Could not install packages due to an EnvironmentError: [Errno 2] No such file or directory \\METADATA

TL;DR: Problem: Long install path Solution 1: Install the desired python package (in my case tensorflow) in the folder which has a shorter path (for example C:/my_py_packages/some_package) Solution 2: Set the registry value HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\FileSystem@LongPathsEnabled to 1 as mentioned here. Original answer: I got here by having this kind of error when I tried installing tensorflow … Read more

How do I update Anaconda?

root is the old (pre-conda 4.4) name for the main environment; after conda 4.4, it was renamed to be base. source What 95% of people actually want In most cases what you want to do when you say that you want to update Anaconda is to execute the command: conda update –all (But this should … Read more

PackagesNotFoundError: The following packages are not available from current channels:

Try adding the conda-forge channel to your list of channels with this command: conda config –append channels conda-forge. It tells conda to also look on the conda-forge channel when you search for packages. You can then simply install the two packages with conda install slycot control. Channels are basically servers for people to host packages … Read more

Using multiple Python engines (32Bit/64bit and 2.7/3.5)

Make sure to set the right environmental variables (https://github.com/conda/conda/issues/1744) Create a new environment for 32bit Python 2.7: set CONDA_FORCE_32BIT=1 conda create -n py27_32 python=2.7 Activate it: set CONDA_FORCE_32BIT=1 activate py27_32 Deactivate it: deactivate py27_32 Create one for 64 bit Python 3.5: set CONDA_FORCE_32BIT= conda create -n py35_64 python=3.5 Activate it: set CONDA_FORCE_32BIT= activate py35_64 The … Read more

Cannot install Python 3.7 on osx-arm64

No native builds available Since Python 3.8 had been released for about a year when Apple Silicon hit the market, Python 3.7 builds for osx-arm64 were never part of the regular build matrix for Conda Forge. Workaround: Emulate Immediate alternatives for using 3.7 on Apple Silicon systems would be to emulate x86_64 with Rosetta or … Read more

How to use Jupyter notebooks in a conda environment?

Disclaimer: ATM tested only in Ubuntu and Windows (see comments to this answer). Jupyter runs the user’s code in a separate process called kernel. The kernel can be a different Python installation (in a different conda environment or virtualenv or Python 2 instead of Python 3) or even an interpreter for a different language (e.g. … Read more