Long runs
nido exec waits until the command ends. For runs of more than a few minutes, start them with
--detach. nido returns at once and names the log:
nido exec train --detach -- bash -c "cd /sandbox/vision && python train.py"
nido exec train -- tail -f /sandbox/.nido/jobs/20261115-093012-417.log
nido exec train -- nvidia-smi
The run goes on when your terminal closes; stop following the log with Ctrl-C. A job started
with & instead stops when nido exec ends. --detach needs nido 0.7.3 or newer: nido update.
As a task file
The same training as a task, so that nido run creates the sandbox, uploads the folder, trains
and brings output/ back:
---
title: Train the shape detector
x-nido:
gpu: l4
command: ["bash", "-c", "uv pip install onnx onnxslim onnxruntime && python train.py"]
network: [github.com, release-assets.githubusercontent.com, pypi.org, files.pythonhosted.org]
output: output/
---
Fine-tune YOLO on the images in shapes/ and export the model to ONNX.
cd vision
nido run
nido rm vision
The sandbox is named after the folder and keeps running after the run, so remove it when you are done.