Open Tomingz opened 6 years ago
did you solve your problem?The problem i met is the same as yours.
you should write your code in this way
tf.variable_scope(name):
cell = tf.contrib.rnn.LSTMCell(self.num_input,state_is_tuple=False) #tf.nn.rnn_cell
state = _istate
for step in range(self.num_steps):
outputs, state = tf.contrib.rnn.static_rnn(cell, [_X[step]],state, dtype=tf.float32) #tf.nn.rnn
tf.nn.rnn_cell.BasicLSTMCell
tf.get_variable_scope().reuse_variables()
return outputs
you should write your code in this way
tf.variable_scope(name): cell = tf.contrib.rnn.LSTMCell(self.num_input,state_is_tuple=False) #tf.nn.rnn_cell state = _istate for step in range(self.num_steps):
outputs, state = tf.contrib.rnn.static_rnn(cell, [_X[step]],state, dtype=tf.float32) #tf.nn.rnn
tf.nn.rnn_cell.BasicLSTMCell
tf.get_variable_scope().reuse_variables()__
return outputs
you should write your code in this way
tf.variable_scope(name): cell = tf.contrib.rnn.LSTMCell(self.num_input,state_is_tuple=False) #tf.nn.rnn_cell state = _istate for step in range(self.num_steps):
outputs, state = tf.contrib.rnn.static_rnn(cell, [_X[step]],state, dtype=tf.float32) #tf.nn.rnn
tf.nn.rnn_cell.BasicLSTMCell
tf.get_variable_scope().reuse_variables()__
return outputs
你好,请问一下你又成功运行起来ROLO吗,能不能留个联系方式啊,我跑的时候遇到一些问题想要咨询一下您
I use tensorflow1.3+python3.5 in windows,so i change the code like this: def LSTM_single(self, name, _X, _istate, _weights, _biases): with tf.device('/gpu:0'):
input shape: (batch_size, n_steps, n_input) 1-3-5002
when I run ROLO_network_test_all.py there is a error like this: ValueError: Variable rnn/lstm_cell/kernel does not exist, or was not created with tf.get_variable(). Did you mean to set reuse=None in VarScope? how to sovle it? maybe we can discuss it . my email:821514169@qq.com