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

import tensorflow problem #32171

Closed
RZz96 opened this issue Sep 3, 2019 · 21 comments
Closed

import tensorflow problem #32171

RZz96 opened this issue Sep 3, 2019 · 21 comments
Assignees
Labels
subtype:windows Windows Build/Installation Issues TF 1.14 for issues seen with TF 1.14 type:build/install Build and install issues

Comments

@RZz96
Copy link

RZz96 commented Sep 3, 2019

  • OS Platform and Distribution (windows 64):
  • TensorFlow version (use command below): 1.14.0
  • Python version:3.6.8

Hi
When i import tensorflow , it just quit the code without any error .

appreciate any help in advance

@00000110
Copy link

00000110 commented Sep 3, 2019 via email

@mihaimaruseac
Copy link
Collaborator

Can you provide all the details needed for a bug, see the template?

Can you provide a demo of the behavior you're seeing?

@ravikyram ravikyram self-assigned this Sep 4, 2019
@ravikyram ravikyram added TF 1.14 for issues seen with TF 1.14 stat:awaiting response Status - Awaiting response from author labels Sep 4, 2019
@RZz96
Copy link
Author

RZz96 commented Sep 4, 2019

Can you provide all the details needed for a bug, see the template?

Can you provide a demo of the behavior you're seeing?

C:\>python
Python 3.6.8 |Anaconda, Inc.| (default, Dec 30 2018, 18:50:55) [MSC v.1915 64 bit (AMD64)] on win32
Type "help", "copyright", "credits" or "license" for more information.
>>> import tensorflow
C:\>

Hi thanks for the reply
As u see after importing the tensorflow , it just quit.

@ravikyram
Copy link
Contributor

@RZz96

As per my understanding you are able to install tensorflow successfully but while importing tensorflow it is going to quit from command prompt. Please, let me know my understanding is correct? Thanks!

@RZz96
Copy link
Author

RZz96 commented Sep 4, 2019

@RZz96

As per my understanding you are able to install tensorflow successfully but while importing tensorflow it is going to quit from command prompt. Please, let me know my understanding is correct? Thanks!

yes exactly . i think i have to install another version of python . may be 3.7 .
is there any other way to solve the problem rather than the new installation of python ?

@ravikyram ravikyram added type:build/install Build and install issues subtype:windows Windows Build/Installation Issues labels Sep 4, 2019
@ravikyram ravikyram assigned ymodak and unassigned ravikyram Sep 4, 2019
@mihaimaruseac
Copy link
Collaborator

Can you try python -v instead of python and repeat the same import? You'll have a large output after that, please share it.

@RZz96
Copy link
Author

RZz96 commented Sep 4, 2019

I did , the result is the same , just this time it printed all the modules and processes in details.
just to mention that im running it on virtual env

@mihaimaruseac
Copy link
Collaborator

Yes, but printing them might hide away the crash. That's why I suggested sharing the output

@tensorflowbutler tensorflowbutler removed the stat:awaiting response Status - Awaiting response from author label Sep 5, 2019
@RZz96
Copy link
Author

RZz96 commented Sep 5, 2019

Hi here i have attached the output.
output.txt

@mihaimaruseac
Copy link
Collaborator

Ok, so there's a segfault coming from a dependency. what version of h5py gets installed on your system?

@RZz96
Copy link
Author

RZz96 commented Sep 5, 2019

it is 2.9.0

@mihaimaruseac
Copy link
Collaborator

Can you try with pip install tensorflow==2.0.0rc0 instead of 1.14?

@mihaimaruseac
Copy link
Collaborator

Another option is to try having a file myfile.py with just import tensorflow and see if you can do python myfile.py

@RZz96
Copy link
Author

RZz96 commented Sep 5, 2019

Another option is to try having a file myfile.py with just import tensorflow and see if you can do python myfile.py
no . i already tried and didnt work . im installing the tensorflow 2

@mihaimaruseac
Copy link
Collaborator

And the third option (although you might want this first) is to run python in a debugger.

For example, here's what I'd do if gdb were present (needs some setup on Windows)

(3) mihaimaruseac@ankh:/tmp/gh/3$ gdb -q python
Reading symbols from python...(no debugging symbols found)...done.
(gdb) r
Starting program: /tmp/gh/3/bin/python 
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1".
Python 2.7.16 (default, Apr  6 2019, 01:42:57) 
[GCC 7.3.0] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>> import tensorflow as tf
[New Thread 0x7ffff3ae9700 (LWP 142370)]
[New Thread 0x7ffff32e8700 (LWP 142371)]
....
>>> print(tf.__version__)
2.0.0-dev20190905
>>> 
[Inferior 1 (process 142358) exited normally]
(gdb) quit

@RZz96
Copy link
Author

RZz96 commented Sep 5, 2019

the new installation didnt work .
i never used gdb for python debugging . i will try it and let you know.

@RZz96
Copy link
Author

RZz96 commented Sep 6, 2019

working with gdb in windows needs a lots of set up which i dont want to go trough .
if you dont know any other solution , then may be is better to install the python 3.7 to resolve the problem.

@mihaimaruseac
Copy link
Collaborator

See also #31431. Some people have had troubles installing tensorflow on python3.7

There should be other debuggers on Windows which can be used.

@RZz96
Copy link
Author

RZz96 commented Sep 6, 2019

Thanks i will check it

@ymodak
Copy link
Contributor

ymodak commented Sep 14, 2019

Automatically closing due to lack of recent activity. Please update the issue when new information becomes available, and we will reopen the issue. Thanks!

@ymodak ymodak closed this as completed Sep 14, 2019
@tensorflow-bot
Copy link

Are you satisfied with the resolution of your issue?
Yes
No

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
subtype:windows Windows Build/Installation Issues TF 1.14 for issues seen with TF 1.14 type:build/install Build and install issues
Projects
None yet
Development

No branches or pull requests

6 participants