Spaces:
Running
on
Zero
Running
on
Zero
add some log
Browse files
Rodin.py
CHANGED
@@ -192,6 +192,7 @@ class Generator:
|
|
192 |
log("ERROR", f"Error in image preprocessing: {preprocess_response}")
|
193 |
raise gr.Error("Busy connection, please try again later.")
|
194 |
|
|
|
195 |
return prompt, processed_image
|
196 |
|
197 |
def generate_mesh(self, prompt, processed_image, task_uuid=""):
|
@@ -236,9 +237,7 @@ class Generator:
|
|
236 |
|
237 |
response = requests.get(preview_image, stream=True)
|
238 |
if response.status_code == 200:
|
239 |
-
# 创建一个PIL Image对象
|
240 |
image = Image.open(response.raw)
|
241 |
-
# 在这里对image对象进行处理,如显示、保存等
|
242 |
else:
|
243 |
log("ERROR", f"Error in generating mesh: {response}")
|
244 |
raise RuntimeError
|
|
|
192 |
log("ERROR", f"Error in image preprocessing: {preprocess_response}")
|
193 |
raise gr.Error("Busy connection, please try again later.")
|
194 |
|
195 |
+
log("INFO", "Image preprocessed successfully")
|
196 |
return prompt, processed_image
|
197 |
|
198 |
def generate_mesh(self, prompt, processed_image, task_uuid=""):
|
|
|
237 |
|
238 |
response = requests.get(preview_image, stream=True)
|
239 |
if response.status_code == 200:
|
|
|
240 |
image = Image.open(response.raw)
|
|
|
241 |
else:
|
242 |
log("ERROR", f"Error in generating mesh: {response}")
|
243 |
raise RuntimeError
|