Saturday, July 11, 2020

python and ipython has different path, modules not found



(base) CS313BQin:~ hqin$ python
Python 3.7.4 (default, Aug 13 2019, 15:17:50) 
[Clang 4.0.1 (tags/RELEASE_401/final)] :: Anaconda, Inc. on darwin
Type "help", "copyright", "credits" or "license" for more information.
>>> import sys
>>> sys.path
['', '/opt/anaconda3/lib/python37.zip', '/opt/anaconda3/lib/python3.7', '/opt/anaconda3/lib/python3.7/lib-dynload', '/opt/anaconda3/lib/python3.7/site-packages', '/opt/anaconda3/lib/python3.7/site-packages/aeosa']









import sys

sys.path.append("/opt/anaconda3/lib/python3.7/site-packages")

This solved the seaborn module loading problem in jupyter-notebook for big macbookpro

However, there is still a loading problem for libriso

Reference:
https://stackoverflow.com/questions/15514593/importerror-no-module-named-when-trying-to-run-python-script/15622021#15622021


No comments:

Post a Comment