Difference between revisions of "Jupyter Notebooks"

From UFRC
Jump to navigation Jump to search
Line 11: Line 11:
 
* '''[[Jupyter OOD|Jupyter via Open on Demand]]''': An easy method to start a Jupyter Lab server that offers additional configuration options beyond the dropdown available in JupyterHub. Jupyter via OOD allows user configurable resource requests, group selection and other options.
 
* '''[[Jupyter OOD|Jupyter via Open on Demand]]''': An easy method to start a Jupyter Lab server that offers additional configuration options beyond the dropdown available in JupyterHub. Jupyter via OOD allows user configurable resource requests, group selection and other options.
 
* '''[[Remote Jupyter Notebook|Batch job submission]]''': This page details methods to submit a batch job and connect via ssh tunnels.
 
* '''[[Remote Jupyter Notebook|Batch job submission]]''': This page details methods to submit a batch job and connect via ssh tunnels.
 +
 +
=Accessing Blue and Orange Directories=
 +
At first, Jupyter only has access to your home directory (<code>/home/<i>gatorlink</i></code>). In order to access directories outside of your home, it is necessary to add links to those directories using the command line. These links are similar to aliases or shortcuts on your computer. Common directories to add are your groups' <code>/blue</code> and <code>/orange</code> directories.
 +
 +
==Open a Terminal==
 +
[[File:Jupyter Launcher Terminal.png|300px|frameless|right]]
 +
We will need a terminal to run the commands below. You can use an ssh client, the OOD Shell Access or launch a Terminal within your Jupyter Server. The image on the right shows the Terminal Launcher button at the bottom of the Launcher panel in JupyterLab. If needed, you can open the Launcher with the '+' icon in the top left or from the File menu, select New Launcher.
 +
 +
==Create the Link==
 +
The specific type of link we want to create is referred to as a ''symbolic link'' or ''symlink''.  The format of the command used to create this link is <code>ln -s <i>path_to_link_to name_of_link</i></code>.
 +
* In general, we recommend making a link to your group's directory. This allows you to use the group's ''share'' folder and more easily collaborate with others in the group than if you made the link to your own folder within the group directory.
 +
* Since people are often in multiple groups, we recommend naming the link with the convention <code>blue_<i>group</i></code>. This allows for multiple links to each group directory.
 +
* The <code>id</code> command will show you the groups you are a member of:
 +
[agator@login4 ~]$ id
 +
uid=12345(agator) gid=12345(gator-group) groups=12345(gator-group),12346(orange-group),12347(blue-group)
 +
[agator@login4 ~]$
 +
* The commands below show the commands needed to change directories to your home directory (<code>cd</code>) and create links to the fictional gator-group <code>/blue</code> and <code>/orange</code> directories.
 +
[agator@login4 ~]$cd
 +
[agator@login4 ~]$ln -s /blue/gator-group blue_gator-group
 +
[agator@login4 ~]$ln -s /orange/gator-group orange_gator-group
 +
 +
Then, you'll see 'blue_gator-group' or 'orange_gator-group' as a folders in your home directory in JupyterLab and will be able to double-click on those to browse the directories.

Revision as of 14:25, 22 April 2021


Jupyter Notebooks are only accessible from within the UF network. Use the VPN if off campus.
Jupyter.png

Jupyter Notebooks are a popular web-based development environment for teaching, testing and development and running code. Notebooks allow seamless integrations of live code, richly formatted text, images, visualizations, cleanly formatted equations and more. Jupyter supports many programming languages, but is most often associated with Python.

UF Research Computing offers several methods to run Jupyter. This page provides general information about Jupyter, Jupyter Notebooks and Jupyter Lab. For details on starting Jupyter on HiPerGator, please see the pages below for detailed information on each option.

  • JupyterHub: An easy, one click option to start a Jupyter Lab server with resources selected from a simple dropdown menu. All JupyterHub jobs run using your primary group's resources.
  • Jupyter via Open on Demand: An easy method to start a Jupyter Lab server that offers additional configuration options beyond the dropdown available in JupyterHub. Jupyter via OOD allows user configurable resource requests, group selection and other options.
  • Batch job submission: This page details methods to submit a batch job and connect via ssh tunnels.

Accessing Blue and Orange Directories

At first, Jupyter only has access to your home directory (/home/gatorlink). In order to access directories outside of your home, it is necessary to add links to those directories using the command line. These links are similar to aliases or shortcuts on your computer. Common directories to add are your groups' /blue and /orange directories.

Open a Terminal

Jupyter Launcher Terminal.png

We will need a terminal to run the commands below. You can use an ssh client, the OOD Shell Access or launch a Terminal within your Jupyter Server. The image on the right shows the Terminal Launcher button at the bottom of the Launcher panel in JupyterLab. If needed, you can open the Launcher with the '+' icon in the top left or from the File menu, select New Launcher.

Create the Link

The specific type of link we want to create is referred to as a symbolic link or symlink. The format of the command used to create this link is ln -s path_to_link_to name_of_link.

  • In general, we recommend making a link to your group's directory. This allows you to use the group's share folder and more easily collaborate with others in the group than if you made the link to your own folder within the group directory.
  • Since people are often in multiple groups, we recommend naming the link with the convention blue_group. This allows for multiple links to each group directory.
  • The id command will show you the groups you are a member of:
[agator@login4 ~]$ id
uid=12345(agator) gid=12345(gator-group) groups=12345(gator-group),12346(orange-group),12347(blue-group)
[agator@login4 ~]$ 
  • The commands below show the commands needed to change directories to your home directory (cd) and create links to the fictional gator-group /blue and /orange directories.
[agator@login4 ~]$cd
[agator@login4 ~]$ln -s /blue/gator-group blue_gator-group
[agator@login4 ~]$ln -s /orange/gator-group orange_gator-group

Then, you'll see 'blue_gator-group' or 'orange_gator-group' as a folders in your home directory in JupyterLab and will be able to double-click on those to browse the directories.