Have a Problem in timit_train.py
cjjjy opened this issue · 0 comments
Hi:
WHEN I TRY TO RUN THE COOMMAND :
python3 timit_train.py --mode train --level cha --batch_size 8
IT PRODUCE THE PROBLEM AS FOLLOWS:
2018-01-14 14:23:26.356409: I tensorflow/core/common_runtime/gpu/gpu_device.cc:1120] Creating TensorFlow device (/device:GPU:0) -> (device: 0, name: GeForce GTX 1080 Ti, pci bus id: 0000:04:00.0, compute capability: 6.1)
2018-01-14 14:23:26.356440: I tensorflow/core/common_runtime/gpu/gpu_device.cc:1120] Creating TensorFlow device (/device:GPU:1) -> (device: 1, name: GeForce GTX 1080 Ti, pci bus id: 0000:82:00.0, compute capability: 6.1)
Epoch 1 ...
Traceback (most recent call last):
File "/usr/local/lib/python3.5/dist-packages/tensorflow/python/client/session.py", line 1323, in _do_call
return fn(*args)
File "/usr/local/lib/python3.5/dist-packages/tensorflow/python/client/session.py", line 1302, in _run_fn
status, run_metadata)
File "/usr/local/lib/python3.5/dist-packages/tensorflow/python/framework/errors_impl.py", line 473, in exit
c_api.TF_GetCode(self.status.status))
tensorflow.python.framework.errors_impl.FailedPreconditionError: Attempting to use uninitialized value capsule_cnn_layer_2/conv_kernel
[[Node: capsule_cnn_layer_2/conv_kernel/read = IdentityT=DT_FLOAT, _class=["loc:@capsule_cnn_layer_2/conv_kernel"], _device="/job:localhost/replica:0/task:0/device:GPU:0"]]
[[Node: Mean/_17 = _Recvclient_terminated=false, recv_device="/job:localhost/replica:0/task:0/device:CPU:0", send_device="/job:localhost/replica:0/task:0/device:GPU:0", send_device_incarnation=1, tensor_name="edge_958_Mean", tensor_type=DT_FLOAT, _device="/job:localhost/replica:0/task:0/device:CPU:0"]]
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "timit_train.py", line 255, in
runner.run()
File "timit_train.py", line 183, in run
feed_dict=feedDict)
File "/usr/local/lib/python3.5/dist-packages/tensorflow/python/client/session.py", line 889, in run
run_metadata_ptr)
File "/usr/local/lib/python3.5/dist-packages/tensorflow/python/client/session.py", line 1120, in _run
feed_dict_tensor, options, run_metadata)
File "/usr/local/lib/python3.5/dist-packages/tensorflow/python/client/session.py", line 1317, in _do_run
options, run_metadata)
File "/usr/local/lib/python3.5/dist-packages/tensorflow/python/client/session.py", line 1336, in _do_call
raise type(e)(node_def, op, message)
tensorflow.python.framework.errors_impl.FailedPreconditionError: Attempting to use uninitialized value capsule_cnn_layer_2/conv_kernel
[[Node: capsule_cnn_layer_2/conv_kernel/read = IdentityT=DT_FLOAT, _class=["loc:@capsule_cnn_layer_2/conv_kernel"], _device="/job:localhost/replica:0/task:0/device:GPU:0"]]
[[Node: Mean/_17 = _Recvclient_terminated=false, recv_device="/job:localhost/replica:0/task:0/device:CPU:0", send_device="/job:localhost/replica:0/task:0/device:GPU:0", send_device_incarnation=1, tensor_name="edge_958_Mean", tensor_type=DT_FLOAT, _device="/job:localhost/replica:0/task:0/device:CPU:0"]]
Caused by op 'capsule_cnn_layer_2/conv_kernel/read', defined at:
File "timit_train.py", line 255, in
runner.run()
File "timit_train.py", line 139, in run
model = model_fn(args, maxTimeSteps)
File "/home/lab/Automatic_Speech_Recognition-master/speechvalley/models/capsuleNetwork.py", line 114, in init
self.build_graph(self.args, self.maxTimeSteps)
File "/home/lab/Automatic_Speech_Recognition-master/speechvalley/models/capsuleNetwork.py", line 153, in build_graph
output = capLayer(output, [2, 2], (1,1,1,1), args.num_iter)
File "/home/lab/Automatic_Speech_Recognition-master/speechvalley/models/capsuleNetwork.py", line 87, in call
self._num_channelsself._num_capsulesself._output_vector_len], dtype=tf.float32)
File "/usr/local/lib/python3.5/dist-packages/tensorflow/python/ops/variable_scope.py", line 1203, in get_variable
constraint=constraint)
File "/usr/local/lib/python3.5/dist-packages/tensorflow/python/ops/variable_scope.py", line 1092, in get_variable
constraint=constraint)
File "/usr/local/lib/python3.5/dist-packages/tensorflow/python/ops/variable_scope.py", line 425, in get_variable
constraint=constraint)
File "/usr/local/lib/python3.5/dist-packages/tensorflow/python/ops/variable_scope.py", line 394, in _true_getter
use_resource=use_resource, constraint=constraint)
File "/usr/local/lib/python3.5/dist-packages/tensorflow/python/ops/variable_scope.py", line 805, in _get_single_variable
constraint=constraint)
File "/usr/local/lib/python3.5/dist-packages/tensorflow/python/ops/variables.py", line 213, in init
constraint=constraint)
File "/usr/local/lib/python3.5/dist-packages/tensorflow/python/ops/variables.py", line 356, in _init_from_args
self._snapshot = array_ops.identity(self._variable, name="read")
File "/usr/local/lib/python3.5/dist-packages/tensorflow/python/ops/array_ops.py", line 125, in identity
return gen_array_ops.identity(input, name=name)
File "/usr/local/lib/python3.5/dist-packages/tensorflow/python/ops/gen_array_ops.py", line 2071, in identity
"Identity", input=input, name=name)
File "/usr/local/lib/python3.5/dist-packages/tensorflow/python/framework/op_def_library.py", line 787, in _apply_op_helper
op_def=op_def)
File "/usr/local/lib/python3.5/dist-packages/tensorflow/python/framework/ops.py", line 2956, in create_op
op_def=op_def)
File "/usr/local/lib/python3.5/dist-packages/tensorflow/python/framework/ops.py", line 1470, in init
self._traceback = self._graph._extract_stack() # pylint: disable=protected-access
FailedPreconditionError (see above for traceback): Attempting to use uninitialized value capsule_cnn_layer_2/conv_kernel
[[Node: capsule_cnn_layer_2/conv_kernel/read = IdentityT=DT_FLOAT, _class=["loc:@capsule_cnn_layer_2/conv_kernel"], _device="/job:localhost/replica:0/task:0/device:GPU:0"]]
[[Node: Mean/_17 = _Recvclient_terminated=false, recv_device="/job:localhost/replica:0/task:0/device:CPU:0", send_device="/job:localhost/replica:0/task:0/device:GPU:0", send_device_incarnation=1, tensor_name="edge_958_Mean", tensor_type=DT_FLOAT, _device="/job:localhost/replica:0/task:0/device:CPU:0"]]
Is there any other parameter that i should set?
Thanks!