Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

version of tensorflow and python #1

Open
Jialeen opened this issue Jun 8, 2020 · 2 comments
Open

version of tensorflow and python #1

Jialeen opened this issue Jun 8, 2020 · 2 comments

Comments

@Jialeen
Copy link

Jialeen commented Jun 8, 2020

Hi,
I wonder the version of tensorflow and python. I run the code and it gives me message that the version is not matched.

Thanks.

@Saafke
Copy link
Owner

Saafke commented Jun 8, 2020

Hi,
I wonder the version of tensorflow and python. I run the code and it gives me message that the version is not matched.

Thanks.

Hi Jialeen,

I am pretty sure it was python 2.7, although I am not sure about tensorflow, my guess would be 1.12.0. I can double check for you somewhere later this week. It should work with most combinations though. Could you perhaps show me the exact error you are getting?

@Jialeen
Copy link
Author

Jialeen commented Jun 12, 2020

Hi,
I wonder the version of tensorflow and python. I run the code and it gives me message that the version is not matched.
Thanks.

Hi Jialeen,

I am pretty sure it was python 2.7, although I am not sure about tensorflow, my guess would be 1.12.0. I can double check for you somewhere later this week. It should work with most combinations though. Could you perhaps show me the exact error you are getting?

The error is as follows:
tensorflow.python.framework.errors_impl.InvalidArgumentError: NodeDef mentions attr 'dilations' not in Op<name=Conv2D; signature=input:T, filter:T -> output:T; attr=T:type,allowed=[DT_HALF, DT_FLOAT]; attr=strides:list(int); attr=use_cudnn_on_gpu:bool,default=true; attr=padding:string,allowed=["SAME", "VALID"]; attr=data_format:string,default="NHWC",allowed=["NHWC", "NCHW"]>; NodeDef: conv1 = Conv2D[T=DT_FLOAT, data_format="NHWC", dilations=[1, 1, 1, 1], padding="SAME", strides=[1, 1, 1, 1], use_cudnn_on_gpu=true, _device="/job:localhost/replica:0/task:0/device:GPU:0"](_arg_IteratorGetNext_0_0/_1, f1). (Check whether your GraphDef-interpreting binary is up to date with your GraphDef-generating binary.).
[[Node: conv1 = Conv2D[T=DT_FLOAT, data_format="NHWC", dilations=[1, 1, 1, 1], padding="SAME", strides=[1, 1, 1, 1], use_cudnn_on_gpu=true, _device="/job:localhost/replica:0/task:0/device:GPU:0"](_arg_IteratorGetNext_0_0/_1, f1)]]

Caused by op u'conv1', defined at:
File "main.py", line 102, in
run.testFromPb(args.image)
File "/home/yujialin/code/sr_cnn/FSRCNN_Tensorflow/run.py", line 243, in testFromPb
graph = self.load_pb(pbPath)
File "/home/yujialin/code/sr_cnn/FSRCNN_Tensorflow/run.py", line 233, in load_pb
tf.import_graph_def(graph_def, name='')
File "/home/yujialin/anaconda3/envs/tf1.10/lib/python2.7/site-packages/tensorflow/python/framework/importer.py", line 313, in import_graph_def
op_def=op_def)
File "/home/yujialin/anaconda3/envs/tf1.10/lib/python2.7/site-packages/tensorflow/python/framework/ops.py", line 2956, in create_op
op_def=op_def)
File "/home/yujialin/anaconda3/envs/tf1.10/lib/python2.7/site-packages/tensorflow/python/framework/ops.py", line 1470, in init
self._traceback = self._graph._extract_stack() # pylint: disable=protected-access

InvalidArgumentError (see above for traceback): NodeDef mentions attr 'dilations' not in Op<name=Conv2D; signature=input:T, filter:T -> output:T; attr=T:type,allowed=[DT_HALF, DT_FLOAT]; attr=strides:list(int); attr=use_cudnn_on_gpu:bool,default=true; attr=padding:string,allowed=["SAME", "VALID"]; attr=data_format:string,default="NHWC",allowed=["NHWC", "NCHW"]>; NodeDef: conv1 = Conv2D[T=DT_FLOAT, data_format="NHWC", dilations=[1, 1, 1, 1], padding="SAME", strides=[1, 1, 1, 1], use_cudnn_on_gpu=true, _device="/job:localhost/replica:0/task:0/device:GPU:0"](_arg_IteratorGetNext_0_0/_1, f1). (Check whether your GraphDef-interpreting binary is up to date with your GraphDef-generating binary.).
[[Node: conv1 = Conv2D[T=DT_FLOAT, data_format="NHWC", dilations=[1, 1, 1, 1], padding="SAME", strides=[1, 1, 1, 1], use_cudnn_on_gpu=true, _device="/job:localhost/replica:0/task:0/device:GPU:0"](_arg_IteratorGetNext_0_0/_1, f1)]]

Python=2.7, tensorflow=1.12 can work.

@weizhiliang0520 weizhiliang0520 mentioned this issue May 19, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants