diff options
Diffstat (limited to 'pkgs/development/python-modules/pyannote-audio/default.nix')
-rw-r--r-- | pkgs/development/python-modules/pyannote-audio/default.nix | 46 |
1 files changed, 29 insertions, 17 deletions
diff --git a/pkgs/development/python-modules/pyannote-audio/default.nix b/pkgs/development/python-modules/pyannote-audio/default.nix index 661bf3cd3ff4e..3a3ee228bcc87 100644 --- a/pkgs/development/python-modules/pyannote-audio/default.nix +++ b/pkgs/development/python-modules/pyannote-audio/default.nix @@ -1,59 +1,64 @@ { lib, - buildPythonPackage, - fetchFromGitHub, - setuptools, - wheel, asteroid-filterbanks, + buildPythonPackage, einops, + fetchFromGitHub, huggingface-hub, - pytorch-lightning, + hydra-core, + numpy, omegaconf, pyannote-core, pyannote-database, pyannote-metrics, pyannote-pipeline, + pyscaffold, + pythonOlder, + pytorch-lightning, pytorch-metric-learning, rich, semver, + setuptools, soundfile, speechbrain, tensorboardx, - torch, torch-audiomentations, + torch, torchaudio, torchmetrics, - numpy, - pyscaffold, + typer, }: buildPythonPackage rec { pname = "pyannote-audio"; - version = "3.1.1"; + version = "3.3.0"; pyproject = true; + disabled = pythonOlder "3.9"; + src = fetchFromGitHub { owner = "pyannote"; repo = "pyannote-audio"; - rev = version; - hash = "sha256-BxmEJE6v+QkEaAJ2oB2LwDQIoRajv6F9SRc8lP9iRLM="; + rev = "refs/tags/${version}"; + hash = "sha256-AFBT6vpOgEIqEn778TWJ04gai7UOyfOeZdmtliYJLvs="; fetchSubmodules = true; }; - nativeBuildInputs = [ + pythonRelaxDeps = [ "torchaudio" ]; + + build-system = [ pyscaffold setuptools - wheel ]; postPatch = '' substituteInPlace setup.cfg \ - --replace "pyscaffold>=3.2a0,<3.3a0" "pyscaffold" + --replace-fail "pyscaffold>=3.2a0,<3.3a0" "pyscaffold" substituteInPlace requirements.txt \ - --replace "lightning" "pytorch-lightning" + --replace-fail "lightning" "pytorch-lightning" ''; - propagatedBuildInputs = [ + dependencies = [ asteroid-filterbanks einops huggingface-hub @@ -76,6 +81,13 @@ buildPythonPackage rec { pytorch-lightning ]; + optional-dependencies = { + cli = [ + hydra-core + typer + ]; + }; + pythonImportsCheck = [ "pyannote.audio" ]; meta = with lib; { @@ -83,6 +95,6 @@ buildPythonPackage rec { homepage = "https://github.com/pyannote/pyannote-audio"; changelog = "https://github.com/pyannote/pyannote-audio/blob/${src.rev}/CHANGELOG.md"; license = licenses.mit; - maintainers = with maintainers; [ ]; + maintainers = [ ]; }; } |