---
title: DiariZen
canonical_url: "https://www.modelscope.cn/models/AXERA-TECH/DiariZen"
md_url: "https://www.modelscope.cn/models/AXERA-TECH/DiariZen.md"
repository: AXERA-TECH/DiariZen
last_updated: 2026-07-06
license: cc-by-nc-4.0
pipeline_tag: voice-activity-detection
tasks:
  - voice-activity-detection
library_name:
  - onnx
  - pytorch
frameworks:
  - pytorch
language:
  - en
downloads: 0
stars: 0
tags:
  - speaker-diarization
  - ax650
  - axera
  - onnx
  - axmodel
  - wavlm
  - conformer
---

# DiariZen

> DiariZen - AXERA-TECH 在 ModelScope 开源的模型。DiariZen Speaker Segmentation - AX650 Deployment

AXERA-TECH/DiariZen 是 ModelScope 魔搭社区上的voice-activity-detection模型，采用 cc-by-nc-4.0 许可。

- **Repository**: AXERA-TECH/DiariZen
- **License**: cc-by-nc-4.0
- **Tasks**: voice-activity-detection
- **Tags**: speaker-diarization, ax650, axera, onnx, axmodel, wavlm, conformer
- **Downloads**: 0
- **Stars**: 0
- **Last updated**: 2026-07-06

Source: https://www.modelscope.cn/models/AXERA-TECH/DiariZen

---

# DiariZen Speaker Segmentation - AX650 Deployment

CPU+NPU hybrid speaker diarization segmentation for AX650 NPU.

## Model

- Source: [BUT-FIT/diarizen-wavlm-large-s80-md](https://huggingface.co/BUT-FIT/diarizen-wavlm-large-s80-md)
- Architecture: WavLM-Large (pruned) + Conformer
- Task: Frame-level speaker activity segmentation (11 classes, 4s @ 16kHz)

## Pipeline

```
Audio (16kHz mono, any length)
  → CPU: resample → 4s sliding window → LayerNorm
  → AX650 NPU: CNN feature extractor (7 conv, U16, 17.7ms)
  → CPU: WavLM Transformer (24L) + Conformer (4L) + Classifier (251ms)
  → Log-probabilities (1, 199, 11) per window
```

## Performance

| Stage | Time | Hardware |
|-------|------|----------|
| CNN | 17.7 ms | AX650 NPU @1GHz |
| Backend | 251 ms | CPU ONNX Runtime |
| Total | 269 ms | 14.9x real-time |

## Accuracy

End-to-end cosine: 0.9997 vs full FP32 reference.

## Directory

```
models/          cnn_features.axmodel + backend.onnx
python/          Python SDK (diarizen_sdk)
cpp/             C++ SDK (diarizen_segmenter)
model_convert/   ONNX export + Pulsar2 compile config
reports/         SDK and simulation reports
```

## Quick Start

```bash
pip install -r python/requirements.txt
python python/diarizen_sdk/example.py audio.wav \
  --cnn-model models/cnn_features.axmodel \
  --backend-model models/backend.onnx
```

## Known Limitations

- 4s fixed window; longer audio requires sliding window stitching.
- CNN requires U16 quantization (U8 insufficient accuracy).
- Transformer + Conformer run on CPU (NPU backend limitation with WavLM attention ops).
- pos_conv_embed Conv (kernel=128, NLC layout) incompatible with NPU; included in CPU backend.
