Merge pull request #307098 from r-ryantm/auto-update/cilium-cli
[NixPkgs.git] / pkgs / development / python-modules / faster-whisper / default.nix
blob2fe0b785cea6ec76754a7886fa01c430380fe277
1 { lib
2 , buildPythonPackage
3 , fetchFromGitHub
4 , pythonRelaxDepsHook
6 # build-system
7 , setuptools
9 # dependencies
10 , av
11 , ctranslate2
12 , huggingface-hub
13 , onnxruntime
14 , tokenizers
16 # tests
17 , pytestCheckHook
20 buildPythonPackage rec {
21   pname = "faster-whisper";
22   version = "1.0.1";
23   pyproject = true;
25   src = fetchFromGitHub {
26     owner = "SYSTRAN";
27     repo = "faster-whisper";
28     rev = "refs/tags/v${version}";
29     hash = "sha256-b8P9fI32ubOrdayA0vnjLhpZ4qffB6W+8TEOA1YLKqo=";
30   };
32   build-system = [
33     setuptools
34     pythonRelaxDepsHook
35   ];
37   pythonRelaxDeps = [
38     "tokenizers"
39   ];
41   dependencies = [
42     av
43     ctranslate2
44     huggingface-hub
45     onnxruntime
46     tokenizers
47   ];
49   pythonImportsCheck = [
50     "faster_whisper"
51   ];
53   # all tests require downloads
54   doCheck = false;
56   nativeCheckInputs = [
57     pytestCheckHook
58   ];
60   preCheck = ''
61     export HOME=$TMPDIR
62   '';
64   meta = with lib; {
65     changelog = "https://github.com/guillaumekln/faster-whisper/releases/tag/${version}";
66     description = "Faster Whisper transcription with CTranslate2";
67     homepage = "https://github.com/guillaumekln/faster-whisper";
68     license = licenses.mit;
69     maintainers = with maintainers; [ hexa ];
70   };