Skip to content

Download Model

netspresso.np_qai.converter.NPQAIConverter.download_model(job, filename)

Download a model from the QAI Hub and handle ONNX zip conversion.

Parameters:

Name Type Description Default
job Union[CompileJob, QuantizeJob]

The job to download the model from (CompileJob or QuantizeJob).

required
filename str

The filename to save the model to.

required

Returns:

Name Type Description
str str

The actual path of the downloaded and processed model.

Note

Since QAI Hub July 2025 update, ONNX models are always downloaded as .zip files with external weights. Other formats (.tflite, .so, .bin) are downloaded directly. Reference: https://app.aihub.qualcomm.com/docs/hub/release_notes.html#released-july-14-2025

This function automatically extracts and converts ONNX zip files to single .onnx files with embedded weights. Non-ONNX models are returned as-is.