Skip to content

Commit

Permalink
python3Packages.whisperx: init at 3.3.1
Browse files Browse the repository at this point in the history
  • Loading branch information
Benjamin Sparks committed Feb 18, 2025
1 parent 332682c commit 171f90f
Show file tree
Hide file tree
Showing 3 changed files with 66 additions and 0 deletions.
1 change: 1 addition & 0 deletions pkgs/by-name/wh/whisperx/package.nix
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
{ pkgs }: with pkgs.python3Packages; toPythonApplication whisperx
63 changes: 63 additions & 0 deletions pkgs/development/python-modules/whisperx/default.nix
Original file line number Diff line number Diff line change
@@ -0,0 +1,63 @@
{
lib,
buildPythonPackage,
fetchFromGitHub,

setuptools,

ctranslate2,
faster-whisper,
ffmpeg,
nltk,
pandas,
pyannote-audio,
torch,
torchaudio,
transformers,
}:
buildPythonPackage rec {
pname = "whisperx";
version = "3.3.1";
pyproject = true;

src = fetchFromGitHub {
owner = "m-bain";
repo = "whisperX";
tag = "v${version}";
hash = "sha256-Wb9jKTs0rTdgjvcnKl1P8Uh6b5jzlkKgQBcJYA+7+W4=";
};

build-system = [ setuptools ];

dependencies = [
ctranslate2
faster-whisper
nltk
pandas
pyannote-audio
torch
torchaudio
transformers
];

pythonRelaxDeps = [
"ctranslate2"
"faster-whisper"
];

pythonImportsCheck = [ "whisperx" ];

# No tests in repository
doCheck = false;

makeWrapperArgs = [ "--prefix PATH : ${lib.makeBinPath [ ffmpeg ]}" ];

meta = {
mainProgram = "whisperx";
description = "Automatic Speech Recognition with Word-level Timestamps (& Diarization) ";

platforms = lib.platforms.all;
license = lib.licenses.bsd2;
maintainers = with lib.maintainers; [ bengsparks ];
};
}
2 changes: 2 additions & 0 deletions pkgs/top-level/python-packages.nix
Original file line number Diff line number Diff line change
Expand Up @@ -18324,6 +18324,8 @@ self: super: with self; {

whispers = callPackage ../development/python-modules/whispers { };

whisperx = callPackage ../development/python-modules/whisperx { };

whitenoise = callPackage ../development/python-modules/whitenoise { };

whodap = callPackage ../development/python-modules/whodap { };
Expand Down

0 comments on commit 171f90f

Please sign in to comment.