Skip to main content

SepRQ

Université de Toulon · LIS · CNRS · ILLS · pyannoteAI

📄 Paper  ·  🌐 Website  ·  🤗 Hugging Face  ·  💻 GitHub

🗣️ This framework is intended to provide an easy, ready-to-use and strong SepRQ feature extractor for 🍸 cocktail-party 🍸 and multi-talker conversational scenarios 🔀 👥, while also facilitating the use of other feature extractors from the literature. We also release a BEST-RQ model trained at 50 Hz as a valuable contribution to the community.

SepRQ features are pulled from 🤗 SevKod/SepRQ; a call returns the 12 Conformer layer features usable for training or cocktail-party representation analysis. Requires PyTorch and upstream speechbrain>=1.0.3; runs on CPU or GPU.


👉 Please visit https://sevkod.github.io/SepRQ/ for the full usage and demo.


Install

pip install seprq

Usage (frozen ❄️ or fine-tuned 🔥)

from seprq import SepRQEncoder

wav = "hf.co/SepRQ/SepRQ/blob/main/ex/mix.wav"
# wav = torchaudio.load("path/to/audio.wav")

# "SepRQ" — see "Available models" for every name
encoder = SepRQEncoder("SepRQ",
                       streams=2)

# ❄️ frozen feature extraction
encoder.requires_grad_(False).eval()  # or True for 🔥 fine-tuning
features = encoder(wav)

It accepts a file path (any format/rate — decoded, mono, resampled to 16 kHz) or a waveform tensor [num_samples], [batch, num_samples] or [batch, channel, num_samples].

SepRQ ships in variants trained to separate a different number of speakers — select one with streams (default 2):

encoder = SepRQEncoder("SepRQ",
                       streams=3)
# 3-speaker variant

Available models

name layers dim
⭐ SepRQ ⭐ 12 576
BestRQ_50Hz 12 576
HuBERT_BASE 12 768
WavLM_BASE 12 768
WavLM_BASE_PLUS 12 768
WavLM_LARGE 24 1024

The SepRQ / BEST-RQ weights come from the Hub (private — authenticate once with huggingface-cli login or HF_TOKEN); the HuBERT / WavLM baselines are fetched from the torchaudio pipelines, nothing extra to host.

Run a task

SUPERB separation, diarization, and enhancement, plus target-speaker extraction, personalized VAD, and target-speaker ASR. The head is chosen from the upstream. Published for SepRQ (streams=2), HuBERT_BASE, WavLM_BASE, and WavLM_BASE_PLUS. Target-speaker tasks take an enrollment utterance.

from seprq import SepRQPipeline

wav = "hf.co/SepRQ/SepRQ/blob/main/ex/mix.wav"
noisy = "hf.co/SepRQ/SepRQ/blob/main/ex/noisy.wav"

save_to = "./output"

# Separation — writes ./output/0.wav, ./output/1.wav
pipe = SepRQPipeline("separation",
                     upstream="SepRQ",
                     streams=2)
sources = pipe(wav,
               save_to=save_to)
# [num_speakers, num_samples]

# Diarization — writes ./output/0.rttm
pipe = SepRQPipeline("diarization",
                     upstream="SepRQ",
                     streams=2)
activations = pipe(wav,
                   save_to=save_to)
# [time, num_speakers]

# Enhancement — writes ./output/0.wav
pipe = SepRQPipeline("enhancement",
                     upstream="SepRQ",
                     streams=2)
clean = pipe(noisy,
             save_to=save_to)
# [num_samples]

# Target speaker extraction — writes ./output/0.wav
mix = "hf.co/SepRQ/SepRQ/blob/main/ex/target-speaker-extraction/1188-133604-0025_4992-23283-0016/mixture.wav"
enrollment = "hf.co/SepRQ/SepRQ/blob/main/ex/target-speaker-extraction/1188-133604-0025_4992-23283-0016/enrollment.wav"
pipe = SepRQPipeline("target-speaker-extraction",
                     upstream="SepRQ",
                     streams=2)
target = pipe(mix,
              enrollment=enrollment,
              save_to=save_to)
# [num_samples]

# Personalized VAD — writes ./output/0.rttm
mix = "hf.co/SepRQ/SepRQ/blob/main/ex/personalized-vad/mix_0000001/mixture.wav"
enrollment = "hf.co/SepRQ/SepRQ/blob/main/ex/personalized-vad/mix_0000001/enrollment.wav"
pipe = SepRQPipeline("personalized-vad",
                     upstream="SepRQ",
                     streams=2)
activations = pipe(mix,
                   enrollment=enrollment,
                   save_to=save_to)
# [time]

# Target-speaker ASR — writes ./output/0.txt
mix = "hf.co/SepRQ/SepRQ/blob/main/ex/target-speaker-asr/4446-2271-0014_3570-5694-0003/mixture.wav"
enrollment = "hf.co/SepRQ/SepRQ/blob/main/ex/target-speaker-asr/4446-2271-0014_3570-5694-0003/enrollment.wav"
pipe = SepRQPipeline("target-speaker-asr",
                     upstream="SepRQ",
                     streams=2)
text = pipe(mix,
            enrollment=enrollment,
            save_to=save_to)

🔀 SepRQ — separation as the pretext task

SepRQ swaps masked prediction for pseudo source separation. It predicts one stream of discrete units per speaker in the mixture, at several temporal resolutions.

SepRQ architecture

Fig. 1. SepRQ performs pseudo source separation in the discrete space. Random vector quantizers (RVQs) give speaker-specific discrete labels at several resolutions.

  • Pseudo source separation — each separation head predicts the frozen BEST-RQ codewords of one clean speaker from the mixture. Utterance-level PIT resolves speaker order.
  • Mask-free — masking can hide exactly the content needed to disentangle a mixture. SepRQ predicts units over the full utterance, which uses every frame for training.
  • Multi-resolution — a separation objective follows every two Conformer layers, with frame folding going from 20 ms to 320 ms and one codebook per scale.

👥 Results

Frozen upstreams with SUPERB / TS-SUPERB downstream heads.

Multi-speaker SUPERB

Speaker diarization (SD), speech separation (SS) and speech enhancement (SE). LS = LibriSpeech, LL = Libri-Light, Mix = LL-60k + GigaSpeech-10k + VoxPopuli-24k.

Model Class #Param (M) Data (h) SD SS SE
DER ↓ SI-SDRi ↑ PESQ ↑ STOI ↑
Generic SSLs
HuBERT BaseBase94.68LS-9605.889.362.5893.9
WavLM BaseBase94.70LS-9604.5510.372.5894.0
WavLM Base+Base94.70Mix-94k3.5010.852.6394.3
HuBERT LargeLarge316.62LL-60k5.7510.452.6494.2
WavLM LargeLarge316.62Mix-94k3.2411.192.7094.5
Cocktail-party SSLs
C-HuBERT BaseBase96.00LS-9602.7711.082.6394.0
C-HuBERT LargeLarge318.00LL-60k2.6511.242.6594.3
⭐ SepRQ ⭐Base85.68LS-9602.0812.102.6794.4

TS-SUPERB

Target speaker extraction (TSE), personalized speech extraction (PSE), personalized VAD (PVAD), target-speaker ASR (TS-ASR).

Upstream #Param (M) TSE PSE PVAD
mAP ↑
TS-ASR
SI-SDRi ↑ STOI ↑ SI-SDRi ↑ STOI ↑ WER ↓
(w/o LM) (w/ LM)
HuBERT Base94.689.6487.308.6179.9294.6036.8630.52
WavLM Base94.7010.2688.409.6581.5794.4027.8222.68
WavLM Base+94.7010.6989.0010.0182.6795.0024.7520.06
⭐ SepRQ ⭐85.6812.5391.4511.1885.6096.6122.2616.78

Out-of-domain

EEND diarization on DIHARD 3 and ConvTasNet separation on WSJ0-2/3mix.

Upstream Diarization Separation
DIHARD 3 WSJ0-2mix WSJ0-3mix
FA / MD / SC ↓ DER ↓ SDRi ↑ SDRi ↑
w/o SSL features6.1 / 8.1 / 4.919.316.413.1
HuBERT Base4.3 / 8.6 / 4.717.717.012.7
WavLM Base4.4 / 8.3 / 4.517.317.513.2
WavLM Base+4.8 / 7.6 / 4.216.618.213.4
⭐ SepRQ (2 src) ⭐4.9 / 7.4 / 3.816.119.814.5
⭐ SepRQ (3 src) ⭐5.0 / 7.3 / 4.116.419.417.2

Citation

If SepRQ helps your research, please cite the paper: arXiv:2610.04690.

@misc{baroudi2026seprqselfsupervisedspeech,
  title         = {SepRQ : Self-Supervised Speech Mixture Representation Learning
                   via Mask-Free, Multi-Scale Source Separation},
  author        = {Séverin Baroudi and Hervé Bredin and Ricard Marxer},
  year          = {2026},
  eprint        = {2610.04690},
  archivePrefix = {arXiv},
  primaryClass  = {eess.AS},
  url           = {https://arxiv.org/abs/2610.04690}
}

Metadata

Release files for seprq 0.4.3

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for seprq 0.4.3
File Size Uploaded
seprq-0.4.3.tar.gz 18.9 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for seprq 0.4.3
File Interpreter ABI Platform
seprq-0.4.3-py3-none-any.whl Python 3 none any Details

Total release size: 35.5 kB

Release files / seprq-0.4.3.tar.gz

Download URL seprq-0.4.3.tar.gz
Size 18.9 kB
Tags Source
SHA-256 checksum
How to use checksums
9798cfe40a08a8cfe489067ca0354e330bbc5218fe2b02def15179f4e44c7c44
BLAKE2b-256 checksum
How to use checksums
d40b86c885f6ecc3b0d453b45ff27cf0ce65132123028f5fec680735f8207771
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 7, 2026.

Transparency log

Release files / seprq-0.4.3-py3-none-any.whl

Download URL seprq-0.4.3-py3-none-any.whl
Size 16.5 kB
Tags Python 3
SHA-256 checksum
How to use checksums
f0bf770896e01c955d066daa0a22223ad6bf2a563a237e87dc71002fb48b9c2d
BLAKE2b-256 checksum
How to use checksums
b6e3066b63bdf3633b8dbeba7f3c0103c2c434c631416aee36743e41e64b193c
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 7, 2026.

Transparency log

Release history Release notifications | RSS feed

0.4.8

2 release files

0.4.7

2 release files

0.4.6

2 release files

0.4.5

2 release files

0.4.4

2 release files

This release

0.4.3 This release

2 release files

0.4.2

2 release files

0.4.1

2 release files

0.4.0

2 release files

0.3.1

2 release files

0.1.3

2 release files

0.1.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page