cjiang2 / VDCNN

Implementation of Very Deep Convolutional Neural Network for Text Classification
171 stars 41 forks source link

Issue about running your code #1

Closed Syrup274 closed 6 years ago

Syrup274 commented 6 years ago

I encounteded the following question when running your code(tf == 1.1.0):

Traceback (most recent call last): File "C:/Users/syrup/Documents/VDCNN-master/train.py", line 47, in use_k_max_pooling=FLAGS.use_k_max_pooling) File "C:\Users\syrup\Documents\VDCNN-master\vdcnn_9.py", line 54, in init initializer=conv_initializer) File "C:\Program Files\Anaconda3\lib\site-packages\tensorflow\python\ops\variable_scope.py", line 1049, in get_variable use_resource=use_resource, custom_getter=custom_getter) File "C:\Program Files\Anaconda3\lib\site-packages\tensorflow\python\ops\variable_scope.py", line 948, in get_variable use_resource=use_resource, custom_getter=custom_getter) File "C:\Program Files\Anaconda3\lib\site-packages\tensorflow\python\ops\variable_scope.py", line 356, in get_variable validate_shape=validate_shape, use_resource=use_resource) File "C:\Program Files\Anaconda3\lib\site-packages\tensorflow\python\ops\variable_scope.py", line 341, in _true_getter use_resource=use_resource) File "C:\Program Files\Anaconda3\lib\site-packages\tensorflow\python\ops\variable_scope.py", line 714, in _get_single_variable validate_shape=validate_shape) File "C:\Program Files\Anaconda3\lib\site-packages\tensorflow\python\ops\variables.py", line 197, in init expected_shape=expected_shape) File "C:\Program Files\Anaconda3\lib\site-packages\tensorflow\python\ops\variables.py", line 275, in _init_from_args initial_value(), name="initial_value", dtype=dtype) File "C:\Program Files\Anaconda3\lib\site-packages\tensorflow\python\ops\variable_scope.py", line 690, in shape.as_list(), dtype=dtype, partition_info=partition_info) TypeError: call() got an unexpected keyword argument 'partition_info'

cjiang2 commented 6 years ago

Sorry for the late reply. I tried running the code on a Windows machine with Anaconda3 and it worked good. Given the error message, I believe the error should be related to your Tensorflow installation. Try updating your Tensorflow to 1.3 then see if the error goes away?