I want to install GSEApy on Anaconda (I use 64bit Windows 10).
https://bioconda.github.io/recipes/gseapy/README.html
https://anaconda.org/bioconda/gseapy
But I get this error:
C:\Windows\system32>conda install gseapy
Using Anaconda Cloud api site https:// api.anaconda.org
Fetching package metadata ...........
Solving package specifications: .
Error: Package missing in current win-64 channels:
- gseapy
You can search for packages on anaconda.org with
anaconda search -t conda gseapy
How can I solve this?
You need to use a channel that has a win-64 version. Use:
conda install -c bioninja gseapy
The option -c or --channel allows to specify a channel.
You can also add a channel permanently via:
conda config --add channels bioninja
This creates a file .condarc in your home directory (on Windows C:\Users\<username>):
channels:
- bioninja
- defaults
You can modify this file manually. The order of the channels determines
their precedence.
Note: Files with a leading . might not be displayed
by certain file browsers. You might need to change settings to display these
files accordingly.
You can find out if a package exits for your platform by searching on Anaconda. Just type gseapy in the search field and you should see the available packages. The column "Platforms" shows if a "win-64" version exists.
Now you could install lastest gseapy through bioconda, too
conda install -c bioconda gseapy
Check the latest version of Keras from the Anaconda Cloud website
https://anaconda.org/search?q=keras
Use command:
conda install -c conda-forge keras=<version>
Maybe it need you to specify a detalied version,so you can just find a version support your environment in Anaconda Clound,just a line of command like "conda install -c dhirschfeld protobuf=3.0.0a3.post418+g0cb84ee ",I select this and it works.
Related
I want to update my conda environment to python3.7.7. However
conda install python=3.7.7
results in
PackagesNotFoundError: The following packages are not available from current channels:
- python=3.7.7
Current channels:
- https://repo.anaconda.com/pkgs/main/osx-64
- https://repo.anaconda.com/pkgs/main/noarch
- https://repo.anaconda.com/pkgs/r/osx-64
- https://repo.anaconda.com/pkgs/r/noarch
I have the correct version installed locally:
$ /usr/local/bin/python3 --version
Python 3.7.7
So how can I get conda to use that?
Given that python 3.7.7 was released on March 10 (6 days ago), I think it's simply a matter of it not having been packaged into a conda package yet. There is usually a delay between a release and it having been conda packaged and tested.
If you are willing, and have the time, you could help contributing to https://conda-forge.org/
nb: Often packages arrive a little earlier into conda-forge (although 3.7.7 is not yet there), and if that would be the case, you can add conda forge to your channel list
$ conda install python=3.7.7 -c conda-forge
Edit:
To see which packages are available, you can use
$ conda search python
or
$ conda search python -c conda-forge
I'm not sure if you can get conda to use that python version. Conda needs to have control over it in order to effectively manage it. Conda does not control that python file.
You can try standard virtual environments. This is similar to conda virtual environments, but you only need python. Recommended way: In your case you would navigate to the folder for your project (using cd in the terminal) and type: /usr/local/bin/python3 -m venv venv. You have just created a folder named venv (the second venv in that code) that will contain files needed for your virtual environment. To activate do: source venv/bin/activate. Now you can proceed to pip install [package_names] (not conda as we are not in a conda environment) packages you want. They will only install into this folder. See link for more information.
I am new to python and I am trying to install new packages in Anaconda. I am using anaconda prompt and Windows 10.
Can you please explain what is the difference between conda install with -c anaconda and without it? For example conda install -c anaconda mysqlclient and conda install mysqlclient.
Which is better to use when and why?
conda, as you know is a package manager that can install packages to your machine. If you do conda install, it needs a place to search for these packages to download them from. For conda, this is solved with the concept of channels, which are, as #David Kabii has pointed out, like repositories that can exist either locally/a network location or be a url. By default, conda install will try to download packages from repo.anaconda.com, specifically on windows, these locations are searched by default:
https://repo.anaconda.com/pkgs/main/win-64
https://repo.anaconda.com/pkgs/main/noarch
https://repo.anaconda.com/pkgs/r/win-64
https://repo.anaconda.com/pkgs/r/noarch
https://repo.anaconda.com/pkgs/msys2/win-64
https://repo.anaconda.com/pkgs/msys2/noarch
More information on the difference can be found in the docs on using default repositories.
Now if you go to www.anaconda.org and search for a package, let's say numpy, you will see that it is available from different channels. You should only worry about those in case a package is not available from the default channels. This you can also check by running conda search <package name> which will list all available versions in the currently configured channels.
Coming to your question. The -c options specifies an additional channel to search first which is needed if a package is not available from default channels. E.g. some bioinformatics tools are only available by specifying -c bioconda. For those packages that are available from the default channels you should not specify anything and using -c anaconda will make no difference, as the anaconda channel is only a mirror of the default ones and should not be used (see the channel description):
This channel is used internally for mirroring. You should very much prefer https://repo.anaconda.com, which is conda's default and needs no "-c" setting.
When you use the -c option, you are specifying the channel from which to get the package. The default is -c anaconda, so they are similar. To use packages built locally, you would use -c local.
Here is a link for more info:
Docs explaining usage of conda install
Is it possible to install glmnet in python 2 or 3 (windows machine):
Using this:
conda install glmnet
produces this error:
packages not found error: ... not available from current channels
Does anyone experience similar problems?
edit: Using pip gave me this error:
failed with error code 1
According to the anaconda cloud website glmnet package the available version for mac and Ubuntu users. It's not available yet for Windows users. The only way is to install the r version of it with anaconda r-glmnet.
conda install -c r r-glmnet
The documentation says you should install using either:
conda install -c conda-forge glmnet
or
pip install glmnet
EDIT:
It seems there are multiple "glmnet" packages for python that go by different names. Here is another: https://github.com/conda-forge/r-glmnet-feedstock
To install that one you just do:
conda install -c conda-forge r-glmnet
Either way, the key is to specify which channel you want to install from using the -c flag followed by the channel name (conda-forge), and then the correct name for the package you want
Alternatively, instead of specifying the channel name every time you want to install something, you can add conda-forge to your config with:
conda config --add channels conda-forge
Then you no longer need to use -c and can just install packages with:
conda install r-glmnet
or conda install glmnet
This is how I succeeded:
You need a fortran compiler. If you're a student (like me), you can get it from intel for free: https://software.intel.com/en-us/qualify-for-free-software/student
Clone the repo for https://pypi.org/project/glmnet/ from https://github.com/civisanalytics/python-glmnet.
Launch the fortran compiler environment in a command prompt
Navigate to the folder where you cloned the repo
Activate the conda environment you want to install glmnet into
Run python setup.py install
The package will now be available as glmnet_python
I have a valid pip package that I am trying to put onto the Anaconda.org server. I created the meta.yaml file with conda skeleton, which includes the requirement for pint (no particular version selected, so it should default to the latest.) However, when I attempt to build the package with conda build, conda raises this error:
raise DependencyNeedsBuildingError(exc, subdir=subdir)
conda_build.exceptions.DependencyNeedsBuildingError: Unsatisfiable dependencies for platform osx-64: ['pint']
However, there is a pint that is built for osx-64... both in conda and in pip and on my machine - it's the one I use to run my pip package. What repository is conda hunting through to find that requirement and how can I specify the correct pint to use in meta.yaml?
Conda is hunting through the channels in your configuration, which you can view with the command
conda config --get channels
(or conda config --show). Conda build always installs packages from the repositories (which is to say it doesn't rely on packages you have installed locally) because that is what a general user will do when they install your package. In your case, you need to add a channel to pick up the pint package; you can find a suitable channel by searching on Anaconda.org, and in this case, the conda-forge channel (among others, but that's the one I'd recommend) has the pint package. You can add the channel to your configuration with
conda config --add channels conda-forge
or you can use it for this single build with the -c option to conda build:
conda build -c conda-forge your_package_name
See conda-build for more information.
I am trying to install python-qutip to run on IPython notebook, which I have configured to run using the conda path variables . Qutip is an extremely popular (and useful) open-source package to simulate open quantum suystems.
With
conda install python-qutip
or
pip-install python-qutip
I get Error: No packages found matching: python-qutip (as expected). Same thing with
pip install python-qutip
As a quick 'n dirty solution, Is there some way to add the jrjohansson/qutip-releases repository to my conda library?
Alternatively, is it possible to install manually as in: sudo python setup.py install and add the installation directory to the conda path?
I figure you've probably solved this at this point but for any wandering search-engine travelers:
In addition to specifying a channel for a singular install, anaconda's docs give this method for adding a channel to your user's conda config(with conda>=4.1):
conda config --add channels new_channel
You can also see the channels you currently have added in ~/.condarc or by running conda config --show
For this particular case, you might do something like:
conda config --add channels jrjohansson
conda install python-qutip
If you're installing packages from a particular channel frequently(e.g. from conda-forge), this can be pretty useful.
Hope it helps :)
If you search anaconda.com you find the following:
Using binstar api site https://api.anaconda.org
Name: qutip
Summary: QuTiP: The Quantum Toolbox in Python
Access: public
Package Types: conda
Versions:
+ 3.0.1
+ 3.0.0
+ 3.1.0
To install this package with conda run:
conda install --channel https://conda.anaconda.org/jrjohansson qutip
The last line works for me (OpenSuse 13.1, miniconda).
I think the easiest way to install qutip is the following
pip install qutip
This worked for me.
(It could be pip3 install qutip instead.)
Assuming you have conda-build installed, you can try building the conda recipe (currently on a fork):
git clone https://github.com/jrjohansson/conda-recipes.git
cd conda-recipes
conda build qutip
conda install --use-local qutip
Didn't work for my env (ubuntu saucy) but I didn't try too hard. Maybe it will work for you!