kendricktan / suiron

Machine Learning for RC Cars
http://jabelone.com.au/blog/make-autonomous-car-code-included/
MIT License
705 stars 78 forks source link

TypeError: variable_scope() got an unexpected keyword argument 'values' #3

Open ProgramItUp opened 7 years ago

ProgramItUp commented 7 years ago

I have followed the installation instructions but am having a problem during training.

When I run python ./train.py the line network = conv_2d(network, 8, [5, 3], activation='relu') throws the error TypeError: variable_scope() got an unexpected keyword argument 'values'

Any thoughts what the problem could be? Thanks,

python ./train.py
I tensorflow/stream_executor/dso_loader.cc:108] successfully opened CUDA library libcublas.so locally
I tensorflow/stream_executor/dso_loader.cc:108] successfully opened CUDA library libcudnn.so locally
I tensorflow/stream_executor/dso_loader.cc:108] successfully opened CUDA library libcufft.so locally
I tensorflow/stream_executor/dso_loader.cc:108] successfully opened CUDA library libcuda.so.1 locally
I tensorflow/stream_executor/dso_loader.cc:108] successfully opened CUDA library libcurand.so locally
[!] Loading dataset...
[!] Finished loading dataset...
Traceback (most recent call last):
  File "./train.py", line 29, in <module>
    servo_model = get_cnn_model(SETTINGS['servo_cnn_name'], SETTINGS['width'], SETTINGS['height'], SETTINGS['depth'])
  File "/data/home/user123/my_tensorflow/suiron/suiron/suiron/core/SuironML.py", line 20, in get_cnn_model
    network = conv_2d(network, 8, [5, 3], activation='relu')
  File "/usr/local/lib/python2.7/dist-packages/tflearn/layers/conv.py", line 72, in conv_2d
    with tf.variable_scope(scope, name, values=[incoming], reuse=reuse) as scope:
  File "/usr/lib/python2.7/contextlib.py", line 84, in helper
    return GeneratorContextManager(func(*args, **kwds))
TypeError: variable_scope() got an unexpected keyword argument 'values'
kendricktan commented 7 years ago

Hmm interesting... could you run the following script and see if it returns any errors?

https://raw.githubusercontent.com/tflearn/tflearn/master/examples/images/convnet_mnist.py

ProgramItUp commented 7 years ago

Yep. Same problem. I wonder if something went wrong during my installation or upgrade of Tensorflow?

~/tensorflow_models/models/im2txt$ python covenet_mnist.py
I tensorflow/stream_executor/dso_loader.cc:108] successfully opened CUDA library libcublas.so locally
I tensorflow/stream_executor/dso_loader.cc:108] successfully opened CUDA library libcudnn.so locally
I tensorflow/stream_executor/dso_loader.cc:108] successfully opened CUDA library libcufft.so locally
I tensorflow/stream_executor/dso_loader.cc:108] successfully opened CUDA library libcuda.so.1 locally
I tensorflow/stream_executor/dso_loader.cc:108] successfully opened CUDA library libcurand.so locally
Downloading MNIST...
Succesfully downloaded train-images-idx3-ubyte.gz 9912422 bytes.
Extracting mnist/train-images-idx3-ubyte.gz
Downloading MNIST...
Succesfully downloaded train-labels-idx1-ubyte.gz 28881 bytes.
Extracting mnist/train-labels-idx1-ubyte.gz
Downloading MNIST...
Succesfully downloaded t10k-images-idx3-ubyte.gz 1648877 bytes.
Extracting mnist/t10k-images-idx3-ubyte.gz
Downloading MNIST...
Succesfully downloaded t10k-labels-idx1-ubyte.gz 4542 bytes.
Extracting mnist/t10k-labels-idx1-ubyte.gz
Traceback (most recent call last):
  File "covenet_mnist.py", line 31, in <module>
    network = conv_2d(network, 32, 3, activation='relu', regularizer="L2")
  File "/usr/local/lib/python2.7/dist-packages/tflearn/layers/conv.py", line 72, in conv_2d
    with tf.variable_scope(scope, name, values=[incoming], reuse=reuse) as scope:
  File "/usr/lib/python2.7/contextlib.py", line 84, in helper
    return GeneratorContextManager(func(*args, **kwds))
TypeError: variable_scope() got an unexpected keyword argument 'values'
kendricktan commented 7 years ago

From the looks of it your installation of tensorflow/cuda went wrong somewhere, or you lack a dependency