camparchimedes commited on
Commit
1aaa91a
·
verified ·
1 Parent(s): c5b5c40

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -3
app.py CHANGED
@@ -35,7 +35,7 @@ pipe = pipeline("automatic-speech-recognition", model="NbAiLabBeta/nb-whisper-la
35
  language = "no"
36
  task = "transcribe"
37
 
38
- @spaces.GPU(queue=True)
39
  def transcribe_audio(audio_file):
40
  if audio_file.endswith(".m4a"):
41
  audio_file = convert_to_wav(audio_file)
@@ -111,7 +111,6 @@ summarization_model = AutoModelForSeq2SeqLM.from_pretrained("t5-base", return_di
111
  summarization_tokenizer = AutoTokenizer.from_pretrained("t5-base")
112
  summarization_model.to(device)
113
 
114
- @spaces.GPU(queue=True)
115
  def summarize_text(text):
116
  preprocessed_text = preprocess_text(text)
117
  if preprocessed_text is None:
@@ -187,7 +186,7 @@ def text_rank_summary(text, num_paragraphs=3):
187
 
188
  banner_html = """
189
  <div style="text-align: center;">
190
- <img src="https://huggingface.co/spaces/camparchimedes/transcription_app/resolve/main/Olas%20AudioSwitch%20Shop.png" alt="Banner Image" width="100%" height="auto">
191
  </div>
192
  """
193
 
 
35
  language = "no"
36
  task = "transcribe"
37
 
38
+ # @spaces.GPU(queue=True)
39
  def transcribe_audio(audio_file):
40
  if audio_file.endswith(".m4a"):
41
  audio_file = convert_to_wav(audio_file)
 
111
  summarization_tokenizer = AutoTokenizer.from_pretrained("t5-base")
112
  summarization_model.to(device)
113
 
 
114
  def summarize_text(text):
115
  preprocessed_text = preprocess_text(text)
116
  if preprocessed_text is None:
 
186
 
187
  banner_html = """
188
  <div style="text-align: center;">
189
+ <img src="https://github.com/camparchimedes/sw-llm/blob/main/annex/banner_trans.png" alt="Banner Image" width="100%" height="auto">
190
  </div>
191
  """
192