alpeshsonar commited on
Commit
5516ba5
1 Parent(s): a53fb22

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +1 -1
app.py CHANGED
@@ -12,7 +12,7 @@ tokenizer = T5Tokenizer.from_pretrained("alpeshsonar/lot-t5-small-filter", legac
12
  model = T5ForConditionalGeneration.from_pretrained("alpeshsonar/lot-t5-small-filter", torch_dtype=torch.bfloat16).to(device)
13
 
14
  # Gradio interface
15
- @spaces.GPU(duration=360)
16
  def generate_text(input_text):
17
  inputs = tokenizer.encode("Extract lots from given text.\n" + input_text, return_tensors="pt").to(device)
18
  outputs = model.generate(inputs, max_new_tokens=1024)
 
12
  model = T5ForConditionalGeneration.from_pretrained("alpeshsonar/lot-t5-small-filter", torch_dtype=torch.bfloat16).to(device)
13
 
14
  # Gradio interface
15
+ @spaces.GPU(duration=120)
16
  def generate_text(input_text):
17
  inputs = tokenizer.encode("Extract lots from given text.\n" + input_text, return_tensors="pt").to(device)
18
  outputs = model.generate(inputs, max_new_tokens=1024)