mgruner commited on
Commit
6621c34
·
2 Parent(s): 9faef73 fa1dce6

Merge branch 'feature/local-asr-demo'

Browse files
Files changed (3) hide show
  1. pyproject.toml +4 -1
  2. run.py +13 -3
  3. uv.lock +0 -0
pyproject.toml CHANGED
@@ -4,4 +4,7 @@ version = "0.1.0"
4
  description = "Huggingface Space to test NVIDIA Nemo's Parakeet v2 speech recognition model."
5
  readme = "README.md"
6
  requires-python = ">=3.10"
7
- dependencies = []
 
 
 
 
4
  description = "Huggingface Space to test NVIDIA Nemo's Parakeet v2 speech recognition model."
5
  readme = "README.md"
6
  requires-python = ">=3.10"
7
+ dependencies = [
8
+ "nemo-toolkit[asr]>=2.2.1",
9
+ "numpy<2.0",
10
+ ]
run.py CHANGED
@@ -1,6 +1,16 @@
1
- def main():
2
- print("Hello from parakeet-tdt-0-6b-v2!")
 
 
 
 
 
 
 
 
 
 
3
 
4
 
5
  if __name__ == "__main__":
6
- main()
 
1
+ import sys
2
+
3
+ import nemo.collections.asr as nemo_asr
4
+
5
+
6
+ def main(argv):
7
+ model = nemo_asr.models.ASRModel.from_pretrained(
8
+ model_name="nvidia/parakeet-tdt-0.6b-v2"
9
+ )
10
+
11
+ output = model.transcribe([argv[1]])
12
+ print(output[0].text)
13
 
14
 
15
  if __name__ == "__main__":
16
+ main(sys.argv)
uv.lock ADDED
The diff for this file is too large to render. See raw diff