tykiww commited on
Commit
f76c4e6
1 Parent(s): 787ed4d

Update services/asr.py

Browse files
Files changed (1) hide show
  1. services/asr.py +3 -1
services/asr.py CHANGED
@@ -12,7 +12,9 @@ class Transcriber:
12
  model=self.conf["model"]["asr"]["transcriber"],
13
  device=0 if torch.cuda.is_available() else -1 # Use 0 for GPU, -1 for CPU
14
  )
15
-
 
 
16
  def run(self, file_path):
17
  kwargs = {"max_new_tokens": self.conf["model"]["asr"]["max_new_tokens"]}
18
  output = self.pipeline(
 
12
  model=self.conf["model"]["asr"]["transcriber"],
13
  device=0 if torch.cuda.is_available() else -1 # Use 0 for GPU, -1 for CPU
14
  )
15
+ def get_pipeline(self):
16
+ return self.pipeline
17
+
18
  def run(self, file_path):
19
  kwargs = {"max_new_tokens": self.conf["model"]["asr"]["max_new_tokens"]}
20
  output = self.pipeline(