Downloads · 30 days
0
lquint/clap-htsat-unfused-onnx
clap-htsat-unfused-onnx is a machine learning model from lquint. Use it for the machine learning task on the model card, and read the license before you ship it in a product.
ONNX export of the audio encoder from laion/clap-htsat-unfused for audio embedding generation.
Downloads · 30 days
0
Access
Public
Updated Mar 3, 2026
Repo size
120 MB
Likes
0
Public
Click a slice to open those files.
.onnx120 MB · 100%
From the Hugging Face model README
ONNX export of the audio encoder from laion/clap-htsat-unfused for audio embedding generation.
| Property | Value |
|---|---|
| File | model.onnx |
| Size | ~114 MB |
| Opset | 18 |
| Inputs | input_features [batch, 1, 1001, 64] float32, is_longer [batch, 1] bool |
| Outputs | embeddings [batch, 512] float32 (L2-normalized) |
import onnxruntime as ort
import numpy as np
session = ort.InferenceSession("model.onnx")
input_features = np.random.randn(1, 1, 1001, 64).astype(np.float32)
is_longer = np.array([[False]], dtype=bool)
embeddings = session.run(None, {"input_features": input_features, "is_longer": is_longer})[0]
print(f"Embedding shape: {embeddings.shape}") # (1, 512)
Exported from laion/clap-htsat-unfused using PyTorch torch.onnx.export with a custom wrapper that:
ClapAudioModel)ClapProjectionLayer: Linear(768→512) → ReLU → Linear(512→512))ClapModel.get_audio_features() behavior)This ONNX model is designed for use with MLNet.AudioInference.Onnx for audio embedding generation in .NET applications via the model-packages-prototype SDK.