Collectives™ on Stack Overflow
Find centralized, trusted content and collaborate around the technologies you use most.
Learn more about Collectives
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
Learn more about Teams
I'm somewhat new to Python. I've used it in a bunch of projects, but haven't really needed to stray from its standard setup. I'm trying to install some new packages to get access to functions necessary for a university assignment. When I try to install, I get the following:
(base) C:\Anaconda2\Jupyter>conda install -c python-control -c cyclus slycot control
Solving environment: failed
PackagesNotFoundError: The following packages are not available from current channels:
- slycot
- control
Current channels:
- https://conda.anaconda.org/python-control/win-64
- https://conda.anaconda.org/python-control/noarch
- https://conda.anaconda.org/cyclus/win-64
And a bunch of other channels similar to that above.
I've been searching for a solution, but haven't found anything substantial. I've seen that it may be a problem with Windows, which is what I'm using it on. Past that I haven't a clue of what is going on.
Keep in mind, I don't really understand how channels and packages work, so any insight on that matter would be great too.
–
–
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 on and the community-driven conda-forge is usually a good place to start when packages are not available via the standard channels. I checked and both slycot and control seem to be available there.
–
–
–
–
–
–
Thanks, Max S. conda-forge worked for me as well.
scikit-learn on Anaconda-Jupyter Notebook.
Upgrading my scikit-learn from 0.19.1 to 0.19.2 in anaconda installed on Ubuntu on Google VM instance:
Run the following commands in the terminal:
First, check available the packages with versions
conda list
It will show packages and their installed versions in the output:
scikit-learn 0.19.1 py36hedc7406_0
Upgrade to 0.19.2 July 2018 release.
conda config --append channels conda-forge
conda install scikit-learn=0.19.2
Now check the version installed correctly or not?
conda list
Output is:
scikit-learn 0.19.2 py36_blas_openblasha84fab4_201 [blas_openblas] conda-forge
Note: Don't use pip command if you are using Anaconda or Miniconda
I tried following commands:
!conda update conda
!pip install -U scikit-learn
It will install the required packages also will show in the conda list but when try to import that package it will not work.
On the website http://scikit-learn.org/stable/install.html it is mentioned as:
Warning To upgrade or uninstall scikit-learn installed with Anaconda or conda you should not use the pip.
I was trying to install fancyimpute package for imputation but there was not luck.
But when i tried below commands, it got installed:
Commands:
conda update conda
conda update anaconda
pip install fancyimpute
(here i was trying to give command conda install fancyimpute which did't work)
–
Even i was facing the same problem ,but solved it by
conda install -c conda-forge pysoundfile
while importing it
import soundfile
–
Conda itself provides a quite detailed guidance about installing non-conda packages. Details can be found here: https://docs.conda.io/projects/conda/en/latest/user-guide/tasks/manage-pkgs.html
The basic idea is to use conda-forge.
If it doesn't work, activate the environment and use pip.
I encountered the same problem while I was working with a non-conda package named matplotlib-venn, where simple commands like conda install <package> and conda install -c conda-forge <package> both resulted in the same PackagesNotFoundError.
However, I realized that if you search your package on the conda-forge website https://anaconda.org/conda-forge, it will list out a series of commands that you can tryout. For me, the second command conda install -c conda-forge/label/gcc7 matplotlib-venn worked successfully.
Note: you may need to add conda-forge to your list of channels by using conda config --append channels conda-forge
in which case "(base)" will most probably show at the start or your terminal command prompt.
... and pip is installed in your base environment ...
which it is: $ conda list | grep pip
... then install the not-found package simply by $ pip install <packagename>