When trying to install the python librosa package with the pip install librosa --user, I get the following error:
...
Collecting audioread>=2.1.9
Using cached audioread-3.0.0.tar.gz (377 kB)
ERROR: Error [WinError 5] Access is denied while executing command python setup.py egg_info
Preparing metadata (setup.py) ... error
ERROR: Could not install packages due to an OSError: [WinError 5] Access is denied
Check the permissions.
This error happens if I run the command from the CMD ran as administrator, and I have also tried restarting the computer and running the command from another shell.
Related
I get the following error when trying to install packages using pip:
ERROR: Could not install packages due to an EnvironmentError: [Errno 2] No such file or directory: 'C:\\SnapVolumesTemp\\MountPoints\\{45c63495-0000-0000-0000-100000000000}\\{E8720320-8733-4E3E-B117-53FE443000AC}\\SVROOT\\Users\\heijd_de\\AppData\\Local\\Temp\\pip-install-hwdp4ddr\\imbalanced-learn\\imblearn/under_sampling/_prototype_generation/tests/test_cluster_centroids.py'
I am not really sure what this directory is. Someone knows how to solve this? I get this error for installing imblearn and plotly for example. When trying to upgrade pip I get this error:
ERROR: Could not install packages due to an EnvironmentError: [WinError 145] The directory is not empty: 'C:\\SnapVolumesTemp\\MountPoints\\{45c63495-0000-0000-0000-100000000000}\\{E8720320-8733-4E3E-B117-53FE443000AC}\\SVROOT\\Users\\heijd_de\\Anaconda3\\envs\\gdal_env\\Lib\\site-packages\\~ip\\_vendor\\urllib3\\packages\\ssl_match_hostname\\__pycache__'
Regards,
Dante
This question already has answers here:
Python - PIP install trouble shooting - PermissionError: [WinError 5] Access is denied
(20 answers)
Access is denied when trying to pip install a package on Windows
(9 answers)
Closed 1 year ago.
I wanted to upgrade pip for installing libraries to learn machine learning. But i am unable to do so.
C:\Users\adith>pip install --upgrade pip
Collecting pip
Downloading pip-21.0.1-py3-none-any.whl (1.5 MB)
|████████████████████████████████| 1.5 MB 211 kB/s
Installing collected packages: pip
Attempting uninstall: pip
Found existing installation: pip 20.2.3
Uninstalling pip-20.2.3:
Successfully uninstalled pip-20.2.3
ERROR: Could not install packages due to an EnvironmentError: [WinError 5] Access is denied: 'C:\\Users\\adith\\AppData\\Local\\Temp\\pip-uninstall-40mydp3z\\pip.exe'
Consider using the `--user` option or check the permissions.
I am getting the above error. Any help would be very much appreciated. Thanks!
There are two ways to go about this:
* (Recommended way) is to just append the --user flag to the command you are trying to run, so you would run pip install --upgrade pip --user
or
* open cmd as an administrator and run that command
..................................................................................................................................
The reason this happened is because the folder you are trying to install pip is a folder that requires admin privileges to access.
Next time you should pay attention to what the error message says.
Most of the time the error message is self explanitory and there is no need to post a new question on S.O.
I am trying to install TensorFlow in windows.
Using pip command:
pip install tensorflow
But I'm getting this error message:
Could not install packages due to an EnvironmentError: [Errno 2] No such file or directory: 'C:\\Users\\naray\\AppData\\Local\\Packages\\PythonSoftwareFoundation.Python.3.8_qbz5n2kfra8p0\\LocalCache\\local-packages\\Python38\\site-packages\\tensorflow_estimator\\python\\estimator\\canned\\linear_optimizer\\python\\utils\\__pycache__\\sharded_mutable_dense_hashtable.cpython-38.pyc'
Can someone help me solve this error?
An error happens while installing tensorflowjs, it's ok to install other packages, just this package ends up with failure.
I tried to pip install --user pyspider, failed.
I upgraded pip version, still failed.
I installed tf_nightly module first and run 'pip install tensorflowjs', still failed.
C:\Users\Jingyi>pip install tensorflowjs
Collecting tensorflowjs
Using cached https://files.pythonhosted.org/packages/79/29/35e1aa467436ff46b98df65a08c49faaedb3429e1c512d1d90fe308040a0/tensorflowjs-1.0.1-py3-none-any.whl
Collecting numpy==1.15.1 (from tensorflowjs)
Using cached https://files.pythonhosted.org/packages/fb/7d/f8b97d97809f184d90faf320fa8e2e7eac994844c5e6c57adbed1283e9e9/numpy-1.15.1-cp36-none-win_amd64.whl
Collecting six==1.11.0 (from tensorflowjs)
Using cached https://files.pythonhosted.org/packages/67/4b/141a581104b1f6397bfa78ac9d43d8ad29a7ca43ea90a2d863fe3056e86a/six-1.11.0-py2.py3-none-any.whl
Collecting tf-nightly-2.0-preview>=2.0.0.dev20190304 (from tensorflowjs)
Using cached https://files.pythonhosted.org/packages/4c/13/8fa7c91176d299759487d90ab201256941b43a48ecbf033a2a726f4dafce/tf_nightly_2.0_preview-2.0.0.dev20190509-cp36-cp36m-win_amd64.whl
ERROR: Could not install packages due to an EnvironmentError: [Errno 2] No such file or directory: 'C:\\Users\\Jingyi\\AppData\\Local\\Temp\\pip-install-4ytziwpr\\tf-nightly-2.0-preview\\tf_nightly_2.0_preview-2.0.0.dev20190509.data/purelib/tensorflow/include/tensorflow/include/external/eigen_archive/unsupported/Eigen/CXX11/src/Tensor/TensorSyclConvertToDeviceExpression.h'
I expect to install tensorflowjs successfully.
It was caused by windows path length limitation, you can try below:
Hit the Windows key, type gpedit.msc and press Enter.
Navigate to Local Computer Policy > Computer Configuration > Administrative Templates > System > Filesystem.
Double click the Enable Win32 long paths option and enable it.
Then restart computer and it works
Original answer here
You can create a virtualenv and install tensorflow within this.
First create a virtualenv:
python3 -m venv envname
Next you have to activate it
source envname/bin/activate
Then install the package
pip install pyspider
When you use a virtualenv you don't nedd the --user flag.
Using a virtualenv is always a better way when you are working locally with python projects.
I'm getting Error while installing watson package in anaconda by
pip install --upgrade watson-developer-cloud==0.26.1
even though I run the command prompt as administrator mode!(in windows 10, Python 3.6.3)
Collecting watson-developer-cloud==0.26.1
.
.
.
.
.
.
PermissionError: [Errno 13] Permission denied: 'C:\ProgramData\Anaconda3\Lib\site-packages\_cffi_backend.cp36-win_amd64.pyd'
Try out to install as a user:
pip install --upgrade watson-developer-cloud==0.26.1 --user
You can also try to use environments.
They are also useful, if you plan to migrate your stuff to the Cloud