Tensorflow中的tf.where与tf.greater

tf.greater(a,b) 功能:通过比较a、b两个值的大小来输出对错。 例如:当a=4,b=3时,输出结果为:true;当a=2,b=3时,输出结果为:false。 import tensorflow as tf sess=tf.Session() with sess.as_default(): print(tf.greater(4,3).eval()) 结果: True tf.w
相关文章
相关标签/搜索