Closed hansely closed 4 years ago
There has been no change recently in this respect. Furthermore, I have no idea why it would have anything to do with setup.py, can you tell me why you suspect that? Does this happen when running setup.py, or afterwards when using the tools? What is the python version that you are using? Does it work with other models?
This error was reported by my teammate who recently installed NNEF using the setup.py script. On my system with the previous version of NNEF, the conversion was working. However, when I ran the latest setup.py script on the NNEF tot, I started to experience the same error. The python version we are using is 2.7. All the other models are failing as well. fyi) I gave the folder path as an input. If I give a file path (graph.nnef), it works.
I think you might have been using a pretty old version of the NNEF tools, and your Python version is also old. This feature with the seekables (to check validity of tensor binaries) have been added to the tools quite long ago, and it may be the case that Python 2.7 does not support that feature. When you give it a graph path instead of a folder, the binaries are not processed, that's why you don't get the error in that case. Can you try upgrading to Python 3? It's advised on the long run as well, since many tools are dropping support for Python2, and maybe NNEF tools will gradually do the same at some point since maintaining these incompatibilities is painful.
I tried running the conversion on python3 and it is working. Thanks for your suggestion. So on any systems with python2, is NNEF not supported anymore?
As it seems that the current tool is broken on Python 2, furthermore there might be other places where it may be broken, it would require some testing to see if it could be fixed. But since other tools such as TensorFlow and PyTorch are also dropping support for Python 2, and NNEF tools for conversion are using those, we can expect that it would soon be the case that it becomes impossible to support Python 2, so I don't see much point in putting much effort to do it.
I see. Thanks for your explanation. Will close the issue now.
With the latest parser/python/setup.py file, when using the load_graph function, I am experiencing an error saying 'file' object has no attribute 'seekable'. This error didn't happen before running the setup.py script. Also, this happens only when I give a folder path as an input. If I give the graph path instead, I don't get the error message. I'm using vgg16-onnx model from Nnef Model Zoo. Any solution to this issue?