Spaces:
Running
on
Zero
Running
on
Zero
Update app.py
Browse files
app.py
CHANGED
@@ -8,6 +8,8 @@ from t2v_metrics import VQAScore, list_all_vqascore_models
|
|
8 |
def update_model(model_name):
|
9 |
return VQAScore(model=model_name, device="cuda")
|
10 |
|
|
|
|
|
11 |
# Global model variable, but do not initialize or move to CUDA here
|
12 |
cur_model_name = "clip-flant5-xl"
|
13 |
model_pipe = update_model(cur_model_name)
|
|
|
8 |
def update_model(model_name):
|
9 |
return VQAScore(model=model_name, device="cuda")
|
10 |
|
11 |
+
global model_pipe
|
12 |
+
|
13 |
# Global model variable, but do not initialize or move to CUDA here
|
14 |
cur_model_name = "clip-flant5-xl"
|
15 |
model_pipe = update_model(cur_model_name)
|