Tensorflow 激活函数 tf.nn.relu介绍 这个函数的作用是计算激活函数 relu。将大于0的值持不变,小于0的值置为0。 tf.nn.relu(features, name = None Example import tensorflow as tf print(tf.nn.relu([-2., 0., -0., 3.]).numpy()) 上述程序输出结果为:[0. 0. 0. 3.]