w
gcw_uQ09W7jl/fixie-ai-ultraVAD-NPU
Model Introduction
Files & versions
Pull Requests
Discussion
Analysis

fixie-ai/ultraVAD - Ascend NPU Adapted

Context-aware audio-native endpointing model adapted for Huawei Ascend 910B NPU.

  • Original: fixie-ai/ultraVAD (Ultravox Llama-8B + Whisper-large-v3-turbo)
  • Task: P(<|eot_id|> | context, user_audio) endpointing / VAD
  • NPU: single npu:0 via torch_npu, verified device placement for model params, waveform and logits

Usage

import subprocess
# NPU inference (real device)
python inference.py --device npu
# CPU baseline
python inference.py --device cpu
# Custom audio
python inference.py --device npu --audio sample.wav

inference.py loads local ./model_cache/ultraVAD (or HF cache) with trust_remote_code=True, moves UltravoxModel to npu:0, preprocesses via UltravoxProcessor (16kHz, synthetic 3s audio if no file), runs synchronized forward (torch.npu.synchronize() before/after), extracts audio_pos = audio_token_start_idx + audio_token_len -1 logits and computes P(<|eot_id|>) via softmax.

NPU Validation

  • CPU vs NPU P(eot) max abs diff < 1e-4, device npu:0 logged for params/inputs/logits
  • Latency via torch.npu.synchronize(), reports ms, RTF and frames/s (see logs)

Evidence

workflow npu call result

Hardware: Ascend910_9362 #NPU, torch_npu 2.9.0