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
Error while compiling the Python code with Tensorflow with Nuitka compiler #74
Comments
Do not use --recurse-directory that way, although it ought to work, but it requires that you do really get right what you are using. However, I can see from the traceback and your PATH that it ought to work. Can you try calling Nuitka with "python -m nuitka" invocation from your Anaconda Python environment to make sure it isn't that. I am assuming now there is a ".pth" file that gets in the way of things, or something like this. I will try and reproduce with current Anaconda. Unfortunately you gave no versions for Nuitka, nor Anaconda there. I assume the one included? |
As for advice to not use recurse directory, next release has "--include-package" that does work on package names. |
Trying to reproduce this on an albeit older Anaconda2: ~/anaconda2/bin/python Mini.py Traceback (most recent call last): |
Ok, my Anaconda skills are too low. I need to do a conda install tensorflow it seems. |
Well, recursing all of tensorflow clearly isn't possible, it includes "contrib" which is just massive amounts of code. I did however not get the assertion from the import code you did. I believe it may be an indication of you using an older Nuitka version. Please use latest by updating with "conda update nuitka" or so. |
Hi, I am compiling the tensorflow code with Nuitka(version 0.5.28) with help of anaconda by using command "nuitka --recurse-all predict.py". I am using Python 3.5/3.6. The simple tensorflow code of printing something is working fine on Nuitka by above command. But when I compile some classification tensorflow code with Nuitka , I am getting the warning/error "scons: *** [predict.exe] the filename or extension is too long in nuitka" where the filename(predict.py) is short. I am saving .exe file into same folder of the code and .exe file is not generating. Here is the screenshot of anaconda prompt. Can you please help me out? Thanks and regards, |
@pratikshaandhare This seems to be a Windows, scons, or compiler issue that I have no clue about. If I had predict.py I would give it a shot here and see if it happens for me too. Have you tried to have ASCII filenames for the directory you compile in? That is about it. |
@swatinair123 No feedback? |
Lack and feedback, plus stink of old bug, closing this. |
It's not an old bug. I am seeing this too right now, current version of Nuitka and Python... |
@cooperdk There is very little that Nuitka can do about this, needs a Scons improvement or so I am thinking. Please consult them. |
Has anyone figured out a work around for this? I'm having this issue when trying to use Nuitka with a discordpy script |
Hi,
I am trying to compile a very simple code with tensorflow. which imports tensorflow. The code compiles fine with Pycharm. But when i try comiling with nuitka --recurse-all Tensorflow_test.py . I have installed Nuitka using anaconda prompt
It gives warning Nuitka:WARNING:Tensorflow_test.py:1: Cannot find 'tensorflow' as relative or absolute import.
I tried nuitka --recurse-all --recurse-directory=C:\Users\tier3dlab1\Anaconda2\pkgs\tensorflow-1.2.1-py36_0\Lib\site-packages\tensorflow --show-progress --standalone Tensorflow_test.py this command also where i am giving the path of tensorflow .But it gives me the below error
File "c:\users\tier3dlab1\anaconda2\lib\site-packages\nuitka\nodes\ModuleNodes.py", line 57, in init
assert '.' not in name, name
AssertionError: benchmark.xcodeproj
and with lots of warnings.
I am able to compile a simple python code with Nuitka. The screenshots are as attached.Please advise
The text was updated successfully, but these errors were encountered: