{"id":17052108,"url":"https://github.com/wq2012/simpleder","last_synced_at":"2025-08-30T22:12:10.291Z","repository":{"id":57467355,"uuid":"167809355","full_name":"wq2012/SimpleDER","owner":"wq2012","description":"A lightweight library to compute Diarization Error Rate (DER).","archived":false,"fork":false,"pushed_at":"2023-08-28T14:33:34.000Z","size":81,"stargazers_count":59,"open_issues_count":0,"forks_count":9,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-06-15T12:57:31.047Z","etag":null,"topics":["diarization","machine-learning","metrics","speaker-diarization","speech-processing","speech-recognition"],"latest_commit_sha":null,"homepage":"https://wq2012.github.io/SimpleDER","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/wq2012.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null}},"created_at":"2019-01-27T13:02:00.000Z","updated_at":"2024-07-22T08:22:12.000Z","dependencies_parsed_at":"2024-01-13T22:25:04.569Z","dependency_job_id":"fc1d8fd8-4581-47c6-b249-c9692da3bd92","html_url":"https://github.com/wq2012/SimpleDER","commit_stats":{"total_commits":39,"total_committers":1,"mean_commits":39.0,"dds":0.0,"last_synced_commit":"0875b50240cda88daa9c97f82d53978a8d5cbd29"},"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/wq2012/SimpleDER","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/wq2012%2FSimpleDER","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/wq2012%2FSimpleDER/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/wq2012%2FSimpleDER/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/wq2012%2FSimpleDER/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/wq2012","download_url":"https://codeload.github.com/wq2012/SimpleDER/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/wq2012%2FSimpleDER/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":261048478,"owners_count":23102501,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["diarization","machine-learning","metrics","speaker-diarization","speech-processing","speech-recognition"],"created_at":"2024-10-14T10:08:27.263Z","updated_at":"2025-06-30T06:03:04.643Z","avatar_url":"https://github.com/wq2012.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# SimpleDER ![Python package](https://github.com/wq2012/SimpleDER/workflows/Python%20package/badge.svg) [![PyPI Version](https://img.shields.io/pypi/v/simpleder.svg)](https://pypi.python.org/pypi/simpleder) [![Python Versions](https://img.shields.io/pypi/pyversions/simpleder.svg)](https://pypi.org/project/simpleder) [![Downloads](https://static.pepy.tech/badge/simpleder)](https://pepy.tech/project/simpleder) [![codecov](https://codecov.io/gh/wq2012/SimpleDER/branch/master/graph/badge.svg)](https://codecov.io/gh/wq2012/SimpleDER) [![Documentation](https://img.shields.io/badge/api-documentation-blue.svg)](https://wq2012.github.io/SimpleDER)\n\n## Overview\n\nThis is a lightweight library to compute Diarization Error Rate (DER).\n\nFeatures **NOT** supported:\n\n* Handling overlapped speech, *i.e.* two speakers speaking at the same time.\n* Allowing segment boundary tolerance, *a.k.a.* the `collar` value.\n\nFor more sophisticated metrics with these supports, please use\n[pyannote-metrics](https://github.com/pyannote/pyannote-metrics) instead.\n\nTo learn more about speaker diarization, here is a curated list of resources:\n[awesome-diarization](https://github.com/wq2012/awesome-diarization).\n\n## Diarization Error Rate\n\nDiarization Error Rate (DER) is the most commonly used metrics for\n[speaker diarization](https://en.wikipedia.org/wiki/Speaker_diarisation).\n\nIts strict form is:\n\n```\n       False Alarm + Miss + Overlap + Confusion\nDER = ------------------------------------------\n                   Reference Length\n```\n\nThe definition of each term:\n\n* `Reference Length:` The total length of the reference (ground truth).\n* `False Alarm`: Length of segments which are considered as speech in\n  hypothesis, but not in reference.\n* `Miss`: Length of segments which are considered as speech in\n  reference, but not in hypothesis.\n* `Overlap`: Length of segments which are considered as overlapped speech\n  in hypothesis, but not in reference.\n  **This library does NOT support overlap.**\n* `Confusion`: Length of segments which are assigned to different speakers\n  in hypothesis and reference (after applying an optimal assignment).\n\nThe unit of each term is *seconds*.\n\nNote that DER can theoretically be larger than 1.0.\n\nReferences:\n\n* [pyannote-metrics documentation](https://pyannote.github.io/pyannote-metrics/reference.html)\n* [Xavier Anguera's thesis](http://www.xavieranguera.com/phdthesis/node108.html)\n\n## Tutorial\n\n### Install\n\nInstall the package by:\n\n```bash\npip3 install simpleder\n```\n\nor\n\n```bash\npython3 -m pip install simpleder\n```\n\n### API\n\nHere is a minimal example:\n\n```python\nimport simpleder\n\n# reference (ground truth)\nref = [(\"A\", 0.0, 1.0),\n       (\"B\", 1.0, 1.5),\n       (\"A\", 1.6, 2.1)]\n\n# hypothesis (diarization result from your algorithm)\nhyp = [(\"1\", 0.0, 0.8),\n       (\"2\", 0.8, 1.4),\n       (\"3\", 1.5, 1.8),\n       (\"1\", 1.8, 2.0)]\n\nerror = simpleder.DER(ref, hyp)\n\nprint(\"DER={:.3f}\".format(error))\n```\n\nThis should output:\n\n```\nDER=0.350\n```","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fwq2012%2Fsimpleder","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fwq2012%2Fsimpleder","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fwq2012%2Fsimpleder/lists"}