conda install pkg with wrong python version - anaconda

I have a conda-env, in which python --version 3.7;
when I use conda install to install some python pkgs, It always installs pkgs-py36 and updates/downgrades existing-pkgs-py37 to pkgs-py36.
Another conda-env with python=2.7 has the similar problem.
conda --version 4.5.11; and other computers work well with this conda version.

Related

What are the differences between two methods- 'conda install anaconda' and 'conda install conda-forge' to install a package through conda?

One method of installing a package through conda is-
conda install -c anaconda lxml
And another is-
conda install -c conda-forge lxml
What are the differences between these two?
In the conda install -c or conda install --channel context, anaconda and conda-forge are CHANNELs to two different package repositories.
anaconda repo is managed by Anaconda, Inc. (https://anaconda.org/), and
conda-forge repo is managed through community effort. (See https://conda-forge.org/docs/user/introduction.html for more info).

how to install fastai on windows 10

I cant seem to install the right version of torch and I cant get fast ai libraries working
I try
Python 3.7
pip3 install https://download.pytorch.org/whl/cu100/torch-1.0.1-cp37-cp37m-win_amd64.whl
pip3 install torchvision
Could not find a version that satisfies the requirement torch>=1.1.0 (from torchvision) (from versions: 0.1.2, 0.1.2.post1, 0.1.2.post2)
No matching distribution found for torch>=1.1.0 (from torchvision)
I feel like I may of downgraded my gpu when I tried conda install fast ai
and then I tried pip and it couldnt find a file C:\Users\Admin\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.7_qbz5n2kfra8p0\LocalCache\local-packages\Python37\site-packages\caffe2\python\serialized_test\data\operator_test
I finally got to the point where it said successfully installed six, pillow, and torch but torch is at 0.3 which is incompatiable.
pip3 install https://download.pytorch.org/whl/cu100/torch-1.0.1-cp37-cp37m-win_amd64.whl
pip3 install torchvision
expected to install pytorch or fastai nothing seems to work
You may try installing the course by creating a conda environment provided anaconda is already installed in your windows machine.
conda update conda
conda create -n fastai_conda python=3.6
conda activate fastai_conda
conda install fastai pytorch=1.0.0 -c fastai -c pytorch -c conda-forge
Or for installing CPU version you can use the below commands after the environment is created
conda install -c pytorch pytorch-cpu torchvision
conda install -c fastai fastai
You can check if installation went right with this command
python -m fastai.utils.show_install
You may further need to install ipykernel to use the conda environment in your jupyter notebook.For that activate environment and run the following commands:
conda install nb_conda_kernels
python -m ipykernel install --user --name fastai_v1 --display-name "fastai v1"
conda install ipywidgets

conflict while installing mayavi into anaconda

Good day,
My colleague asked my to install Anaconda and mayavi and I am novice with this topic and I decided to do the tasks on a new ubuntu installation
Here are my tasks before my issue
I fresh installed a Ubuntu 16.04
I ran all update apt-get update/upgrade
I created an user account (anna) and add it in sudo group
I loged into anna account
I downloaded Anaconda2-4.4.0-Linux-x86_64.sh for python 2.7
I installed with the command sudo bash Anaconda2-4.4.0-Linux-x86_64.sh
I installed anaconda in /opt/anaconda2 instead to the /home/anna/anaconda2 (for all user usage) and I say YES to have the line export PATH="/opt/anaconda2/bin:$PATH" in .bashrc file of anna
I run source /home/anna/.bashrc
After the anaconda installation, I could see a successful message regarding the installation
Now my colleague asked me to install mayavi and she provided me the following link mayavi
Then I simply enter the following command
conda install -c anaconda mayavi=4.5.0
And here start my problem. I can not well understand the conflict but apparently there is a conflict and I have no idea how to solve it. Here is the command and the message
anna#pc17:~$ conda install -c anaconda mayavi=4.5.0
Fetching package metadata ...........
Solving package specifications: .
UnsatisfiableError: The following specifications were found to be in conflict:
- mayavi 4.5.0* -> pyqt 4.* -> qt >=4.8.6,<5.0
- mayavi 4.5.0* -> pyqt 4.* -> sip >=4.16.4,<4.18
- navigator-updater -> pyqt >=5.6 -> qt 5.6.*
Use "conda info <package>" to see the dependencies for each package.
I have no idea what does mean the above message and how to solve me problem.
Is there depencies that I have to additionally install?
For information the above command return me this:
anna#cryospc17:~$ python --version
Python 2.7.13 :: Anaconda 4.4.0 (64-bit)
anna#cryospc17:~$ python3 --version
Python 3.5.2
Did I correctly try t install mayavi?
Thank a lot for any help you can provide me
To complete the install of mayavi, you have to first install the following depence
conda install -c anaconda vtk=6.3.0
conda install -c anaconda pyside=1.2.1
Then install mayavi
conda install -c anaconda mayavi=4.5.0
It may possible, you have to remove pyqt
conda uninstall pyqt
We finally could install anaconda and mayavi sucessfully.
I hope it help
Cheers
This might be helpfull to others. It must be anaconda for python 2.7 currently and the follows worked.
Install anaconda for python 2.7, then try the follows:
conda uninstall pyqt
conda uninstall navigator-updater
conda install pyqt=4
conda install vtk
conda install envisage
conda install pyside
conda install apptools=4.4.0
conda install mayavi

Update Software Version in Anaconda

I have installed python and many other useful tools on my Ubuntu 14.04 using Anaconda. I installed pysam (htslib interface for python) using
conda install pysam
However this installs the old version (0.6). The current version is 0.8.4. How can I install that version using conda. I don't want to use pip install pysam because I read somewhere it might cause problems.
Thanks.
Anaconda only provides version 0.6. You can install from binstar with:
conda install -c https://conda.anaconda.org/uhlitz pysam
This should give you version 0.8.3 for linux64. Other channels are also available.

I have installed virtualenv 1.9 which includes pip, but cannot install nltk

I have installed virtualenv 1.9 which includes pip, but cannot install nltk on my Mac. First it does not recognize pip as a command. Second how do I install nltk?
You should be able to run the following command to setup the virtual environment:
$ virtualenv venv
New python executable in venv/bin/python
Installing setuptools.............done.
Installing pip...............done.
Then activate the virtual environment using:
$ source venv/bin/activate
Then install nltk:
(venv)$ pip install nltk
When you are done with the virtual environment run:
$ deactivate
You may want to try installing Python using Homebrew rather than using the Python version included with the OS. With 'brew' you will not need to use virtualenv (unless you want to) because brew installs packages to /usr/local owned by you. So you can simply run 'pip install '.
Follow the installation instructions here for Homebrew. Then run:
$ brew install python
$ pip install nltk
You can install virtualenv as well if you want it.
$ pip install virtualenv

Resources