zoukankan      html  css  js  c++  java
  • 105、TensorFlow的变量(一)

    import tensorflow as tf
    
    mammal = tf.Variable("Elephant", tf.string)
    ignition = tf.Variable(451, tf.int16)
    floating = tf.Variable(3.14159265359, tf.float64)
    its_complicated = tf.Variable(12.3 - 4.85j, tf.complex64)
    sess = tf.Session()
    init = tf.global_variables_initializer()
    sess.run(init)
    print(sess.run(mammal))
    print(sess.run(ignition))
    print(sess.run(floating))
    print(sess.run(its_complicated))

    下面是输出的结果

    2018-02-16 20:30:08.650791: I C:	f_jenkinsworkspace
    el-winMwindowsPY35	ensorflowcoreplatformcpu_feature_guard.cc:137] Your CPU supports instructions that this TensorFlow binary was not compiled to use: AVX AVX2
    b'Elephant'
    451
    3.14159
    (12.3-4.85j)
  • 相关阅读:
    PHP base64
    JS 获取url参数
    PHP 微信分享
    symfony安装笔记
    php 中文繁简体转换
    php webservice
    win10+PHP7
    JS弹出浮层
    CentOS7 Nginx负载均衡
    inotify+rsync目录实时同步
  • 原文地址:https://www.cnblogs.com/weizhen/p/8450441.html
Copyright © 2011-2022 走看看