korallll commited on
Commit
eca7c72
·
verified ·
1 Parent(s): 81902c3

Fix: exclude seedtts_testset (real reference prompts mislabeled spoof); 4548->3948

Browse files
README.md CHANGED
@@ -28,11 +28,11 @@ synthetic / deepfake voice detection.
28
 
29
  ## Overview
30
 
31
- SONAR is a balanced binary-classification benchmark: **bonafide** (genuine human speech)
32
- vs. **spoof** (AI-synthesized speech). The spoof side aggregates clips from **nine modern
33
  speech-synthesis systems**, deliberately spanning architectures and providers so that a
34
- detector cannot win by memorising one generator's artifacts. The bonafide side is an equal
35
- number of real clips sampled from the **LibriTTS** clean-test set. Original code and data:
36
  https://github.com/Jessegator/SONAR.
37
 
38
  | Side | Source | n |
@@ -40,7 +40,6 @@ https://github.com/Jessegator/SONAR.
40
  | bonafide | LibriTTS clean-test | 2274 |
41
  | spoof | OpenAI TTS | 600 |
42
  | spoof | xTTS | 600 |
43
- | spoof | Seed-TTS (en 300 + zh 300) | 600 |
44
  | spoof | FlashSpeech | 118 |
45
  | spoof | VoiceBox | 104 |
46
  | spoof | AudioGen | 100 |
@@ -48,6 +47,12 @@ https://github.com/Jessegator/SONAR.
48
  | spoof | NaturalSpeech 3 | 32 |
49
  | spoof | PromptTTS 2 | 25 |
50
 
 
 
 
 
 
 
51
  ## License & redistribution
52
 
53
  This **packaging** is released under the **Creative Commons Attribution-NonCommercial 4.0
@@ -86,16 +91,16 @@ print(ds[0])
86
 
87
  | Stat | Value |
88
  |------|-------|
89
- | Total trials | 4548 |
90
  | Bonafide | 2274 |
91
- | Spoof | 2274 |
92
 
93
  ## Source provenance
94
 
95
  - Paper: https://arxiv.org/abs/2410.04324
96
  - Code / data: https://github.com/Jessegator/SONAR
97
- - Labels derived from the source directory layout (`real_samples/` = bonafide; the nine
98
- synthesis-system directories = spoof).
99
 
100
  ## Evaluation
101
 
 
28
 
29
  ## Overview
30
 
31
+ SONAR is a binary-classification benchmark: **bonafide** (genuine human speech)
32
+ vs. **spoof** (AI-synthesized speech). The spoof side aggregates clips from **eight modern
33
  speech-synthesis systems**, deliberately spanning architectures and providers so that a
34
+ detector cannot win by memorising one generator's artifacts. The bonafide side is real
35
+ clips sampled from the **LibriTTS** clean-test set. Original code and data:
36
  https://github.com/Jessegator/SONAR.
37
 
38
  | Side | Source | n |
 
40
  | bonafide | LibriTTS clean-test | 2274 |
41
  | spoof | OpenAI TTS | 600 |
42
  | spoof | xTTS | 600 |
 
43
  | spoof | FlashSpeech | 118 |
44
  | spoof | VoiceBox | 104 |
45
  | spoof | AudioGen | 100 |
 
47
  | spoof | NaturalSpeech 3 | 32 |
48
  | spoof | PromptTTS 2 | 25 |
49
 
50
+ > **Seed-TTS excluded (2026-06-07).** The upstream `seedtts_testset/` directory holds the
51
+ > SeedTTS *reference prompts* — real Common Voice audio (`common_voice_en_<prompt>-<target>.wav`),
52
+ > not synthesized speech (the actual SeedTTS-generated outputs are not redistributed on disk).
53
+ > Labeling those 600 real clips as spoof was incorrect, so they are dropped from this package.
54
+ > This matches the SONAR authors' own released eval set (3948 clips).
55
+
56
  ## License & redistribution
57
 
58
  This **packaging** is released under the **Creative Commons Attribution-NonCommercial 4.0
 
91
 
92
  | Stat | Value |
93
  |------|-------|
94
+ | Total trials | 3948 |
95
  | Bonafide | 2274 |
96
+ | Spoof | 1674 |
97
 
98
  ## Source provenance
99
 
100
  - Paper: https://arxiv.org/abs/2410.04324
101
  - Code / data: https://github.com/Jessegator/SONAR
102
+ - Labels derived from the source directory layout (`real_samples/` = bonafide; the eight
103
+ synthesis-system directories = spoof; `seedtts_testset/` excluded — real reference prompts).
104
 
105
  ## Evaluation
106
 
build_parquet.py CHANGED
@@ -52,14 +52,20 @@ except AttributeError: # older datasets
52
  REPO_ROOT = Path(__file__).resolve().parent
53
  SRC_ROOT = Path("/home/kirill/mnt/users_4tb/datasets/sonar")
54
  REAL_DIR = "real_samples" # bonafide; every other top-level dir is spoof
 
 
 
 
 
 
55
  PARQUET_DIR = REPO_ROOT / "data"
56
  STAGING_DIR = REPO_ROOT / "_clean_flac"
57
  NUM_SHARDS = 2
58
- EXPECTED_ROWS = 4548
59
  EXPECTED_BONAFIDE = 2274
60
- EXPECTED_SPOOF = 2274
61
  TARGET_SR = 16000
62
- PROBE_SAMPLE = 4548 # whole set
63
  WORKERS = int(os.environ.get("SONAR_BUILD_WORKERS", os.cpu_count() or 4))
64
 
65
  FEATURES = Features(
@@ -84,6 +90,8 @@ def build_catalogue():
84
  for path in SRC_ROOT.rglob("*.wav"):
85
  relpath = path.relative_to(SRC_ROOT).as_posix()
86
  system = relpath.split("/", 1)[0]
 
 
87
  label = "bonafide" if system == REAL_DIR else "spoof"
88
  language = "zh" if "/zh/" in f"/{relpath}" else "en"
89
  records.append(
 
52
  REPO_ROOT = Path(__file__).resolve().parent
53
  SRC_ROOT = Path("/home/kirill/mnt/users_4tb/datasets/sonar")
54
  REAL_DIR = "real_samples" # bonafide; every other top-level dir is spoof
55
+ # EXCLUDED dirs: seedtts_testset holds the SeedTTS *reference prompts* (real Common
56
+ # Voice audio, common_voice_en_<prompt>-<target>.wav), NOT synthesized speech — the
57
+ # actual SeedTTS-generated outputs are not on disk. Labeling them spoof mislabels 600
58
+ # real clips (Spectra-AASIST scored 99.83% bona fide; full-set EER 24.85% vs 0.48%
59
+ # without them). Matches the SONAR authors' own 3948-file eval. (2026-06-07)
60
+ EXCLUDE_DIRS = {"seedtts_testset"}
61
  PARQUET_DIR = REPO_ROOT / "data"
62
  STAGING_DIR = REPO_ROOT / "_clean_flac"
63
  NUM_SHARDS = 2
64
+ EXPECTED_ROWS = 3948
65
  EXPECTED_BONAFIDE = 2274
66
+ EXPECTED_SPOOF = 1674
67
  TARGET_SR = 16000
68
+ PROBE_SAMPLE = 3948 # whole set (seedtts_testset excluded)
69
  WORKERS = int(os.environ.get("SONAR_BUILD_WORKERS", os.cpu_count() or 4))
70
 
71
  FEATURES = Features(
 
90
  for path in SRC_ROOT.rglob("*.wav"):
91
  relpath = path.relative_to(SRC_ROOT).as_posix()
92
  system = relpath.split("/", 1)[0]
93
+ if system in EXCLUDE_DIRS:
94
+ continue
95
  label = "bonafide" if system == REAL_DIR else "spoof"
96
  language = "zh" if "/zh/" in f"/{relpath}" else "en"
97
  records.append(
data/labels.parquet CHANGED
@@ -1,3 +1,3 @@
1
  version https://git-lfs.github.com/spec/v1
2
- oid sha256:9edb7158cc6241bed48edcff96d10dc85f3b977b911dc4cd26ae3144584cb7c6
3
- size 35013
 
1
  version https://git-lfs.github.com/spec/v1
2
+ oid sha256:e05a59ad837b922948aac0f3a8ef70a752a247bf652e275e0a5994618afc8fcf
3
+ size 28035
data/test-00000-of-00002.parquet CHANGED
@@ -1,3 +1,3 @@
1
  version https://git-lfs.github.com/spec/v1
2
- oid sha256:a1b7ebe9290425834bf8fcd0e471806247c68fa0a36979372e6a7d7a0f08f750
3
- size 288064744
 
1
  version https://git-lfs.github.com/spec/v1
2
+ oid sha256:e398e67c65b0fe18ef6ac45a9d0f4f8c4685d62c2cab6b53f7d2ce381e22ef2d
3
+ size 233448507
data/test-00001-of-00002.parquet CHANGED
@@ -1,3 +1,3 @@
1
  version https://git-lfs.github.com/spec/v1
2
- oid sha256:fe7259b670680394ca2e1d4477ba41e2ac0b6bb940c61ef8014a1e1487002e32
3
- size 290017252
 
1
  version https://git-lfs.github.com/spec/v1
2
+ oid sha256:54c9b77e96202ca9ea73c309e26d8f7693a305619fcf0143ec86581e4aa73a72
3
+ size 293936334
eval.yaml CHANGED
@@ -1,10 +1,11 @@
1
  name: SONAR
2
  description: >
3
- SONAR synthetic-audio detection benchmark (arXiv 2410.04324). Balanced binary
4
- classification: 2274 bonafide (LibriTTS clean-test) vs. 2274 spoof aggregated
5
- from nine speech-synthesis systems (OpenAI TTS, xTTS, Seed-TTS, FlashSpeech,
6
- VoiceBox, AudioGen, VALL-E, NaturalSpeech 3, PromptTTS 2). EER computed over all
7
- 4548 utterances.
 
8
  evaluation_framework: inspect-ai
9
 
10
  tasks:
 
1
  name: SONAR
2
  description: >
3
+ SONAR synthetic-audio detection benchmark (arXiv 2410.04324). Binary
4
+ classification: 2274 bonafide (LibriTTS clean-test) vs. 1674 spoof aggregated
5
+ from eight speech-synthesis systems (OpenAI TTS, xTTS, FlashSpeech, VoiceBox,
6
+ AudioGen, VALL-E, NaturalSpeech 3, PromptTTS 2). EER computed over all 3948
7
+ utterances. (Seed-TTS excluded: the on-disk seedtts_testset clips are the real
8
+ Common Voice reference prompts, not synthesized speech.)
9
  evaluation_framework: inspect-ai
10
 
11
  tasks: