Continue training
Every simulo run starts a fresh run: submitting the exact same file and
parameters while that job is still queued or running returns the existing
job, but once it has ended, submitting the same command again starts a new
job, training from scratch with nothing carried over. To keep training a
policy you already have, name one of its checkpoints with --from.
1. Choose a checkpoint
Section titled “1. Choose a checkpoint”simulo policy listThe table shows each of your policies with its status, its checkpoints and
its best reward. Add --org to include policies trained by others in your
organization. Any member can continue from any of the organization’s
policies.
A checkpoint reference is the policy ID, a colon, and the checkpoint kind:
policy_brisk-heron-4f8k2m:bestis the checkpoint with the highest mean episode reward seen during training.policy_brisk-heron-4f8k2m:latestis the most recent checkpoint.
The kind is required. The policy must also be sealed, which happens when its training job ends, whether it completed, failed, was cancelled or timed out. A policy whose job stopped early keeps the checkpoints it saved before it stopped, so you can continue from those too.
2. Submit with --from
Section titled “2. Submit with --from”Pass the checkpoint to simulo run on the same training file:
simulo run train.py --from policy_brisk-heron-4f8k2m:latest --max-iterations 900The header names the new job, its new policy, and where it starts:
TRAIN job_quiet-lynx-2b7h5cPolicy: policy_quiet-lynx-2b7h5c, starting from policy_brisk-heron-4f8k2m:latest (iteration 600)The job downloads the checkpoint, checks its digest, and resumes training
from it. Its log shows Resumed from seed checkpoint at iteration 600, and
the iteration count carries on from 601.
--max-iterations is the total number of iterations, counting the ones the
checkpoint already has. Here the checkpoint covers 600, so the job trains 300
more. If you ask for no more than the checkpoint already covers, the job
fails with a message that says so:
The seed checkpoint already covers 600 iterations, which is >= the requested max_iterations=600 — there is nothing to train. Raise --max-iterations above 600 to continue training the seeded policy, or run fresh (without --from).What you get
Section titled “What you get”- A new job and a new policy. The source policy never changes.
- Only new checkpoints. The new policy’s
bestandlatestcome only from checkpoints the new job saves. The checkpoint you started from stays part of the source policy. - A record of where it started.
simulo policy list --jsonshows it in the new policy’sstarted_fromfield.
Change the task between runs
Section titled “Change the task between runs”You can edit task.py before you continue, for example to change the
reward. Keep the number of observation values (observation_dim) and action
values (action_dim) the same. If either changes, the checkpoint no longer
fits the task, and the job fails at start with Incompatible checkpoint; refusing to resume, naming the value that differs.
When --from is refused
Section titled “When --from is refused”The CLI checks the reference before it uploads anything:
| You typed | What happens |
|---|---|
A job ID, such as --from job_brisk-heron-4f8k2m:best |
job_brisk-heron-4f8k2m is a job; did you mean policy_brisk-heron-4f8k2m:best? |
No kind, such as --from policy_brisk-heron-4f8k2m |
name a checkpoint: policy_x:best or policy_x:latest |
--from on a file whose job isn’t type="train" |
--from works only on a training file (@app.job(type="train")); play.py holds a play job. To play a policy, use --policy policy_x:best. |
--from while not signed in |
The CLI refuses, because only the Simulo cloud can look up the checkpoint. Run simulo login first. |
The platform then checks that the policy exists in your organization, that it is sealed, and that it has the checkpoint you named. A policy in another organization is reported as not found.