Reputation: 6466
As the title clearly describes the issue I've been experiencing, no Pipfile.lock
is being generated as I get the following error when I execute the recommended command pipenv lock --clear
:
ERROR: ERROR: Could not find a version that matches keras-nightly~=2.5.0.dev
Skipped pre-versions: 2.5.0.dev2021020510, 2.5.0.dev2021020600, 2.5.0.dev2021020700, 2.5.0.dev2021020800, 2.5.0.dev2021020900, 2.5.0.dev2021021000, 2.5.0.dev2021021100, 2.5.0.dev2021021200, 2.5.0.dev2021021300, 2.5.0.dev2021021400, 2.5.0.dev2021021500, 2.5.0.dev2021021600, 2.5.0.dev2021021700, 2.5.0.dev2021021800, 2.5.0.dev2021021900, 2.5.0.dev2021022000, 2.5.0.dev2021022100, 2.5.0.dev2021022200, 2.5.0.dev2021022300, 2.5.0.dev2021022317, 2.5.0.dev2021022400, 2.5.0.dev2021022411, 2.5.0.dev2021022500, 2.5.0.dev2021022600, 2.5.0.dev2021022700, 2.5.0.dev2021022800, 2.5.0.dev2021030100, 2.5.0.dev2021030200, 2.5.0.dev2021030300, 2.5.0.dev2021030400, 2.5.0.dev2021030500, 2.5.0.dev2021030600, 2.5.0.dev2021030700, 2.5.0.dev2021030800, 2.5.0.dev2021030900, 2.5.0.dev2021031000, 2.5.0.dev2021031100, 2.5.0.dev2021031200, 2.5.0.dev2021031300, 2.5.0.dev2021031400, 2.5.0.dev2021031500, 2.5.0.dev2021031600, 2.5.0.dev2021031700, 2.5.0.dev2021031800, 2.5.0.dev2021032213, 2.5.0.dev2021032300, 2.5.0.dev2021032413, 2.5.0.dev2021032500, 2.5.0.dev2021032600, 2.5.0.dev2021032610, 2.5.0.dev2021032700, 2.5.0.dev2021032800, 2.5.0.dev2021032900, 2.6.0.dev2021033000, 2.6.0.dev2021033100, 2.6.0.dev2021040100, 2.6.0.dev2021040200, 2.6.0.dev2021040300, 2.6.0.dev2021040400, 2.6.0.dev2021040500, 2.6.0.dev2021040600, 2.6.0.dev2021040714, 2.6.0.dev2021040800, 2.6.0.dev2021040900, 2.6.0.dev2021041000, 2.6.0.dev2021041100, 2.6.0.dev2021041200, 2.6.0.dev2021041300, 2.6.0.dev2021041400, 2.6.0.dev2021041500, 2.6.0.dev2021041600, 2.6.0.dev2021041700, 2.6.0.dev2021041800, 2.6.0.dev2021041900, 2.6.0.dev2021042000, 2.6.0.dev2021042100, 2.6.0.dev2021042200, 2.6.0.dev2021042300, 2.6.0.dev2021042500, 2.6.0.dev2021042600, 2.6.0.dev2021042700, 2.6.0.dev2021042800, 2.6.0.dev2021042900, 2.6.0.dev2021043000, 2.6.0.dev2021050100, 2.6.0.dev2021050200, 2.6.0.dev2021050300, 2.6.0.dev2021050400, 2.6.0.dev2021050500, 2.6.0.dev2021050600, 2.6.0.dev2021051200, 2.6.0.dev2021051300, 2.6.0.dev2021051400, 2.6.0.dev2021051500, 2.6.0.dev2021051600, 2.6.0.dev2021051700, 2.6.0.dev2021051800, 2.6.0.dev2021051900, 2.6.0.dev2021052000, 2.6.0.dev2021052100, 2.6.0.dev2021052200, 2.6.0.dev2021052300, 2.6.0.dev2021052400, 2.6.0.dev2021052500, 2.6.0.dev2021052600, 2.6.0.dev2021052700
There are incompatible versions in the resolved dependencies.
So, how can I overcome this situation? I'm basically developing a deep neural network using Keras
. I simply installed the following dependencies without explicitly declaring versions:
tensorflow = "*"
nltk = "*"
pandas = "*"
tweepy = "*"
textblob = "*"
seaborn = "*"
matplotlib = "*"
wordcloud = "*"
stop-words = "*"
vadersentiment = "*"
scikit-learn = "*"
keras = "*"
Upvotes: 7
Views: 1900
Reputation: 1
adding those line to Pipfile fixed my issue.
[pipenv]
allow_prereleases = true
Upvotes: 0
Reputation: 135
It seems that tensorflow does not work on python 3.9 as it has a dependency on the nightly.
If you are using python 3.9, your option is to go to tensorflow 2.6.0rc1,
Upvotes: 0
Reputation: 531
Pipenv wants you to use the --pre
flag in this situation. I think the simplest way to install it would be like this:
pipenv install tensorflow --python=3.8 --pre
Upvotes: 2
Reputation: 3651
By Changing the python_version
in pipenv
file resolved my issue.
I had it 3.9
before.
Pipfile
:
python_version = "3.8"
Upvotes: 0
Reputation: 1675
I had the same problem. Apparently, tensorflow
arises a sub-dependency resolution error with Pipfile
when resolving keras
. It searches for a version that matches keras-nightly~=2.5.0.dev
. Looking at pypi
, this version does not exist.
Whatsoever, installing a version 2.4.X works, e. g. pipenv install tensorflow~=2.4.1
.
Upvotes: 0
Reputation: 1001
By looking at the pypi
site for keras-nightly
library, I could see that there are no versions named 2.5.0.dev
. Check which package is generating the error and try downgrading that package.
Upvotes: 2