File size: 2,479 Bytes
b13e4db | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 | [project]
name = "prosody_explorer"
version = "0.1.0"
description = "Prosody features to mel to text -- the Prosody2text pipeline"
requires-python = ">=3.10"
dependencies = [
# The feature extractor. amfm-decompy is pinned exactly: f0_interp builds
# a pYAAPT.PitchObj without __init__ and reads class constants off it, so
# a release that moves those to instance attributes breaks gap
# interpolation at runtime rather than at import.
"amfm-decompy==1.0.12.2",
# Praat's intensity analysis. Wheels exist for Linux, macOS and Windows.
"praat-parselmouth>=0.4.7",
"numpy>=1.26",
"scipy>=1.11",
# The conformer is the trained torch module, loaded from safetensors.
"torch>=2.8",
"safetensors>=0.4",
# transformers is pinned to the 5.x line the reference was measured
# against: the beam capture monkeypatches GenerationMixin.generate, so a
# major version is a real compatibility boundary.
"transformers>=5.20,<6",
"tokenizers>=0.23,<0.24",
"huggingface-hub>=0.25",
# Reading an audio file by path. Ships its own libsndfile, so unlike
# torchcodec it needs no system codec.
"soundfile>=0.12",
]
[project.optional-dependencies]
# Only for evaluate_dataset.py. Kept out of the base install because
# `datasets` pulls a large tree the pipeline itself never touches.
#
# soundfile rather than torchcodec, deliberately: datasets 5.x decodes audio
# through torchcodec, which dlopens system FFmpeg libraries and so fails
# with "libavutil.so not found" on a machine that has only wheels. The
# script asks datasets for undecoded bytes and reads them with soundfile,
# which ships its own libsndfile.
eval = [
"datasets>=3.0",
"jiwer>=4.0.0",
"soundfile>=0.12",
]
[build-system]
requires = ["hatchling"]
build-backend = "hatchling.build"
# The modeling files sit at the repo root, which is the Hub's own convention
# for a custom architecture. Mapping them into a package here lets the same
# files be imported normally by anything that installs this -- so the Space
# can `from prosody_explorer.features import ...` at module level rather
# than reaching into the revision-hashed path trust_remote_code creates.
[tool.hatch.build.targets.wheel]
only-include = [
"features.py", "f0_interp.py", "_yaapt_patch.py",
"speech.py", "conformer.py", "conformer_model.py",
"whisper_decoder.py", "configuration_prosody.py", "modeling_prosody.py",
]
sources = { "" = "prosody_explorer" }
|