name: inverse layout: true class: center, middle, inverse --- # Setting up Jupyter Notebook (Nova) --- layout: false .left-column[ ### Step 1 - Login to Nova ] .right-column[ Open your terminal and SSH to Nova: ```bash ssh
@nova.its.iastate.edu ``` Enter your 2FA code and then password Request an interactive session: ```bash salloc -N 1 -n 4 -t 2:00:00 -p interactive ``` You requested a single node (computer) with 4 processors (CPUs) for 2 hours ] --- .left-column[ ### Step 1 - Login to Nova ### Step 2 - Create conda env ] .right-column[ Load the module for conda: ```bash module load miniconda3 ``` ```bash conda create -n notebook # proceed with "Y" when prompted conda activate notebook conda install -c conda-forge jupyterlab ipython \ ipykernel notebook # proceed with "Y" when prompted ``` This will install those packages in the notebook environment When you see this message: ```terminal Preparing transaction: done Verifying transaction: done Executing transaction: done ``` You are ready to proceed. ] --- .left-column[ ### Step 1 - Login to Nova ### Step 2 - Create conda env ### Step 3 - Install programs ] .right-column[ Without exiting your interactive session, activate the environment by typing ```bash conda activate notebook # Add the env to jupyter kernels python -m ipykernel install --user \ --name notebook \ --display-name "Python3 (BCB/EEOB 546)" ``` Next, install some useful packages ```bash conda install -c conda-forge \ pandas \ statsmodels \ numpy \ matplotlib \ seaborn \ scipy \ lxml \ biopython ``` ] --- .left-column[ ### Step 1 - Login to Nova ### Step 2 - Create conda env ### Step 3 - Install programs ] .right-column[ when done, you can deactivate and and exit the interactive session ```bash conda deactivate exit ``` or simply type `exit` to close the session. ```bash exit ``` ] --- .left-column[ ### Step 1 - Login to Nova ### Step 2 - Create conda env ### Step 3 - Install programs ### Step 4 - Nova OnDemand ] .right-column[ From your local computer, open a browser and go to: https://nova-ondemand.its.iastate.edu Click on the Interactive Apps tab, and select Jupyter Notebook
] --- .left-column[ ### Step 1 - Login to Nova ### Step 2 - Create conda env ### Step 3 - Install programs ### Step 4 - Nova OnDemand ] .right-column[ Fillout the form as follows: ```xml Account:
Queue:
Number of hours: <2> Memory required: <32G> Number of tasks per node: <4> GRES (only applies to GPU jobs):
Job name:
: I would like to receive an email Jupyter Notebook vs Lab:
``` Then launch the session by clicking `Launch`. Job submitted will go to the queue and wait for the resources to be available. ] --- .left-column[ ### Step 1 - Login to Nova ### Step 2 - Create conda env ### Step 3 - Install programs ### Step 4 - Nova OnDemand ] .right-column[ Once the resources are available, the job will start and you will be able to access the notebook by clicking on "Connect to Jupyter" button.
] --- .left-column[ ### Step 1 - Login to Nova ### Step 2 - Create conda env ### Step 3 - Install programs ### Step 4 - Nova OnDemand ] .right-column[ Click on the New button and select: ```bash Python3 (BCB/EEOB 546) ``` kernel. This will start a new notebook session.
] --- # Things to remember 1. You can install additional packages using `conda` package manager. They will appear in your notebook environment. - From terminal, login to Nova, request an interactive session. - Activate the `notebook` conda environment. - Install the package(s) and exit. 2. For using Jupyter Notebook, simply go to [Nova OnDemand](https://nova-ondemand.its.iastate.edu) on your browser and launch a session. 3. New packages installed while using Jupyter Notebook will not appear unless you restart the kernel. 4. Additional Kernels, isolated from the existing kernels with specific python version and packages can be installed using the same method. The kernel will appear in the dropdown menu when you click on the `New` button. --- name: last-page template: inverse ## That's all folks (for now)!