Update app.py
Browse files190 unmodified lines19119219319419519619719821 unmodified lines220221222223224225226227228190 unmodified linesdef transcribe():try:# Initialize the speaker diarization pipeline with the provided tokenpipeline = Pipeline.from_pretrained("pyannote/speaker-diarization", use_auth_token=hf_token)if pipeline is None:raise ValueError("Failed to initialize the speaker diarization pipeline")print("Speaker diarization pipeline initialized successfully")21 unmodified lines]), download_dataelse:return transcript, Noneprint("Reached end of script definitions")if __name__ == '__main__':print("Starting the Dash application...")app.run(debug=True, host='0.0.0.0', port=7860)190 unmodified lines19119219319419519619719821 unmodified lines220221222223224225226190 unmodified linesdef transcribe():try:# Initialize the speaker diarization pipeline with the provided token and correct locationpipeline = Pipeline.from_pretrained("collinbarnwell/pyannote-speaker-diarization-31", use_auth_token=hf_token)if pipeline is None:raise ValueError("Failed to initialize the speaker diarization pipeline")print("Speaker diarization pipeline initialized successfully")21 unmodified lines]), download_dataelse:return transcript, Noneif __name__ == '__main__':print("Starting the Dash application...")app.run(debug=True, host='0.0.0.0', port=7860)
app.py+3-5