SYNTOLOGY HomeExplorerAtlasCodeMethodologyAboutDevelopersFeedPricing
Paper · 2406.02560 · 2024

Less Peaky and More Accurate CTC Forced Alignment by Label Priors

arXiv · PDF · Open in the Atlas

Code that ran

3 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; 0 honoured the contract we drafted, 1 violated it and 0 have no contract verdict; 2 failures of our instrument; 7 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/2406.02560.json · badge: /api/ran/2406.02560.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
huangruizhe/audio canonical (classifier label)
classifier basis: census
3 ran · 7 no recorded run
FunctionStatusWhere it lives
deprecated Ran
ran; our contract draft was wrong, not the code
huangruizhe/audio/torchaudio/_internal/module_utils.py
code served (permissive licence) · get_code("23bbafb2ef4c5399")
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 function. 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 warnings
from functools import wraps
from typing import Optional

def deprecated(direction: str, version: Optional[str]=None, remove: bool=False):
    """Decorator to add deprecation message

    Args:
        direction (str): Migration steps to be given to users.
        version (str or int): The version when the object will be removed
        remove (bool): If enabled, append future removal message.
    """

    def decorator(func):

        @wraps(func)
        def wrapped(*args, **kwargs):
            message = f'{func.__module__}.{func.__name__} has been deprecated. {direction}'
            if remove:
                message += f" It will be removed from {('future' if version is None else version)} release. "
            warnings.warn(message, stacklevel=2)
            return func(*args, **kwargs)
        return wrapped
    return decorator


# Setup code to construct valid arguments
def dummy_function():
    """A simple function to decorate for testing"""
    return "success"


ARGS = {
    'direction': 'Please use new_function() instead.',
    'version': '2.0.0',
    'remove': True
}
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 function — a function output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a function 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
eval_env Ran
ran, violated the contract we drafted
huangruizhe/audio/torchaudio/_internal/module_utils.py
code served (permissive licence) · get_code("25d33eba42f595af")
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 bool, ndim 0, dtype family float, shape () as a later run recorded it. The image it ran in was not recorded. If your copy returns the same type, ndim and shape 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

# Set up environment variables for testing
os.environ['TEST_VAR_TRUE'] = '1'
os.environ['TEST_VAR_FALSE'] = '0'
os.environ['TEST_VAR_NOT_SET'] = ''
if 'TEST_VAR_NOT_SET' in os.environ:
    del os.environ['TEST_VAR_NOT_SET']

ARGS = {
    'var': 'TEST_VAR_TRUE',
    'default': False
}
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 bool, ndim 0, dtype family float, shape () — shape () as a later run recorded it
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
fail_with_message Ran
ran; our contract draft was wrong, not the code
huangruizhe/audio/torchaudio/_internal/module_utils.py
code served (permissive licence) · get_code("a62536e09f055a5f")
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 function. 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 torch.nn as nn
from functools import wraps

torch.manual_seed(0)

def fail_with_message(message):
    """Generate decorator to give users message about missing TorchAudio extension."""

    def decorator(func):

        @wraps(func)
        def wrapped(*args, **kwargs):
            raise RuntimeError(f'{func.__module__}.{func.__name__} {message}')
        return wrapped
    return decorator


# The function takes a single parameter: message (a string)
# The function body uses message in an f-string to construct a RuntimeError
# No complex objects needed - just a simple string

ARGS = {
    "message": "is not available. Please install torchaudio."
}
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 function — a function output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a function 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
conv_tasnet_base Not yet run
unverified (harvested, no recorded run)
huangruizhe/audio/torchaudio/models/conv_tasnet.py
code served (permissive licence) · get_code("2f32af51fe66d825")
How it ran

no invocation recorded.

get_labels Not yet run
unverified (harvested, no recorded run)
huangruizhe/audio/.github/process_commit.py
code served (permissive licence) · get_code("57cb0e041c9b422c")
How it ran

no invocation recorded.

get_pr_merger_and_number Not yet run
unverified (harvested, no recorded run)
huangruizhe/audio/.github/process_commit.py
code served (permissive licence) · get_code("9eaef367a8dc3018")
How it ran

no invocation recorded.

hdemucs_high Not yet run
unverified (harvested, no recorded run)
huangruizhe/audio/torchaudio/models/_hdemucs.py
code served (permissive licence) · get_code("b5688413d6c546fb")
How it ran

no invocation recorded.

hdemucs_low Not yet run
unverified (harvested, no recorded run)
huangruizhe/audio/torchaudio/models/_hdemucs.py
code served (permissive licence) · get_code("7d24e3eb5e1c5d98")
How it ran

no invocation recorded.

hdemucs_medium Not yet run
unverified (harvested, no recorded run)
huangruizhe/audio/torchaudio/models/_hdemucs.py
code served (permissive licence) · get_code("12cc644d5df7cb21")
How it ran

no invocation recorded.

query_torchaudio Not yet run
unverified (harvested, no recorded run)
huangruizhe/audio/.github/process_commit.py
code served (permissive licence) · get_code("087f9d0ce1b3f939")
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 (5 with at least one paper dated earlier, 0 the same month, 0 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
eval_env 1 other paper
1 dated earlier
2310.17864 (2023-10)
TorchAudio 2.1: Advancing speech recognition, self-supervised learning, and audio processing components for PyTorch
fail_with_message 1 other paper
1 dated earlier
2310.17864 (2023-10)
TorchAudio 2.1: Advancing speech recognition, self-supervised learning, and audio processing components for PyTorch
get_labels 1 other paper
1 dated earlier
2310.17864 (2023-10)
TorchAudio 2.1: Advancing speech recognition, self-supervised learning, and audio processing components for PyTorch
get_pr_merger_and_number 1 other paper
1 dated earlier
2310.17864 (2023-10)
TorchAudio 2.1: Advancing speech recognition, self-supervised learning, and audio processing components for PyTorch
query_torchaudio 1 other paper
1 dated earlier
2310.17864 (2023-10)
TorchAudio 2.1: Advancing speech recognition, self-supervised learning, and audio processing components for PyTorch

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

Connectionist temporal classification (CTC) models are known to have peaky output distributions. Such behavior is not a problem for automatic speech recognition (ASR), but it can cause inaccurate forced alignments (FA), especially at finer granularity, e.g., phoneme level. This paper aims at alleviating the peaky behavior for CTC and improve its suitability for forced alignment generation, by leveraging label priors, so that the scores of alignment paths containing fewer blanks are boosted and maximized during training. As a result, our CTC model produces less peaky posteriors and is able to more accurately predict the offset of the tokens besides their onset. It outperforms the standard CTC model and a heuristics-based approach for obtaining CTC's token offset timestamps by 12-40% in phoneme and word boundary errors (PBE and WBE) measured on the Buckeye and TIMIT data. Compared with the most widely used FA toolkit Montreal Forced Aligner (MFA), our method performs similarly on PBE/WBE on Buckeye, yet falls behind MFA on TIMIT. Nevertheless, our method has a much simpler training pipeline and better runtime efficiency. Our training recipe and pretrained model are released in TorchAudio.

For agents

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

get_harvested_code_for_paper("2406.02560")
get_code_for_paper("2406.02560")
have("2406.02560")

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

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

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

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

Connect an agent — have() is free.