Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
@@ -38,7 +38,7 @@ projection = torch.nn.Linear(clip_embed, phi_embed).to(device)
|
|
38 |
resblock = SimpleResBlock(phi_embed).to(device)
|
39 |
phi_model = AutoModelForCausalLM.from_pretrained(phi_model_name,trust_remote_code=True).to(device)
|
40 |
# Assuming you have defined 'device' and 'compute_type' elsewhere
|
41 |
-
audio_model = whisperx.load_model("tiny", device, compute_type=compute_type, asr_options={'max_new_tokens': 2048, 'clip_timestamps': True, 'hallucination_silence_threshold': 0.25
|
42 |
|
43 |
# load weights
|
44 |
model_to_merge = PeftModel.from_pretrained(phi_model,os.path.join(os.getcwd(), 'model_chkpt/lora_adaptor'))
|
|
|
38 |
resblock = SimpleResBlock(phi_embed).to(device)
|
39 |
phi_model = AutoModelForCausalLM.from_pretrained(phi_model_name,trust_remote_code=True).to(device)
|
40 |
# Assuming you have defined 'device' and 'compute_type' elsewhere
|
41 |
+
audio_model = whisperx.load_model("tiny", device, compute_type=compute_type, asr_options={'max_new_tokens': 2048, 'clip_timestamps': True, 'hallucination_silence_threshold': 0.25})
|
42 |
|
43 |
# load weights
|
44 |
model_to_merge = PeftModel.from_pretrained(phi_model,os.path.join(os.getcwd(), 'model_chkpt/lora_adaptor'))
|