Skip to main content

A lightweight library to compute Diarization Error Rate (DER).

Project description

SimpleDER Build Status

Overview

This is a lightweight library to compute Diarization Error Rate (DER).

Features NOT supported:

  • Handling overlapped speech, i.e. two speakers speaking at the same time.
  • Allowing segment boundary tolerance, a.k.a. the collar value.

For more sophisticated with these supports, please use pyannote-metrics instead.

To learn more about speaker diarization, here is a curated list of resources: awesome-diarization.

Tutorial

Here is a minimal example:

import der

# reference (ground truth)
ref = [("A", 0.0, 1.0),
       ("B", 1.0, 1.5),
       ("A", 1.6, 2.1)]

# hypothesis (diarization result from your algorithm)
hyp = [("1", 0.0, 0.8),
       ("2", 0.8, 1.4),
       ("3", 1.5, 1.8),
       ("1", 1.8, 2.0)]

error = der.DER(ref, hyp)

print("DER={:.3f}".format(error))

This should output:

DER=0.350

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

simpleder-0.0.1.tar.gz (3.2 kB view hashes)

Uploaded Source

Built Distribution

simpleder-0.0.1-py3-none-any.whl (7.7 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page