Can I use jupyter notebooks (or astropy, matplotlib, scipy) with CIAO-4.10?
In order to use jupyter notebooks with CIAO, users must install the the jupyter package (and all supporting packages) into their CIAO installation.
Following this procedure has the potential to corrupt (break) your existing CIAO installation. You will be installing additional packages into the same directories as where CIAO is installed. Those packages may introduce conflicts with CIAO analysis tasks.
You must have write-access to the CIAO installation directories.
Follow these instructions at your own risk!
Requirements: Linux using the Python 3.5 edition of CIAO. This will not work with any of the Python 2.7 editions, nor with any of the macOS/OSX builds. The CXC does not have specific advice for Python 2.7 nor macOS/OSX users.
First, determine if you have a compatible version of libssl.so.1.0 on your system (more information about this is available in the Python bugs page). Source the CIAO setup script and then check the following import command
unix% source /soft/ciao/bin/ciao.bash unix% python -c 'import ssl'
If this command succeeds (no error message), then you can proceed to the next step. If not, then you can see if your package manager provides libssl.so.1.0 and install it. Note: some newer Linux distributions only provide libssl.so.1.1 which is not compatible.
If the import works, then try to install jupyter using the pip module
unix% python -c 'import pip;pip.main()' install jupyter
Users can replace jupyter with matplotlib, astropy, scipy or other packages which can be installed using the pip command.
Note: since pip installs pre-compiled binaries of packages, those packages may not be 100% compatible with the version of python included in CIAO. Users will need to test those packages on their platform to see if this recipe worked.
To use jupyter it has to be executed using the ciaorun command:
unix% source /soft/ciao/bin/ciao.bash unix% ciaorun jupyter notebook
This ensures that the CIAO modules and paths are setup correctly.