How to use FBProphet within Databricks? - python

I have tried installing the FBProphet within a Databricks notebook in the following ways:
dbutils.library.installPyPI('FBProphet', version='0.5')
pip install fbprophet
The first line of code has the error:
Py4JJavaError: An error occurred while calling o1552.addIsolatedPyPILibrary.
: org.apache.spark.SparkException: Process List(/local_disk0/pythonVirtualEnvDirs/virtualEnv-d8a840a2-8b99-410b-a9c8-0b04a40153ab/bin/python, /local_disk0/pythonVirtualEnvDirs/virtualEnv-d8a840a2-8b99-410b-a9c8-0b04a40153ab/bin/pip, install, FBProphet==0.5, --disable-pip-version-check) exited with code 1. ERROR: Could not find a version that satisfies the requirement httpstan<4.7,>=4.6 (from pystan>=2.14->FBProphet==0.5) (from versions: 0.6.0, 0.6.1, 0.7.0, 0.7.1, 0.7.2, 0.7.5, 0.7.6, 0.8.0, 0.10.1, 1.0.0, 1.1.0, 1.1.1, 1.1.2, 2.0.1, 2.0.2, 2.0.3, 2.0.4, 2.0.5, 2.1.0, 2.2.0, 2.3.0, 4.0.0, 4.1.0, 4.2.1, 4.3.0, 4.3.1, 4.3.2, 4.4.0, 4.4.1, 4.4.2)
ERROR: No matching distribution found for httpstan<4.7,>=4.6 (from pystan>=2.14->FBProphet==0.5)
And the second line has the error:
com.databricks.backend.daemon.driver.conda.NotebookEnvironmentException: Notebook environment commands (eg %pip) cannot be used in the same notebook as dbutils.library commands. Please ensure your notebook only uses one of these two types of commands, then detach and re-attach the notebook to run this command.

You shouldn't use the first one because from the error:
"dbutils.library APIs are deprecated and will be removed in a future
DBR release. You can use %pip commands to install notebook-scoped
python libraries."
And for the second one, according to the installations instructions on official documentation,
As of v1.0, the package name on PyPI is “prophet”; prior to v1.0 it
was “fbprophet”
So, you should use pip install prophet instead of pip install fbprophet

Related

ERROR: No matching distribution found for transformers==4.20.1

I am trying to install this specific version of transformers but I get the error:
pip3 install transformers==4.20.1
ERROR: Could not find a version that satisfies the requirement transformers==4.20.1
from versions: 0.1, 2.0.0, 2.1.0, 2.1.1, 2.2.0, 2.2.1, 2.2.2, 2.3.0, 2.4.0, 2.4.1,
2.5.0, 2.5.1, 2.6.0, 2.7.0, 2.8.0, 2.9.0, 2.9.1, 2.10.0, 2.11.0, 3.0.0, 3.0.1, 3.0.2,
3.1.0, 3.2.0, 3.3.0, 3.3.1, 3.4.0, 3.5.0, 3.5.1, 4.0.0rc1, 4.0.0, 4.0.1, 4.1.0,
4.1.1, 4.2.0, 4.2.1, 4.2.2, 4.3.0rc1, 4.3.0, 4.3.1, 4.3.2, 4.3.3, 4.4.0, 4.4.1,
4.4.2, 4.5.0, 4.5.1, 4.6.0, 4.6.1, 4.7.0, 4.8.0, 4.8.1, 4.8.2, 4.9.0, 4.9.1, 4.9.2,
4.10.0, 4.10.1, 4.10.2, 4.10.3, 4.11.0, 4.11.1, 4.11.2, 4.11.3, 4.12.0, 4.12.1,
4.12.2, 4.12.3, 4.12.4, 4.12.5, 4.13.0, 4.14.0, 4.14.1, 4.15.0, 4.16.0, 4.16.1,
4.16.2, 4.17.0, 4.18.0)
ERROR: No matching distribution found for transformers==4.20.1
I know the version exists since I have it installed on my local machine. I installing the package on an ubuntu remote machine. The Python version is 3.6.9. How can I get the version I need if it's saying that it doesn't even exist.
The 4.20.1 build does not support Python prior to 3.7. You'll either need to pick an earlier version or upgrade your Python.
You need Python >=3.7. You might also want to upgrade pip:
pip install --upgrade pip
https://pypi.org/project/transformers/4.20.0/

Can't get Tensorflow 2.9 on Mac?

I'm trying to build a custom environment for a TF agent but for any modules that I need I get the error:
ImportError: This version of TensorFlow Probability requires TensorFlow version >= 2.9; Detected an installation of version 2.6.3. Please upgrade TensorFlow to proceed.
For !pip install tensorflow --upgradeI get:
Requirement already satisfied: tensorflow in ./opt/anaconda3/lib/python3.9/site-packages (2.6.5)
I also tried !pip install tensorflow-macos because it was suggested on pypi.org but then I get:
ERROR: Could not find a version that satisfies the requirement tensorflow-macos (from versions: none) ERROR: No matching distribution found for tensorflow-macos
If I try to specify 2.9 with !pip install 'tensorflow==2.9' --upgrade that does not work either:
ERROR: Could not find a version that satisfies the requirement tensorflow==2.9 (from versions: 2.5.0, 2.5.1, 2.5.3, 2.6.0rc0, 2.6.0rc1, 2.6.0rc2, 2.6.0, 2.6.2, 2.6.3, 2.6.4, 2.6.5, 2.7.0rc0, 2.7.0rc1, 2.7.0, 2.7.1, 2.7.2, 2.7.3)
ERROR: No matching distribution found for tensorflow==2.9
I also tried all of these in my Mac terminal (with python -m pip...) as well as in VS code terminal but I really can't seem to get the Tensorflow version that I need for the agents and environments …
Ok so apparently, Tensorflow 2.9 is only available on macOSX 10.14 and onward ... yikes

PyPi lead to older version of my package instead of the latest

So I have currently uploaded this package: https://pypi.org/project/easy-predictor/0.6.5/ main problem is that when I searched for easy-predictor (which is the name of my package) on PyPi page it displays my older version which is 0.6.3 (https://pypi.org/project/easy-predictor/). Second problem is when I tried to install the latest version of my package (0.6.5) on Command Promt by using pip, it throws this error:
ERROR: Could not find a version that satisfies the requirement easy-predictor==0.6.5 (from versions: 0.0.1, 0.2.0, 0.3.0, 0.4.0, 0.5.0, 0.6.0, 0.6.1, 0.6.2, 0.6.3)
ERROR: No matching distribution found for easy-predictor==0.6.5
I've aswell updated the pip version to the latest.
How do I resolve both errors? and what causes them?.
Can you check with:
pip install easy-predictor==
So without a version?
I get this:
ERROR: Could not find a version that satisfies the requirement easy-predictor== (from versions: 0.0.1, 0.2.0, 0.3.0, 0.4.0, 0.5.0, 0.6.0, 0.6.1, 0.6.2, 0.6.4, 0.6.5)
So 0.6.5 is available in the list.

ERROR: Could not find a version that satisfies the requirement tensorflow==1.2.1 ? pip cannot find tensroflow 1 versions

I cannot install any tensorflow 1 version in my virtual env.. it is required by a project that I'm trying to run..
pip install tensorflow==1.2.1
ERROR: Could not find a version that satisfies the requirement tensorflow==1.2.1 (from versions: 2.2.0rc1, 2.2.0rc2, 2.2.0rc3, 2.2.0rc4, 2.2.0, 2.2.1, 2.3.0rc0, 2.3.0rc1, 2.3.0rc2, 2.3.0, 2.3.1, 2.4.0rc0, 2.4.0rc1, 2.4.0rc2, 2.4.0rc3)
ERROR: No matching distribution found for tensorflow==1.2.1
Tried things suggested here :
Tensorflow r1.0 : could not a find a version that satisfies the requirement tensorflow
my python version is not old : 3.8.5
my pip version is OK : 20.0.2
i still CANNOT install tensorflow 1.2.1 ...
what i gotta do.. I am using ubuntu 20
From https://www.tensorflow.org/install/pip:
System requirements:
Python 3.5–3.8
Python 3.8 support requires TensorFlow 2.2 or later.
There are two options:
Use older version of python (3.5-3.7)
Use TensorFlow 2.2 or later

Can't install last version of pandas (1.0.3)

For last two days, 24/7 I'm trying to deal with the problem of installation of pandas 1.0.3 package within Python 3.6.0. I will try to describe the whole situation below.
In my PyCharm I saw that I can upgrade pandas from 0.25.3 I was using to 1.0.3, but once I tried it an error has occurred.
possibility of an upgrade of pandas
an error
Firstly, I checked the default version of my python in the terminal:
In: python -V
Out: Python 2.7
In: python3 -V
Out: Python 3.6.0
Using this guid I have change the default python version for python 3.6. Which lead to this thing:
In: python -V
Out: Python 3.6.0
But still I can't install/upgrade pandas to version 1.0.3.
I've tried these commands in the terminal:
pip install pandas
pip3 install pandas
pip install pandas==1.0.3
pip3 install pandas==1.0.3
Same commands via sudo
pip install /path_to_wheel
Always I got the same error:
ERROR: Could not find a version that satisfies the requirement pandas==1.0.3 (from versions: 0.1, 0.2b0, 0.2b1, 0.2, 0.3.0b0, 0.3.0b2, 0.3.0, 0.4.0, 0.4.1, 0.4.2, 0.4.3, 0.5.0, 0.6.0, 0.6.1, 0.7.0rc1, 0.7.0, 0.7.1, 0.7.2, 0.7.3, 0.8.0rc1, 0.8.0rc2, 0.8.0, 0.8.1, 0.9.0, 0.9.1, 0.10.0, 0.10.1, 0.11.0, 0.12.0, 0.13.0, 0.13.1, 0.14.0, 0.14.1, 0.15.0, 0.15.1, 0.15.2, 0.16.0, 0.16.1, 0.16.2, 0.17.0, 0.17.1, 0.18.0, 0.18.1, 0.19.0rc1, 0.19.0, 0.19.1, 0.19.2, 0.20.0rc1, 0.20.0, 0.20.1, 0.20.2, 0.20.3, 0.21.0rc1, 0.21.0, 0.21.1, 0.22.0, 0.23.0rc2, 0.23.0, 0.23.1, 0.23.2, 0.23.3, 0.23.4, 0.24.0rc1, 0.24.0, 0.24.1, 0.24.2, 0.25.0rc0, 0.25.0, 0.25.1, 0.25.2, 0.25.3)
ERROR: No matching distribution found for pandas==1.0.3
Please help. I do not know why it happens :(
UPDATE:
Also not working:
python3 -m pip install /Users/username/Downloads/pandas-1.0.3-cp36-cp36m-macosx_10_9_x86_64.whl
Processing ./Downloads/pandas-1.0.3-cp36-cp36m-macosx_10_9_x86_64.whl
ERROR: Package 'pandas' requires a different Python: 3.6.0 not in '>=3.6.1' –
This is because pandas 1.0.x (and 1.1.0x) requires Python 3.6.1 or later. You are using Python 3.6.0. This can be seen in the error message you get :
ERROR: Package 'pandas' requires a different Python: 3.6.0 not in '>=3.6.1' –
This should be solved if you update your Python version.
You can see here the Python 3.6.1 requirement starting from pandas 1.0.0.

Categories