Skip to main content

Fine-tuning the SmolVLA Model

SmolVLA is a Vision-Language-Action (VLA) policy from Hugging Face, and its base weights are lerobot/smolvla_base. It takes multi-view images, robot state, and optional language instructions as input and outputs continuous actions. The platform registers it under the model identifier smolvla, uses the lerobot training framework, and supports LeRobot v2 and v3 datasets.

Roles and Prerequisites​

Roles​

RoleCan create a training taskDescription
AdministratorYesNot restricted by Module Permissions
Project ManagerRequires authorizationAn administrator grants Create Training Job in Module Permissions
AnnotatorRequires authorizationSame as above
AuditorRequires authorizationSame as above
CollectorRequires authorizationSame as above

Viewing training tasks and metrics requires only View Training.

Prerequisites​

ItemRequirement
Dataset versionLeRobot v2 or v3. The training service reads codebase_version in the dataset's meta/info.json to identify the version and choose the training image
Frameworklerobot
GPU memoryNo fixed lower bound; determined by batch_size, image resolution, and the freeze strategy. The vision encoder is frozen by default
DependencyThe platform's model training service is enabled with at least one training location configured; the training image must include the LeRobot training entry point lerobot-train and video decoding dependencies
Dataset structureThe directory contains meta/info.json, data/, and videos/; image fields are consistent across episodes, and the dimensions of observation.state and action are fixed
PermissionCreating requires Create Training Job; viewing requires View Training

Training Task Creation and Parameters​

Procedure​

  1. Go to Model → Training and select Create Training Job.
  2. Choose a training location: a local GPU or a cloud training location enabled by an administrator.
  3. Under Selected Model, select smolvla.
  4. Under Training Dataset, choose the data source: Export Records, an uploaded LeRobot dataset, Download Link, or Hugging Face.
  5. Set parameters in Training Parameters; the table below lists their meaning and default values.
  6. Enter Notes (optional).
  7. Select Create Training Job.

Training Parameters​

The lerobot framework first applies general training parameters:

ParameterDescriptionDefaultValid range
batch_sizeBatch size1Integer, ≥ 1
stepsTraining steps10000Integer, ≥ 1
seedRandom seed1000Integer
num_workersDataLoader processes4Integer, ≥ 1
eval_freqEvaluation interval1000Integer, ≥ 1 and not greater than steps
log_freqLogging interval100Integer, ≥ 1 and not greater than steps
save_freqCheckpoint save interval5000Integer, ≥ 1 and not greater than steps
save_checkpointWhether to save checkpointstruetrue / false

It then appends model parameters with the policy. prefix:

ParameterDescriptionDefaultValid range
policy.n_obs_stepsInput observation steps1Integer
policy.chunk_sizeAction prediction length50Integer
policy.n_action_stepsAction steps executed per call50Integer
policy.max_state_dimState vector padding dimension32Integer
policy.max_action_dimAction vector padding dimension32Integer
policy.resize_imgs_with_paddingImage preprocessing size[512, 512]Two-element tuple
policy.empty_camerasNumber of empty camera placeholders0Integer
policy.tokenizer_max_lengthMaximum tokenizer length48Integer
policy.num_stepsNumber of decoding steps10Integer
policy.use_cacheWhether to use the attention cachetruetrue / false
policy.freeze_vision_encoderWhether to freeze the vision encodertruetrue / false
policy.train_expert_onlyWhether to train only the action experttruetrue / false
policy.train_state_projWhether to train the state projection layertruetrue / false
policy.vlm_model_nameVision-language backbone modelHuggingFaceTB/SmolVLM2-500M-Video-InstructString
policy.attention_modeAttention modecross_attncross_attn, self_attn
policy.pad_language_toLanguage padding methodlongestlongest, max_length
policy.num_vlm_layersNumber of vision-language backbone layers16Integer
policy.self_attn_every_n_layersInterval for inserting self-attention layers2Integer
policy.expert_width_multiplierHidden width ratio of the action expert0.75Float
policy.optimizer_lrOptimizer learning rate1e-4Float
policy.optimizer_grad_clip_normGradient clipping threshold1.0Float
policy.scheduler_decay_stepsLearning rate decay steps100000Integer
policy.scheduler_decay_lrFinal learning rate after decay1e-5Float

Verification​

Training Monitoring​

The training details page parses metrics in the LeRobot log format and plots the curves:

MetricMeaningCriteria
stepNumber of completed training stepsIncreases step by step up to the configured steps
sampleNumber of processed samplesIncreases with step
episodeNumber of processed episodesIncreases with step
epochNumber of trained epochsIncreases with step
lossTraining lossDecreases overall
gradient_normGradient normDoes not keep growing
learning_rateCurrent learning rateChanges according to the schedule
update_time_sTime per update stepStable, does not keep growing
data_time_sData loading timeStable

Offline loss only reflects how well the model fits the training distribution. To evaluate policy performance, use the real-robot success rate under fixed initial states and varied object positions and lighting conditions.

Verification Checklist​

The training service determines the final task state from the container exit code: exit code 0 is recorded as Success, and a nonzero code as Failed.

CheckPass criteria
Task statusThe training details page shows Success and the container exit code is 0
Output directorycheckpoints/ under the output directory
CheckpointsCheckpoints lists the checkpoints, whose contents include pretrained_model/; the entry that last points to has type Final, and the rest have type Step
Metric curvesTraining Metrics plots step, loss, gradient_norm, and learning_rate
LogsReal-time Logs can be read without repeated errors

Checkpoints listed in Checkpoints can be downloaded, synced to object storage, or used to create an inference service; see Model Inference for the inference side.

Error Handling​

SymptomPossible causeActionOwner
Training fails immediately with a dataset-not-found errorThe dataset lacks meta/info.json, or the selected source path is wrongSelect the correct Export Records entry or uploaded dataset againProject Manager
Video decoding failsThe training image lacks ffmpeg or video decoding dependenciesUse the platform training image, or switch to exported MP4 video dataAlgorithm Engineer
Out of GPU memorybatch_size or image resolution is too largeLower batch_size; check policy.resize_imgs_with_paddingAlgorithm Engineer
Loss decreases but real-robot performance is poorInsufficient data coverage, or the task text does not match the actionsAdd samples with varied object positions, lighting, and initial poses; verify the task textAlgorithm Engineer
Save interval greater than training steps errorsave_freq exceeds stepsReduce save_freq to no more than stepsAlgorithm Engineer
Loss stops decreasing for a long timeUnsuitable learning rate or too little dataCheck the number of episodes in the dataset; adjust policy.optimizer_lrAlgorithm Engineer
Training location unavailableThe platform has not enabled that training location, or its GPU is unavailableSwitch to another training location; ask an administrator to check the Training ServiceAdministrator
PagePurpose
Model TrainingCreating, monitoring, and quotas for training tasks
LeRobot datasets and trainingDataset export and training overview
LeRobot v2 and v3 format differencesDifferences between the two data formats and migration
Data exportGenerate a LeRobot training package