How can I plot histograms of the activations of tf.layers.dense
in tensorboard? Consider the following situation:
with tf.variable_scope('hidden'):
hidden_layer = tf.layers.dense(input, 100, activation=tf.nn.relu)
I can plot the weights and biases from hidden
with the following code:
for v in tf.get_collection(tf.GraphKeys.TRAINABLE_VARIABLES, scope='hidden'):
tf.summary.histogram("{}/weight_histogram".format(v.name), v)
However, I can't seem to get a collection of the activations as well. How could I modify this to also plot histograms of the activations?
在模型范围内,您需要调用以下内容: tf.contrib.layers.summarize_activation(hidden_layer)
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.