Spaces:
Paused
Paused
Update api/ltx/ltx_aduc_manager.py
Browse files
api/ltx/ltx_aduc_manager.py
CHANGED
|
@@ -139,6 +139,7 @@ class LTXWorker:
|
|
| 139 |
logging.info(f"[LTXWorker-{self.main_device}] ✅ Pipeline 'quente', corrigido e pronto.")
|
| 140 |
|
| 141 |
|
|
|
|
| 142 |
class LTXAducManager:
|
| 143 |
def __init__(self):
|
| 144 |
main_device = gpu_manager.get_ltx_device()
|
|
@@ -146,12 +147,12 @@ class LTXAducManager:
|
|
| 146 |
# Em uma arquitetura futura, poderíamos ter múltiplos workers. Por enquanto, temos um.
|
| 147 |
self.worker = LTXWorker(str(main_device), str(vae_device), load_config())
|
| 148 |
|
| 149 |
-
def load_config(
|
| 150 |
-
|
| 151 |
-
|
| 152 |
-
|
| 153 |
-
|
| 154 |
-
|
| 155 |
def get_pipeline(self) -> LTXVideoPipeline:
|
| 156 |
return self.worker.pipeline
|
| 157 |
|
|
|
|
| 139 |
logging.info(f"[LTXWorker-{self.main_device}] ✅ Pipeline 'quente', corrigido e pronto.")
|
| 140 |
|
| 141 |
|
| 142 |
+
|
| 143 |
class LTXAducManager:
|
| 144 |
def __init__(self):
|
| 145 |
main_device = gpu_manager.get_ltx_device()
|
|
|
|
| 147 |
# Em uma arquitetura futura, poderíamos ter múltiplos workers. Por enquanto, temos um.
|
| 148 |
self.worker = LTXWorker(str(main_device), str(vae_device), load_config())
|
| 149 |
|
| 150 |
+
def load_config() -> Dict:
|
| 151 |
+
"""Loads the YAML configuration file."""
|
| 152 |
+
config_path = LTX_VIDEO_REPO_DIR / "configs" / "ltxv-13b-0.9.8-distilled-fp8.yaml"
|
| 153 |
+
with open(config_path, "r") as file:
|
| 154 |
+
return yaml.safe_load(file)
|
| 155 |
+
|
| 156 |
def get_pipeline(self) -> LTXVideoPipeline:
|
| 157 |
return self.worker.pipeline
|
| 158 |
|