Jobs are great for testing different aspects of a model (i.e., training on different versions of a dataset for a model that may include different labeling parameters).

Creating a Job is similar to creating a Workspace. To create a new Job go to the "Jobs" menu in your project and click "Create Job".

Note: Jobs can only execute code that is committed into the "Code" repository or you can use git clone <repository-url>  in "Shell command" field.  In the latter case, your code will be cloned into /onepanel/code/<repository-name> 

Important: The current working directory while executing a job is /onepanel/code . Datasets are mounted into /onepanel/input/datasets and any output that you want to save should be saved to /onepanel/output .

Tip: You can chain shell commands and download datasets in jobs. See Chaining Job Commands and Downloading Datasets for more information.

Tip: You can install additional python packages in jobs by adding a requirements.txt file to your code.  See Installing Packages and Dependencies for more information

Once a job is created, you will see the following tabs:

  • Log
  • Code
  • Output

Log

The "log" tab displays a realtime log of your job's progress.

Code

The "code" tab displays the exact version of code that was used for this job.

Output

The output tab contains the output files that were saved.  Please see Job Output for more information on saving and downloading job output.

Cloning Jobs

You can easily clone a job that was previously executed by clicking on the 'CLONE' button. The previous shell command will be shown but you can easily update this field.

Note: The Code, Machine Type and Environment of the previous job will be preselected for you.

Stopping Jobs

You can stop a job by clicking on the 'STOP' button on the top of the right panel.  This will immediately stop the job and save any output and log for future reference.

Creating Jobs with CLI

Create a job

onepanel jobs create <command> 
    -m <machine-type>
    -e <environment>
    -d source=<dataset>,destination=<mount-location>

List Jobs

onepanel jobs list [--all]

View Logs for a Job

onepanel jobs logs <job-id>

Example

To get started, get a list of available machine types:

onepanel machine-types list

Next, get a list of available environments:

onepanel environments list

Finally using the info from above commands, run the job:

onepanel jobs create 'python tensorflow/main.py' \
    -m gpu-8-52-1v100 \
    -e jupyter-py3-tensorflow1.11.0 \
    -d source=onepanel/mit-cbcl-streetscenes,destination=streetscenes
    -d source=onepanel/rgb-d-7scenes,destination=7scenes

To see a list of running jobs:

onepanel jobs list

And to see the logs for a particular job:

onepanel jobs logs <job-id>

Did this answer your question?