Browse Source

previously was checking all nodes for download status which lead to issues when running on multiple nodes. changed it to just check local node when checking model download status

Caden MacKenzie 6 months ago
parent
commit
f8cc54b91b
1 changed files with 1 additions and 8 deletions
  1. 1 8
      exo/api/chatgpt_api.py

+ 1 - 8
exo/api/chatgpt_api.py

@@ -237,14 +237,7 @@ class ChatGPTAPI:
             if model_name in model_cards:
                 model_info = model_cards[model_name]
                 
-                required_engines = list(dict.fromkeys(
-                    [engine_name for engine_list in self.node.topology_inference_engines_pool 
-                     for engine_name in engine_list 
-                     if engine_name is not None] + 
-                    [self.inference_engine_classname]
-                ))
-                
-                if all(map(lambda engine: engine in model_info["repo"], required_engines)):
+                if self.inference_engine_classname in model_info.get("repo", {}):
                     shard = build_base_shard(model_name, self.inference_engine_classname)
                     if shard:
                         downloader = HFShardDownloader(quick_check=True)