add changes in pdf logic

changes:
   1. Remove `/` file (just missed click when create it);
   2. Add filename input for pdf;
   3. Now pdf file saves.
This commit is contained in:
swrneko
2025-09-09 18:24:18 +03:00
parent 240c39cab2
commit 83e19c471a
5 changed files with 21 additions and 38 deletions

View File

@@ -2,7 +2,7 @@ from faster_whisper import WhisperModel
class FasterWhisper:
def recognize(self, model, audioFile, beamSize, vadFilter, minSilenceDurationMs, speechPadMs, temp0, temp1, temp2, wordTimestamps, noSpeechThreshold, conditionOnPreviousText):
model = WhisperModel(model, device='auto', compute_type='auto') # Задаем модель
model = WhisperModel(model, device='cuda', compute_type='auto') # Задаем модель
segments, _ = model.transcribe( # Распознаем текст
audioFile,