How do I submit a job?¶
Users may submit jobs using the Jobs UI or the maap-py client library.
Jobs UI¶
- Open the Jobs UI from the
Jobs
menu then navigate to the Jobs UISubmit
tab.
- Select the algorithm you would like to run then enter the algorithm inputs.
- Click the
Submit Job
button. A toast will appear in the bottom right of the screen indicating whether job submission was successfull or not.
MAAP-py Library¶
- Open a Jupyter Notebook then click the
MAAP
button from the notebook toolbar. This will paste the code snippet below into your notebook.
- Provide the MAAP host. For DIT, this would be
api.dit.maap-project.org
from maap.maap import MAAP
maap = MAAP(maap_host='api.dit.maap-project.org')
- Use the
submitJob
method and provide your algorithm inputs. The example below will run therun-dps-test_ubuntu
algorithm.
maap.submitJob(identifier="test-job",
algo_id="run-dps-test_ubuntu",
version="delay10",
username="anonymous",
queue="maap-dps-worker-8gb",
input_file="https://raw.githubusercontent.com/MAAP-Project/dps-unit-test/main/README.md")
- Run the notebook to submit the job. The cell output for a job that was submitted successfully will look similar to this:
{'status': 'success',
'http_status_code': 200,
'job_id': '86fbac52-24b0-4963-8b67-59d0fc09946a'}