SmolVLA is a compact VLA model (500M VLM + action expert) achieving competitive manipulation at reduced compute, deployable on Ascend 910.
observation.state: float32 tensor shape=[1,6] (agent_pos 4 + extra dims), padded to max_state_dim 32 internally, device must match policy (npu:0)observation.images.camera1/2/3: float32 tensor shape=[1,3,256,256] range [0,1] -> normalized to [-1,1] via siglip; resize_imgs_with_padding to 512x512; 3 cameras required, empty_cameras=0observation.language.tokens: int64 shape=[1,48] tokenizer_max_length 48, pad_language_to max_length, vocab 49152 (SmolVLM2)observation.language.attention_mask: bool shape=[1,48]task string example: "push the cube\n" (newline ensured)action_chunk: continuous tensor shape=[1,50,4] (batch, chunk_size=50, action_dim=4) - 50-step future action horizon for MetaWorld 4-DoF (XYZ + gripper)num_steps=10, deterministic via fixed noise seed (1234), sampler fixed for CPU/NPU comparisonactions[0,0] is immediate action; remaining 49 are queued via deque for action chunkingchunk_size=50, n_action_steps=50, num_steps=10, max_action_dim=32, max_state_dim=32policy_preprocessor_step_5_normalizer_processor.safetensors)num_vlm_layers=16, expert_width_multiplier=0.75torch_npu 2.9.0 + CANN 8.5.1, device npu:0 (Ascend910_9362)bfloat16 VLM weights -> float32 before NPU move to fix torch.bucketize searchsorted NPU failure (DT_BFLOAT16 not supported, error 161002). CPU and NPU both use float32 for consistent comparison (max_abs 4.17e-06, within FP32 atol=1e-4 rtol=1e-3).observation.state, 3 cameras, noise), model params, and output action_chunk recorded as npu:0; torch.npu.synchronize() surrounds timing; CPU fallback is failure, not compatibility mode.python inference.py)[-0.4673, -0.2698, 0.1466, 0.3572] (varies with seed)npu:0, synchronize used/tmp/smolvla_metaworld), shared observations, same tokenizer, same noise seed 1234, same dtype float32, eval mode, deterministicvalidate_policy_outputs.py with atol=1e-4 rtol=1e-3max_abs=4.17e-06, mean_abs=9.1e-07, tolerance 0.0011 -> PASS (far below 1e-4 threshold)/data/adapt-npu-hf, HF_ENDPOINT https://hf-mirror.com via proxy http://127.0.0.1:7890 (NO_PROXY cleared for HF)pip install -r requirements.txt
python inference.pyDefault runs on npu:0 if available, else CPU with same deterministic synthetic batch and prints device proof.
bfloat16; forced float32 for NPU compatibility may slightly increase memory/latency vs native BF16 but fixes searchsorted support
