Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
|
@@ -22,7 +22,7 @@ from fastapi.responses import HTMLResponse
|
|
| 22 |
from pydantic import BaseModel, Field
|
| 23 |
from typing import List, Dict, Tuple
|
| 24 |
|
| 25 |
-
from model_definition import
|
| 26 |
|
| 27 |
|
| 28 |
from simulation_modules import InterfuserController, Tracker
|
|
@@ -42,7 +42,7 @@ app = FastAPI(
|
|
| 42 |
)
|
| 43 |
|
| 44 |
# متغيرات عامة سيتم تهيئتها عند بدء التشغيل
|
| 45 |
-
MODEL:
|
| 46 |
DEVICE = torch.device("cuda" if torch.cuda.is_available() else "cpu")
|
| 47 |
SESSIONS: Dict[str, Dict] = {} # قاموس لتخزين حالة الجلسات النشطة
|
| 48 |
|
|
|
|
| 22 |
from pydantic import BaseModel, Field
|
| 23 |
from typing import List, Dict, Tuple
|
| 24 |
|
| 25 |
+
from model_definition import InterfuserHDPE , load_and_prepare_model, get_master_config
|
| 26 |
|
| 27 |
|
| 28 |
from simulation_modules import InterfuserController, Tracker
|
|
|
|
| 42 |
)
|
| 43 |
|
| 44 |
# متغيرات عامة سيتم تهيئتها عند بدء التشغيل
|
| 45 |
+
MODEL: InterfuserHDPE = None
|
| 46 |
DEVICE = torch.device("cuda" if torch.cuda.is_available() else "cpu")
|
| 47 |
SESSIONS: Dict[str, Dict] = {} # قاموس لتخزين حالة الجلسات النشطة
|
| 48 |
|