Cannot install "dash" with Python version 3.6.4 - python

We have a large clustered Data environment with no access to the internet. I'm attempting to install Dash from our local pip repository, but it doesn't want to install on Python 3.6.4. I've tried versions 2.0.0 and 1.21.1.
When attempting to install dash 2.0.0, I get the following error:
ERROR: Package 'dash' requires a different Python: 3.6.4 not in '>=3.6'
When attempting to install dash 1.21.1, I get the following error:
ERROR: Package 'dash' requires a different Python: 3.6.4 not in '!=3.0.*,!=3.1.*,!=3.2.*,>=2.7'
Neither of these appear to actually state 3.6.4 is not supported, however I can't for the life of me get it to install. Is there a version of Dash specific to Python 3.6.4, or is it simply not supported? It's not an easy environment to update the Python version so this will likely not permit us to use Dash in the near future if it is simply not supported.

I was able to determine my problem.
I had to download about 25 dependent packages for dash and based my download purely on the version that dash told me to download. One of the packages (importlib-metadata) was not compatible with Python 3.6.4. Once I downgraded this package it worked fine.
I really wish pip informed you of the specific dependency it was having an issue with rather than reverting to the one you are trying to install.

Related

Error while running azuremlsdk::install_azureml() in R

I'm trying to load an existing azure workspace in RStudio Azure Compute Instance like it's shown in this link: https://azure.github.io/azureml-sdk-for-r/. But, after installing azuremlsdk package when I'm running this code azuremlsdk::install_azureml(). I'm getting this error :
Attempting uninstall: certifi  Found existing installation: certifi2016.9.26ERROR: Cannot uninstall 'certifi'. It is a distutilsinstalled project and thus we cannot accurately determine which files belong to it which would lead to only a partial uninstall.Error: Error installing package(s): 'azureml-sdk==1.10.0', 'numpy', 'pandas'
By referring to this link : https://learn.microsoft.com/en-us/azure/machine-learning/how-to-troubleshoot-environments; I tried to fix this error by running conda remove certifi through terminal of that Compute Instance & Jupyter Notebook of that Compute Instance. But, no luck.
Does anyone have any experience in resolving this issue. Please help.
Azure ML has issues with Python versions and its dependency packages, make sure you are using Python package of 3.5 to 3.8 while installing these.
While installing azureml it will search for all the dependency packages and will install all of them, in this process there will be the version issues, like pandas, numpy.. with different pip versions.
From your stack trace looks like the error is happening when we install the packages like pandas numpy etc along with azureml-train-automl-client package so try to install them before hand by checking its versions which are dependent with you python versions packages.
Check the Azure ML documentation for installation of Azure ML Additional packages.
If you investigate them azureml-train-automl requires somes data science packages including pandas, numpy, and scikit-learn.
Kindly follow below commands for conda environment:
pip install azureml-train-automl
pip install --upgrade azureml-train-automl
pip install show azureml-train-automl
It seems that the Python SDK installation conflicts with itself when using Python 3.6 (the default). I was able to install the SDK for Python 3.7:
azuremlsdk::install_azureml(conda_python_version = '3.7')

Getting an error saying "Could not build wheels for numpy which use PEP 517 and cannot be installed directly" while installing numpy

I am trying to install a specific version of numpy using the command pip install numpy=1.19.1 in a python virtual environment. But I am getting the following errors
ERROR: Failed building wheel for numpy
Failed to build numpy
ERROR: Could not build wheels for numpy which use PEP 517 and cannot be installed directly
How do I solve this? I am using Python 3.9.6 and Pip 21.1.3. And I am on macOS Big Sur.
I was facing the same error on my MacBook Air(macOS BigSur) Laptop while installing the Numpy package via integrated terminal of VS Code. And I found the solution:
So previously I was using older version of pip i.e. 19.2.3.
But when I upgraded it to the latest version using command
pip install --upgrade pip
and after that when running the command
pip install numpy
it worked absolutely fine.
At the time running the above commands, my python version was 3.8.2.
I think NumPy is not yet being prepared for Python 3.9 since they need to check a lot of times. You should try Python 3.7 or 3.8 is better.
See this thread: https://github.com/numpy/numpy/issues/17569
Edit: Based on the latest news on numpy's website (dated 31st December) Numpy appears to now be supporting python 3.9 and 3.10 as well
If you're on Windows, then install Visual Studio 2019 Build Tools, then go to 'Individual components', then tick the latest version of 'Windows 10 SDK', and 'MSVC v142 x64/86 build tools - Latest'. That solved this error for me, except for me this error came when installing discord.py.
Try seeing if it works with Python 3.8 first though, just like Dhananjay's answer. That could save you a lot of storage, because Visual Studio takes up lots of space. If that doesn't work, you can try my answer.
Edit: I just realised, you said you're on Mac. Try this:
type python -VV in terminal
It should say something like this:
Python 3.9.6 (default, Jun 29 2021, 10:19:25)
[GCC 10.3.0]
Whatever it says on the second line is what you will need to install. I use Python on Ubuntu 21.10 on WSL2, which uses GCC 10.3.0, and I have GCC 10.3.0 installed.
Similarly to the answers above, switching to Python 3.8 solved the issue. Additionally, because of this issue, I couldn't install scikit-image which depends on numpy.
I created a virtual environment of Python 3.8 using conda i.e. conda create -n py38 python=3.8 to switch python version. I have Mac M1, 2020 updated to OS Monterey, version 12.0.1.
yea, I was also using python 3.10 and switched back to python 3.8.
check this link python/downloads to download python 3.8

Can't find Brew installed packages on Mac M1 in Pycharm

I'm having trouble installing packages and using them in Pycharm. I've followed various threads (I'm new to Macs and seem to have tried everything) now I'm stuck.
In this case, I want to use the package xgboost.
I have brew installed, after launching a terminal using Rosetta:
%brew install xgboost
Warning: xgboost 1.3.3 is already installed and up-to-date.
It appears installed OK here:
/opt/homebrew/Cellar/xgboost
I also have Python installed here:
/opt/homebrew/Cellar/python#3.9
But no matter how I configure an Interpreter in Pycharm, I can't seem to get the package recognised.
Where have I gone wrong?
I am very unsure exactly how, but I've got this working.
Following: https://abbasegbeyemi.me/blog/homebrew-python-apple-m1
I changed the order of elements in my path:
export PATH=/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/opt/homebrew/bin
then a new interpreter in Pycharm using:
usr/local/Cellar/Python#3.9/3.9.2_2/bin/python3.9
Now I can install packages just using pip in pycharm and it works.
This has been 6 hours of pain - warning to anyone who isn't well versed in macs, setting up an M1 for python dev was a complete nightmare for me.
Docs: https://xgboost.readthedocs.io/en/latest/build.html
Pre-built binary wheel for Python
If you are planning to use Python, consider installing XGBoost from a pre-built binary wheel, available from Python Package Index (PyPI). You may download and install it by running
# Ensure that you are downloading one of the following:
# * xgboost-{version}-py2.py3-none-manylinux1_x86_64.whl
# * xgboost-{version}-py2.py3-none-win_amd64.whl
pip3 install xgboost

cannot install tensorflow-text using pip despite having tensorflow 2.0.0-beta1 installed

My tensorflow 2.0.0beta1 runs normally, but I cannot install tensorflow-text using the command pip install tensorflow-text (as described on the tensorflow page). I can find it using pip search tensorflow-text but I am getting an error
ERROR: Could not find a version that satisfies the requirement tensorflow-text (from versions: none)
There are no requirements for this package (i.e. a specific python version).
I am running on windows, using conda, python 3.6.9
Update
The first release candidate of 2.4.0 was published today which features windows wheels for the first time. 2.4.0rc0 on PyPI. Note that only wheels for Python 3.6 and 3.7 are working properly at the moment. Install via e.g.
> py -3.7 -m pip install tensorflow-text==2.4.0rc0
Original answer
At the time of writing this, tensorflow-text is not available for Windows yet.
Windows is something we do wish to add. We've had some difficulties getting a working package though, which is why it is not available yet. The difference between this library and tensorflow-probability is we make use of custom ops written in c++, and building those shared libraries to work well with Tensorflow inside Windows has had issues; plus, the lengthy build times on Windows has made iterating on these issues slow. While the next beta release (this week) will not include Windows, we would like for the next release to include it.
Source.

How to resolve version compatible error for python 3.6

I need to install matplotlib on Python 3.6.2 but when trying to install it getting this error (installing matplotlib package for designing the graphs.)The error is :-
Could not find a version that satisfies the requirement install (from versions: )
No matching distribution found for install”
operating system is Windows 10 -64 bit.
I tried to install the package from same link shared as https://www.lfd.uci.edu/~gohlke/pythonlibs/ .
but the same error appears.
I tried to install from command line plus from blue screen command python packagename.setup and it ended up throwing mentioned error.
it seems for python version 3.6.2 package matplotlib version 3.0.2 can not be installed because each time same error keeps populating as mentioned in previous post.
Can we use a similar other package for pie charts or graphs etc. as matplotlib version 3.0.2 is not getting installed because of mentioned error?
Have you tried installing it with "python3 -m pip install matplotlib"? Matplotlib should work with your Python version, maybe you are accidentally trying to install it for an older Python version.

Categories