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

ModuleNotFoundError: No module named 'tensorflow.python.training.checkpointable' #155

Open
Franck-Dernoncourt opened this issue Nov 21, 2019 · 8 comments
Labels

Comments

@Franck-Dernoncourt
Copy link
Owner

I ran:

# Create python virtual environment
virtualenv -p python3.6 /mnt/ilcompn0d1/user/dernonco/pyenv/neuroner
source /mnt/ilcompn0d1/user/dernonco/pyenv/neuroner/bin/activate

# Install neuroner
pip3 install pyneuroner[gpu]

# Get word embeddings
wget -P data/word_vectors http://neuroner.com/data/word_vectors/glove.6B.100d.zip
unzip data/word_vectors/glove.6B.100d.zip -d data/word_vectors/

# Test neuroner 
neuroner --fetch_data=conll2003

The last command gives the error:


(neuroner) dernonco@ilcompn0:/mnt/ilcompn0d1/user/dernonco/sensei/neuroner/gpu$ neuroner --fetch_data=conll2003

Traceback (most recent call last):
  File "/mnt/ilcompn0d1/user/dernonco/pyenv/neuroner/bin/neuroner", line 6, in <module>
    from neuroner.__main__ import main
  File "/mnt/ilcompn0d1/user/dernonco/pyenv/neuroner/lib/python3.6/site-packages/neuroner/__main__.py", line 16, in <module>
    from neuroner import neuromodel
  File "/mnt/ilcompn0d1/user/dernonco/pyenv/neuroner/lib/python3.6/site-packages/neuroner/neuromodel.py", line 20, in <module>
    from tensorflow.contrib.tensorboard.plugins import projector
  File "/mnt/ilcompn0d1/user/dernonco/pyenv/neuroner/lib/python3.6/site-packages/tensorflow/contrib/__init__.py", line 28, in <module>
    from tensorflow.contrib import checkpoint
  File "/mnt/ilcompn0d1/user/dernonco/pyenv/neuroner/lib/python3.6/site-packages/tensorflow/contrib/checkpoint/__init__.py", line 47, in <module>
    from tensorflow.contrib.checkpoint.python.containers import UniqueNameTracker
  File "/mnt/ilcompn0d1/user/dernonco/pyenv/neuroner/lib/python3.6/site-packages/tensorflow/contrib/checkpoint/python/containers.py", line 20, in <module>
    from tensorflow.python.training.checkpointable import base as checkpointable_lib
ModuleNotFoundError: No module named 'tensorflow.python.training.checkpointable'

The fix is to change the version of tensorflow-gpu from 2.x to 1.13.1, which can be done as follows:

pip uninstall tensorflow-gpu
pip install tensorflow-gpu==1.13.1

But we should fix the installation code to avoid having the issue in the first place.

@nkshelby
Copy link

nkshelby commented Dec 1, 2019

@Franck-Dernoncourt Did it solve the issue ??
i am having a similar

Traceback (most recent call last):
File "train.py", line 43, in
from tensorflow.contrib import framework as contrib_framework
File "C:\ProgramData\Anaconda3\lib\site-packages\tensorflow\contrib_init_.py", line 28, in
from tensorflow.contrib import checkpoint
File "C:\ProgramData\Anaconda3\lib\site-packages\tensorflow\contrib\checkpoint_init_.py", line 47, in
from tensorflow.contrib.checkpoint.python.containers import UniqueNameTracker
File "C:\ProgramData\Anaconda3\lib\site-packages\tensorflow\contrib\checkpoint\python\containers.py", line 20, in
from tensorflow.python.training.checkpointable import base as checkpointable_lib
ModuleNotFoundError: No module named 'tensorflow.python.training.checkpointable'

Please help!. Thanks in advance

@Franck-Dernoncourt
Copy link
Owner Author

Yes I fixed the issue, please see the end of my bug report

@nkshelby
Copy link

nkshelby commented Dec 1, 2019 via email

@nkshelby
Copy link

nkshelby commented Dec 1, 2019

@Franck-Dernoncourt my tensorflow-gpu is already 1.13.1.
and it is still not working

@ravikrindiswathi
Copy link

if the tensorflow-gpu version==1.13.1 also the same issue arising

@ravikrindiswathi
Copy link

how to fix it??

@sourav1122
Copy link

i've solved this issue with the same u provided above :) thanks

@rrajp
Copy link

rrajp commented May 8, 2020

Upgrade tensorflow to "==1.15.2" solved issue for me.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

5 participants