SYNTOLOGY HomeExplorerAtlasCodeMethodologyAboutDevelopersFeedPricing
Paper · 2006.13979 · 2020

Unsupervised Cross-lingual Representation Learning for Speech Recognition

arXiv · PDF · Open in the Atlas

Code that ran

3 of 6 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, 0 violated it and 3 have no contract verdict; 0 failures of our instrument; 3 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/2006.13979.json · badge: /api/ran/2006.13979.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
HLasse/wav2vec_finetune community (classifier label)
classifier basis not recorded on the link
3 ran · 3 no recorded run
FunctionStatusWhere it lives
label2id Ran
ran on a synthesized input
HLasse/wav2vec_finetune/train_baseline_models.py
code served (permissive licence) · get_code("2e846888099ed9e1")
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 torch

torch.manual_seed(0)

# The function label2id takes two parameters:
# 1. col: a key to look up in the mapping
# 2. mapping: a dictionary that maps col to some value

# From the function body, we see:
# - col is used as a key in mapping
# - mapping[col] is accessed and returned in a dict with key 'label_id'

col = "class_a"
mapping = {
    "class_a": 0,
    "class_b": 1,
    "class_c": 2,
}

ARGS = {
    "col": col,
    "mapping": mapping,
}
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
make_config Ran
ran on a synthesized input
HLasse/wav2vec_finetune/configs/make_binary_wav2vec_configs.py
code served (permissive licence) · get_code("799709e0afdff68f")
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 torch
import torch.nn as nn

torch.manual_seed(0)

# Construct arguments for make_config
ARGS = {
    'model_name': 'wav2vec2-base',
    'train': '/path/to/train.csv',
    'validation': '/path/to/validation.csv',
    'augmentations': 'specaugment',
    'output_dir': '/tmp/output',
    'run_name': 'test_run'
}
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
stack_frames Ran
ran on a synthesized input
HLasse/wav2vec_finetune/src/make_windows.py
code served (permissive licence) · get_code("9222522c819be1f6")
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 ndarray, ndim 2, dtype family float, shape (9, 5) 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 numpy as np
import math

sig = np.arange(0, 20)

sampling_rate = 1

frame_length = 5

frame_stride = 2

zero_padding = True

def stack_frames(sig, sampling_rate, frame_length, frame_stride, filter=lambda x: np.ones((x,)), zero_padding=True, keep_short_signals=True, remove_zero_padding=False):
    """Frame a signal into overlapping frames.
    Args:
        sig (array): The audio signal to frame of size (N,).
        sampling_rate (int): The sampling frequency of the signal.
        frame_length (float): The length of the frame in second.
        frame_stride (float): The stride between frames.
        filter (array): The time-domain filter for applying to each frame.
            By default it is one so nothing will be changed.
        zero_padding (bool): If the samples is not a multiple of
            frame_length(number of frames sample), zero padding will
            be done for generating last frame.
        keep_short_signal:  Return the original signal if shorter than frame_length.
        remove_zero_padding: Remove trailing zeros from last element following zero padding
    Returns:
            array: Stacked_frames-Array of frames of size (number_of_frames x frame_len).
    """
    s = 'Signal dimention should be of the format of (N,) but it is %s instead'
    assert sig.ndim == 1, s % str(sig.shape)
    length_signal = sig.shape[0]
    frame_sample_length = int(np.round(sampling_rate * frame_length))
    frame_stride = float(np.round(sampling_rate * frame_stride))
    signal_length = len(sig) / sampling_rate
    if signal_length < frame_length:
        if keep_short_signals:
            if zero_padding:
                return np.expand_dims(sig, axis=0)
            return np.expand_dims(sig, axis=0)
        else:
            raise ValueError(f'Signal is shorter than frame length {signal_length} vs {frame_length}. Set `keep_short_signal` to True to return the original signal in such cases.')
    if zero_padding:
        numframes = int(math.ceil((length_signal - (frame_sample_length - frame_stride)) / frame_stride))
        len_sig = int(numframes * frame_stride + frame_sample_length)
        additive_zeros = np.zeros((len_sig - length_signal,))
        signal = np.concatenate((sig, additive_zeros))
    else:
        numframes = int(math.floor((length_signal - frame_sample_length) / frame_stride))
        len_sig = int((numframes - 1) * frame_stride + frame_sample_length)
        signal = sig[0:len_sig]
    indices = np.tile(np.arange(0, frame_sample_length), (numframes, 1)) + np.tile(np.arange(0, numframes * frame_stride, frame_stride), (frame_sample_length, 1)).T
    indices = np.array(indices, dtype=np.int32)
    frames = signal[indices]
    window = np.tile(filter(frame_sample_length), (numframes, 1))
    Extracted_Frames = frames * window
    if remove_zero_padding:
        Extracted_Frames[-1] = np.trim_zeros(Extracted_Frames[-1], trim='b')
    return Extracted_Frames


# Create a simple filter function that takes an integer and returns an array
def simple_filter(x):
    return np.ones((x,))

# Setup arguments
ARGS = {
    'sig': np.arange(0, 20, dtype=np.float32),
    'sampling_rate': 1,
    'frame_length': 5,
    'frame_stride': 2,
    'filter': simple_filter,
    'zero_padding': True,
    'keep_short_signals': True,
    'remove_zero_padding': False
}
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 ndarray, ndim 2, dtype family float, shape (9, 5) — shape (9, 5) 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
create_trainer Not yet run
unverified (harvested, no recorded run)
HLasse/wav2vec_finetune/train_baseline_models.py
code served (permissive licence) · get_code("1ac327c3640acdb7")
How it ran

no invocation recorded.

map_l2id Not yet run
unverified (harvested, no recorded run)
HLasse/wav2vec_finetune/train_wav2vec_streaming.py
code served (permissive licence) · get_code("61f33bdd096359a4")
How it ran

no invocation recorded.

preprocess_stacked_speech_files Not yet run
unverified (harvested, no recorded run)
HLasse/wav2vec_finetune/train_wav2vec_streaming.py
code served (permissive licence) · get_code("2c5f5e77e1131aae")
How it ran

no invocation recorded.

Also present in other papers' code

Of 6 samples lifted from this paper's linked repositories, 6 carry a function identity and 0 do not. Of the 6 distinct functions with an identity, 0 are also present in other papers whose code we hold (0 with at least one paper dated earlier, 0 the same month, 0 later) and 6 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.

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

This paper presents XLSR which learns cross-lingual speech representations by pretraining a single model from the raw waveform of speech in multiple languages. We build on wav2vec 2.0 which is trained by solving a contrastive task over masked latent speech representations and jointly learns a quantization of the latents shared across languages. The resulting model is fine-tuned on labeled data and experiments show that cross-lingual pretraining significantly outperforms monolingual pretraining. On the CommonVoice benchmark, XLSR shows a relative phoneme error rate reduction of 72% compared to the best known results. On BABEL, our approach improves word error rate by 16% relative compared to a comparable system. Our approach enables a single multilingual speech recognition model which is competitive to strong individual models. Analysis shows that the latent discrete speech representations are shared across languages with increased sharing for related languages. We hope to catalyze research in low-resource speech understanding by releasing XLSR-53, a large model pretrained in 53 languages.

For agents

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

get_harvested_code_for_paper("2006.13979")
get_code_for_paper("2006.13979")
have("2006.13979")

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

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

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

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

Connect an agent — have() is free.