Browse Source

增加生成时长

rambo 1 month ago
parent
commit
58b45be892
2 changed files with 3 additions and 3 deletions
  1. 1 1
      python/api.py
  2. 2 2
      python/service/online_request/module_online_data.py

+ 1 - 1
python/api.py

@@ -774,7 +774,7 @@ async def _process_model_images(aigc_clazz, run_main, return_data_check_before_d
                         save_image_path
                     )
                     # 设置70秒超时
-                    image_path = future.result(timeout=70)
+                    image_path = future.result(timeout=80)
                 
                 goods_art_dict_info_item["模特图"] = image_path
                 new_goods_dict[goods_art_no_info]["货号资料"][idx_key] = goods_art_dict_info_item

+ 2 - 2
python/service/online_request/module_online_data.py

@@ -128,7 +128,7 @@ class AIGCDataRequest(object):
         """生成场景图"""
         try:
             url = settings.DOMAIN + "/api/ai_image/inspired/command_to_image"
-            resultData = self.s.post(url, data=data, headers=self.post_headers, timeout=70).json()
+            resultData = self.s.post(url, data=data, headers=self.post_headers, timeout=80).json()
 
             code = resultData.get("code", 0)
             message = resultData.get("message", "")
@@ -247,7 +247,7 @@ class AIGCDataRequest(object):
         if len(generate_ids) == 0:
             raise UnicornException("模特图生成失败")
         generate_id = generate_ids[0]
-        search_times = 60
+        search_times = 80
         status = 0
         result_image = None
         print("generate_id", generate_id)