1
votes

I'm a little confused with package install in anaconda environment.

I can install my python packagse in the following ways.

  1. open anaconda prompt and do : conda install tensorflow
  2. launch an jupyter notebook from anaconda prompt, choose the default python kernel, and do: !pip install tensorflow

Can someone tell me what is the difference between these two cases? Where are the python packages installed? What happens when I pip install python packages in default kernel in jupyter notebook?

I was able to install tensorflow in jupyter notebook in default kernel (python3), but trying to import tensorflow give me module note found error. Does anyone know why that happened? What is happening under the hood? Very much appreciate any help to clarification.

1

1 Answers

0
votes

pip is the default package manager that ships with python. Conda is also a package manager, but it is third party. Conda was made especially for data science libraries. Libraries installed with conda usually give much better performance than pip. In pip, the packages are stored in python/scripts and conda stores them at /anaconda/pkgs/. As for the module not found error. I would need more information about it, but you can check out this video. I learnt how to install TensorFlow here and would highly recommend it.