prithivMLmods commited on
Commit
d59b11e
·
verified ·
1 Parent(s): 5aa7be5

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -1
app.py CHANGED
@@ -20,6 +20,7 @@ from pathlib import Path
20
  from datetime import datetime, timezone
21
 
22
  import torch
 
23
  import numpy as np
24
  import cv2
25
  from PIL import Image
@@ -231,7 +232,7 @@ def generate_video_infer(video_path, prompt_text, max_new_tokens=1024, temperatu
231
  # ---------------------------
232
  # Unified generation function for ChatInterface
233
  # ---------------------------
234
-
235
  def generate(input_dict: dict, chat_history: list[dict],
236
  max_new_tokens: int, temperature: float,
237
  top_p: float, top_k: int, repetition_penalty: float):
 
20
  from datetime import datetime, timezone
21
 
22
  import torch
23
+ import spaces
24
  import numpy as np
25
  import cv2
26
  from PIL import Image
 
232
  # ---------------------------
233
  # Unified generation function for ChatInterface
234
  # ---------------------------
235
+ @spaces.GPU
236
  def generate(input_dict: dict, chat_history: list[dict],
237
  max_new_tokens: int, temperature: float,
238
  top_p: float, top_k: int, repetition_penalty: float):