sc45 commited on
Commit
6e84375
1 Parent(s): 2a3563d
Files changed (1) hide show
  1. diarization.py +2 -2
diarization.py CHANGED
@@ -8,8 +8,8 @@ def perform_diarization(audio_file_path, translated_file_path, output_dir='./aud
8
 
9
  # Initialize diarization pipeline
10
  accesstoken = os.environ['Diarization']
11
- pipeline = Pipeline.from_pretrained("pyannote/speaker-diarization-3.1", token=accesstoken )
12
-
13
  # Send pipeline to GPU (when available)
14
  pipeline.to(torch.device("cuda" if torch.cuda.is_available() else "cpu"))
15
 
 
8
 
9
  # Initialize diarization pipeline
10
  accesstoken = os.environ['Diarization']
11
+ pipeline = Pipeline.from_pretrained("pyannote/speaker-diarization-3.1", use_auth_token=accesstoken )
12
+
13
  # Send pipeline to GPU (when available)
14
  pipeline.to(torch.device("cuda" if torch.cuda.is_available() else "cpu"))
15