Unable to install tensorflow==2.0.0beta1: wrapt conflict - macos

I want to install tensorflow2.0.0 but I can't even install tensroflow1.14.0.
I am using macbook pro. I kept running into problems that some packets version are not compatible. I then tried to uninstall certain packets then reinstall them but it didn't work.
Error message:
ERROR: thinc 6.12.1 has requirement msgpack<0.6.0,>=0.5.6, but you'll have msgpack 0.6.1 which is incompatible.
ERROR: thinc 6.12.1 has requirement wrapt<1.11.0,>=1.10.0, but you'll have wrapt 1.11.2 which is incompatible.
Installing collected packages: wrapt, tensorflow
Found existing installation: wrapt 1.10.10
ERROR: Cannot uninstall 'wrapt'. It is a distutils installed project and thus we cannot accurately determine which files belong to it which would lead to only a partial uninstall.

Execute the below command:
pip install wrapt==1.10.0 --ignore-installed

Related

pip install IBM_DB does not work on Ubuntu 22.04 python 3.8

I am trying to install ibm_db v3.1.2 on python 3.8.13 Ubuntu 22.04 (5.15.0-40-generic)
pip install ibm_db
Collecting ibm_db
Downloading ibm_db-3.1.2.tar.gz (1.1 MB)
|████████████████████████████████| 1.1 MB 5.5 MB/s
Installing build dependencies ... done
Getting requirements to build wheel ... done
ERROR: Could not install packages due to an OSError: [Errno 2] No such file or directory: '/tmp/tmpfv417hua/output.json'
Other commands, such as pip install numpy work as expected
Any help would be appreciated.
Edit: I was able to work around the problem using Anaconda.
conda install -c conda-forge ibm_db. Now the basic use of ibm_db
ibm_db.pconnect(connection_string, "", "")
throws the error
[IBM][CLI Driver] SQL10013N The specified library "GSKit Error: 207" could not be loaded. SQLSTATE=42724 SQLCODE=-10013
which also seems to be known, but the suggested solution does not work.
Edit 2: pip3 install 'ibm_db==3.1.1' worked, so the problem may be with 3.1.2

Error installing geopandas in python on mac m1

I'm trying to install geopandas on my M1 mac and I'm running into errors
I tried to pip install all the dependencies individually but where I'm tripping up is in the install of pyproj.
I installed PROJ using brew install proj and that worked fine
When I try to pip install pyproj, I get the follow error
Building wheels for collected packages: pyproj
Building wheel for pyproj (pyproject.toml) ... error
error: subprocess-exited-with-error
× Building wheel for pyproj (pyproject.toml) did not run successfully.
│ exit code: 1
╰─> [12 lines of output]
PROJ_DIR is set, using existing PROJ installation..
running bdist_wheel
running build
running build_py
running build_ext
building 'pyproj._geod' extension
pyproj/_geod.c:704:10: fatal error: 'geodesic.h' file not found
#include "geodesic.h"
^~~~~~~~~~~~
1 error generated.
error: command '/usr/bin/clang' failed with exit code 1
[end of output]
note: This error originates from a subprocess, and is likely not a problem with pip.
ERROR: Failed building wheel for pyproj
Failed to build pyproj
ERROR: Could not build wheels for pyproj, which is required to install pyproject.toml-based projects
Any help would be much appreciated
At the moment, installing geopandas on M1 macs can be achieved via conda or pip+homebrew.
GeoPandas itself is written in pure Python, so there is no issue running that on any architecture. However, it depends on other libraries that are written in other languages (C, C++) that need to be compiled specifically for M1 chips. While you could compile it yourself, I am not going to cover this option as it is not user friendly.
There are three possible sources of required libraries - pip wheels, conda-forge, and Homebrew.
When a Python package requires C dependency, it can create wheels with the dependency compiled for each system and chip architecture. See for example pygeos - https://pypi.org/project/pygeos/#files. What you need is *macosx_11_0_arm64.whl . If your package doesn't offer it, you have to find another way of installing than pip. Since GeoPandas requires shapely and fiona (among others) that do not have these wheels, you should look elsewhere - either on conda-forge or Homebrew. Below are both options tested as of today.
Conda and conda-forge way (recommended)
Conda-forge currently has all packages geopandas needs
Install M1 version of miniforge or mambaforge. It can be downloaded from here - https://github.com/conda-forge/miniforge.
conda install -c conda-forge geopandas pygeos
Note: if you install x86 (Intel) version of conda, it will run under Rosetta2 and install all packages using x86 architecture, meaning that everything will run under emulation. Try to avoid that.
Pip and Homebrew way
Homebrew can install C libraries compiled for M1. Python packages will find and use them.
Using an environment with Python 3.9
Install shapely:
brew install geos
export DYLD_LIBRARY_PATH=/opt/homebrew/opt/geos/lib/
pip install shapely
DYLD_LIBRARY_PATH is needed for shapely to find GEOS installation.
Install fiona:
brew install gdal
pip install fiona
Install pyproj:
brew install proj
pip install pyproj
Install geopandas and pygeos for speedups:
pip install pygeos
pip install geopandas
Note that this is a copy&paste of my own explanation given in https://github.com/geopandas/geopandas/issues/1816#issuecomment-1003093329.
Related https://github.com/pyproj4/pyproj/issues/1027
I was stuck with the same problem, I also tried setting the environment values for PROJ_DIR, PROJ_LIBDIR, PROJ_INCDIR but perhaps setting the values is causing the error, so closed the terminal and tried again and was able to install correctly

Getting the error "No matching distribution found for httpstan"

When I try to install auto-ts package(pip install auto-ts) in Anaconda prompt, i am getting the following error message.
ERROR: Could not find a version that satisfies the requirement httpstan<4.5,>=4.4 (from pystan>=2.14->fbprophet->auto-ts) (from versions: 0.2.5, 0.3.0, 0.3.1, 0.4.0, 0.5.0, 0.6.0, 0.7.2, 0.7.3, 0.7.5, 0.7.6, 0.8.0, 0.9.0, 0.10.1, 1.0.0)
ERROR: No matching distribution found for httpstan<4.5,>=4.4 (from pystan>=2.14->fbprophet->auto-ts)
I have also tried with the following command and upgraded the pip but faced same problem.
Note: I also got No matching distribution error for the below commands. Anybody faced the same issue?
pip install fbprophet
pip install pystan==2.17.1.0
The problem arises from missing wheel formats in older versions of pip. A simple pip update should solve the issue.
pip install -U pip

Trouble using PIP Install

Having trouble installing any packages or upgrading through PIP install. basically i want to install packages for Data Science. Not able to use CONDA either.
Error I got-
ERROR: Could not find a version that satisfies the requirement menuinst (from conda) (from versions: none)
ERROR: No matching distribution found for menuinst (from conda)
WARNING: You are using pip version 19.2.3, however version 20.1.1 is available.
You should consider upgrading via the 'python -m pip install --upgrade pip' command.

Error when install autokeras on Windows 10

I tried to install autokeras (pip install autokeras) on my windows10 computer but got the following errors:
tensorflow-gpu 1.9.0 has requirement tensorboard<1.10.0,>=1.9.0, but you'll have tensorboard 1.10.0 which is incompatible.
tensorflow 1.10.0 has requirement numpy<=1.14.5,>=1.13.3, but you'll have numpy 1.15.4 which is incompatible.
Installing collected packages: scikit-learn, unidecode, pandas, inflect, tqdm, imageio, tensorboard, tensorflow, opencv-python, lightgbm, nltk, lws, joblib, librosa, networkx, cloudpickle, toolz, dask, PyWavelets, scikit-image, chardet, idna, urllib3, requests, autokeras
Found existing installation: scikit-learn 0.18.1
Cannot uninstall 'scikit-learn'. It is a distutils installed project and thus we cannot accurately determine which files belong to it which would lead to only a partial uninstall.
My python is 3.6.5, numpy 1.12.0 & 1.15.4, tensorboard 1.9.0, tensorflow-gpu 1.9.0.
Is the gpu version of tensorflow a problem for autokeras?
I would appreciate it a lot if someone can help me to solver this problem.
I had a similar problem when installing tensorflow-gpu on linux. Your tensorboard and numpy are too recent, meaning they are incompatible.
Your best bet is to set up a virtual environment (use virtualenv), install tensorboard 1.9.0 and numpy 1.13.3 and specify those for the virtual environment. Run the virtual environment and install tf-gpu in there and it should work.

Resources