SYNTOLOGY HomeExplorerAtlasCodeMethodologyAboutDevelopersFeedPricing
Paper · 2311.01616 · 2023

Adapting Frechet Audio Distance for Generative Music Evaluation

arXiv · PDF · Open in the Atlas

Code that ran

9 of 10 samples (functions and classes) lifted from this paper's linked repositories executed on a synthesized input in Syntology's jail (0 of them constructed an object rather than computing a result; 1 honoured the contract we drafted, 0 violated it and 4 have no contract verdict; 4 failures of our instrument; 1 no recorded run), measured 2026-11-22; repository links from the Papers with Code archive attributed under CC BY-SA, no affiliation; bodies inline only under a permissive licence as GitHub detects it. Not a reproduction of the paper's results.

"Ran" means the function executed on a synthesized input and returned a value. It is not a reproduction of the paper's results. This record, dated, as JSON: /api/ran/2311.01616.json · badge: /api/ran/2311.01616.svg

Each repository's role is a label: a classifier's output recorded on the link, or, where no role is recorded, what the Papers with Code archive marked. The line under it names its basis. Neither says who wrote the code.

RepositoryRoleRan
microsoft/fadtk canonical (classifier label)
classifier basis: census
2 ran · 0 no recorded run
pablebe/gensvs_eval community (classifier label)
classifier basis not recorded on the link
6 ran · 1 no recorded run
copy not recorded community
not in the paper's declared repositories
1 ran · 0 no recorded run
FunctionStatusWhere it lives
add_gen_disc_column Ran
ran on a synthesized input
pablebe/gensvs_eval/01_evaluation_and_correlation/gensvs_eval_plots_and_csv_export.py
code served (permissive licence) · get_code("f42e113f46cfeb9c")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned str. The image it ran in was not recorded. If your copy returns the same type on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import pandas as pd

def add_gen_disc_column(row):
    if row['model_name'] == 'htdemucs' or row['model_name'] == 'melroformer_large' or row['model_name'] == 'melroformer_small':
        val = 'discriminative'
    else:
        val = 'generative'
    return val

# Create a sample row as a pandas Series with a 'model_name' key
row = pd.Series({'model_name': 'some_other_model'})

ARGS = {
    'row': row
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
pandas — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type str — a str output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a str output the recorded ndim 0 and dtype family float describe that coercion, not the output, and are not stated
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
calc_embd_statistics Ran
ran; our contract draft was wrong, not the code
microsoft/fadtk/fadtk/fad.py
code served (permissive licence) · get_code("f13f3eddd329ff24")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned tuple. The image it ran in was not recorded. If your copy returns the same type on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import numpy as np

# Create a small embedding array with at least 2 samples
# Shape: (num_embeddings, embedding_dim)
# Using distinct dimensions: 5 embeddings of dimension 3 each
embd_lst = np.random.randn(5, 3).astype(np.float32)

ARGS = {
    "embd_lst": embd_lst,
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
numpy — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type tuple — a tuple output has no array shape of its own; none is stated
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
create_prompt Ran
ran; our contract draft was wrong, not the code
this paper's copy was not recorded; identical code first harvested from dcase2024-task7-sound-scene-synthesis/fadtk
pointer only · get_code("ca4b05e19c89061a")
How it ran

The body of this sample is withheld: this paper's copy of the code was not recorded (its link names no repository or source path), so no licence was read for it. The setup block that called it is withheld with it, because it is written against that body. source_path and origin say where the code lives, to read under the repository's own terms. A run is recorded.

evaluate_pam Ran
ran, honoured the contract we drafted
pablebe/gensvs_eval/01_evaluation_and_correlation/pam_eval/pcc.py
code served (permissive licence) · get_code("a8d84ccaebb23a2a")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned tuple, ndim 2, dtype family float; no output shape is stated. The image it ran in was not recorded. If your copy returns the same type and ndim on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import torch
import torch.nn as nn
from torch.utils.data import DataLoader, Dataset

torch.manual_seed(0)

# Define a minimal PAM model that implements the evaluate method
class MinimalPAM(nn.Module):
    def __init__(self):
        super().__init__()
        self.linear = nn.Linear(4, 2)
    
    def evaluate(self, audios, sample_index):
        # Return two lists of scores as expected by the function
        batch_size = audios.shape[0]
        pam_scores = [float(i) for i in range(batch_size)]
        pam_segment_scores = [float(i * 2) for i in range(batch_size)]
        return pam_scores, pam_segment_scores

# Define a minimal dataset
class MinimalAudioDataset(Dataset):
    def __init__(self, num_samples=4):
        self.num_samples = num_samples
    
    def __len__(self):
        return self.num_samples
    
    def __getitem__(self, idx):
        # Return (_, audios, sample_index) as expected by the dataloader iteration
        dummy_label = 0
        audios = torch.randn(4)  # Small audio feature vector
        sample_index = idx
        return dummy_label, audios, sample_index

# Create dataloader that yields (_, audios, sample_index)
dataset = MinimalAudioDataset(num_samples=4)
dataloader = DataLoader(dataset, batch_size=2)

# Create PAM instance
pam = MinimalPAM()

# Define arguments
ARGS = {
    "dataloader": dataloader,
    "pam": pam
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
torch, tqdm — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type tuple, ndim 2, dtype family float — a tuple output has no array shape of its own; none is stated
dtype family
int means an integer dtype; float means any other dtype the instrument saw, bool and complex included (fixture_check.py records only these two families)
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
get_argparse_groups Ran
ran on a synthesized input
pablebe/gensvs_eval/00_training_and_inference/train_finetune_bigvgan.py
code served (permissive licence) · get_code("478f975b166d8aac")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned dict. The image it ran in was not recorded. If your copy returns the same type on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import argparse
import torch

# Create a simple argument parser with groups
parser = argparse.ArgumentParser()

# Add some action groups
group1 = parser.add_argument_group('model', 'Model arguments')
group1.add_argument('--hidden_size', type=int, default=64)
group1.add_argument('--num_layers', type=int, default=2)

group2 = parser.add_argument_group('training', 'Training arguments')
group2.add_argument('--learning_rate', type=float, default=0.001)
group2.add_argument('--batch_size', type=int, default=32)

group3 = parser.add_argument_group('data', 'Data arguments')
group3.add_argument('--dataset_name', type=str, default='test_dataset')
group3.add_argument('--split', type=str, default='train')

# Parse some args with the defaults
args = parser.parse_args([])

ARGS = {
    'parser': parser,
    'args': args
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type dict — a dict output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a dict output the recorded ndim 0 and dtype family float describe that coercion, not the output, and are not stated
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
get_cache_embedding_path Ran
ran; our contract draft was wrong, not the code
microsoft/fadtk/fadtk/utils.py
code served (permissive licence) · get_code("c8e9bc934b6ab42c")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned PosixPath. The image it ran in was not recorded. If your copy returns the same type on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

from pathlib import Path

# Construct arguments for get_cache_embedding_path
model = "test_model"
audio_dir = Path("/tmp/audio/sample_audio.wav")

ARGS = {
    "model": model,
    "audio_dir": audio_dir,
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
none outside the standard library — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type PosixPath — a PosixPath output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a PosixPath output the recorded ndim 0 and dtype family float describe that coercion, not the output, and are not stated
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
load_task_dataframe Ran
ran; our contract draft was wrong, not the code
pablebe/gensvs_eval/01_evaluation_and_correlation/pam_eval/pcc.py
code served (permissive licence) · get_code("9e1c1269ab3f61a7")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned tuple, ndim 2, dtype family float; no output shape is stated. The image it ran in was not recorded. If your copy returns the same type and ndim on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import os
import pandas as pd
import tempfile
import shutil

# Create a temporary directory structure to mimic the task/model layout
temp_dir = tempfile.mkdtemp()
task_dir = os.path.join(temp_dir, 'task')
model_name = 'test_model'
model_dir = os.path.join(task_dir, model_name)

os.makedirs(model_dir, exist_ok=True)

# Create a scores.csv file with test data
scores_data = {
    'Model': [model_name, model_name, 'other_model'],
    'File Name': ['file1', 'file2', 'file3'],
    'OVL': [0.8, 0.9, 0.7],
    'REL': [0.6, 0.7, 0.5]
}
df = pd.DataFrame(scores_data)
df.to_csv(os.path.join(task_dir, 'scores.csv'), index=False)

# Create dummy wav files
for filename in ['file1', 'file2', 'file3']:
    filepath = os.path.join(model_dir, filename + '.wav')
    with open(filepath, 'w') as f:
        f.write('dummy wav content')

# Create a simple model class that has a split method (used in the function)
class SimpleModel:
    def __init__(self, model_path):
        self.path = model_path
    
    def split(self, sep):
        return self.path.split(sep)

model = SimpleModel(model_dir)

ARGS = {
    'task': task_dir,
    'model': model_dir
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
pandas — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type tuple, ndim 2, dtype family float — a tuple output has no array shape of its own; none is stated
dtype family
int means an integer dtype; float means any other dtype the instrument saw, bool and complex included (fixture_check.py records only these two families)
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
pvalue_to_stars Ran
ran on a synthesized input
pablebe/gensvs_eval/01_evaluation_and_correlation/gensvs_eval_plots_and_csv_export.py
code served (permissive licence) · get_code("a0be35dc5fd90ded")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned str. The image it ran in was not recorded. If your copy returns the same type on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import torch
import numpy as np

P_VAL_THRESHOLD = 0.05
P_VAL_THRESHOLD_2 = 0.01
P_VAL_THRESHOLD_3 = 0.001

def pvalue_to_stars(p):
    if p <= P_VAL_THRESHOLD_3:
        return '***'
    elif p <= P_VAL_THRESHOLD_2:
        return '**'
    elif p <= P_VAL_THRESHOLD:
        return '*'
    else:
        return 'ns'

ARGS = {
    'p': 0.001
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
numpy, torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type str — a str output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a str output the recorded ndim 0 and dtype family float describe that coercion, not the output, and are not stated
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
sort_df_by_order_df Ran
ran on a synthesized input
pablebe/gensvs_eval/01_evaluation_and_correlation/gensvs_eval_fad_mse.py
code served (permissive licence) · get_code("a197466fbd6f0714")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned DataFrame. The image it ran in was not recorded. If your copy returns the same type on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import os
import pandas as pd

# Create sample dataframes for the function
# The function expects:
# 1. df: a dataframe with file paths in the first column
# 2. file_order_df: a dataframe with a 'file_id' column that defines the sort order

# Create df with file paths that contain 'fileid_' patterns
df = pd.DataFrame({
    0: [
        '/path/to/audio/fileid_003.wav',
        '/path/to/audio/fileid_001.wav',
        '/path/to/audio/fileid_002.wav',
    ],
    'data': [10, 20, 30]
})

# Create file_order_df with file_ids in a specific order
file_order_df = pd.DataFrame({
    'file_id': ['fileid_001', 'fileid_002', 'fileid_003']
})

ARGS = {
    'df': df,
    'file_order_df': file_order_df
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
pandas — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type DataFrame — a DataFrame output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a DataFrame output the recorded ndim 2 and dtype family float describe that coercion, not the output, and are not stated
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
get_audio_encoder Not yet run
unverified (harvested, no recorded run)
pablebe/gensvs_eval/01_evaluation_and_correlation/pam_eval/PAM/models/audio.py
code served (permissive licence) · get_code("705be5651717fc89")
How it ran

no invocation recorded.

Also present in other papers' code

Of 10 samples lifted from this paper's linked repositories, 10 carry a function identity and 0 do not. Of the 10 distinct functions with an identity, 5 are also present in other papers whose code we hold (0 with at least one paper dated earlier, 0 the same month, 5 later) and 5 are only here among the 52,977 papers whose code Syntology holds (as of 2026-09-26).

Only here means: among the 52,977 papers whose code Syntology holds (51,887 with lifted samples, 1,090 through their assemblies only), as of 2026-09-26, no other paper's lifted samples or current assembly bricks contain an identical function body after normalisation.

FunctionAlso present inEarliest-datedOthers named
get_audio_encoder 2 other papers
2 later
2402.00282 (2024-02)
PAM: Prompting Audio-Language Models for Audio Quality Assessment
2503.08540 (2025-03)
Mellow: a small audio language model for reasoning
create_prompt 1 other paper
1 later
2403.17508 (2024-03)
Correlation of Fréchet Audio Distance With Human Perception of Environmental Audio Is Embedding Dependant
evaluate_pam 1 other paper
1 later
2402.00282 (2024-02)
PAM: Prompting Audio-Language Models for Audio Quality Assessment
get_cache_embedding_path 1 other paper
1 later
2403.17508 (2024-03)
Correlation of Fréchet Audio Distance With Human Perception of Environmental Audio Is Embedding Dependant
load_task_dataframe 1 other paper
1 later
2402.00282 (2024-02)
PAM: Prompting Audio-Language Models for Audio Quality Assessment

Presence, not direction: an identical function body in two papers' repositories does not say who wrote it, which came from which, or that either paper's method rests on it. Matching is exact after normalisation, so a renamed or edited function is not matched. Dates are when papers appeared, not when code was written. Only .py files the harvester lifted are covered; notebooks are not read. A new-style arXiv id YYMM.NNNN dates a paper to the month 20YY-MM; otherwise Paper.year dates it to the year; otherwise it is undated. Dates are when the paper appeared, not when the code was written. Read 2026-11-22.

Repositories linked to this paper

Some links come from the archived Papers with Code dataset (CC BY-SA 4.0): attribution and licence.

Abstract

The growing popularity of generative music models underlines the need for perceptually relevant, objective music quality metrics. The Frechet Audio Distance (FAD) is commonly used for this purpose even though its correlation with perceptual quality is understudied. We show that FAD performance may be hampered by sample size bias, poor choice of audio embeddings, or the use of biased or low-quality reference sets. We propose reducing sample size bias by extrapolating scores towards an infinite sample size. Through comparisons with MusicCaps labels and a listening test we identify audio embeddings and music reference sets that yield FAD scores well-correlated with acoustic and musical quality. Our results suggest that per-song FAD can be useful to identify outlier samples and predict perceptual quality for a range of music sets and generative models. Finally, we release a toolkit that allows adapting FAD for generative music evaluation.

For agents

The same record, over MCP at https://syntology.ai/mcp:

get_harvested_code_for_paper("2311.01616")
get_code_for_paper("2311.01616")
have("2311.01616")

The run record, dated, one paper per request, free:

curl https://syntology.ai/api/ran/2311.01616.json

A badge for a README (the split and the date, never a ratio):

[![Syntology run record](https://syntology.ai/api/ran/2311.01616.svg)](https://syntology.ai/paper/2311.01616)

Connect an agent — have() is free.