以下はコードの簡略版です。行でエラーが発生していますres = input - var
import tensorflow.contrib.slim as slim
import tensorflow as tf
x = tf.placeholder(tf.float32, shape=[None, 150, 220, 3], name='x')
input = slim.conv2d(x, num_outputs=96, kernel_size=11, stride=4, padding=padding, scope=scope, weights_initializer=tf.truncated_normal_initializer(stddev=0.01), biases_initializer=None, activation_fn=None)
var = tf.zeros_initializer()
res = input - var
変数の種類
input type: <tensorflow.python.ops.init_ops.Zeros object at 0x7f1a017fdb38>
var_type: Tensor("conv1/Conv2D:0", shape=(?, 35, 53, 96), dtype=float32)
エラー
TypeError: Expected float32, got <tensorflow.python.ops.init_ops.Zeros object at 0x7f1a017fdb38> of type 'Zeros' instead.
どうすれば解決できますか、どんな提案も役に立ちます。