Spaces:
Running
Running
Update generator_function/multimodel_image_processor.py
Browse files
generator_function/multimodel_image_processor.py
CHANGED
|
@@ -99,7 +99,7 @@ def process_image_files_multimodel(image_files: List[Tuple[str, str]], category:
|
|
| 99 |
inputs = {"file_name": file_name, "mode": "img_or_zip_multimodel"}
|
| 100 |
job_id = start_job(
|
| 101 |
COL,
|
| 102 |
-
type="
|
| 103 |
created_by=uid,
|
| 104 |
category=category or "general",
|
| 105 |
inputs=inputs,
|
|
@@ -214,11 +214,11 @@ def generate_image_multimodel(file_path: str, model_name: str, category: str, se
|
|
| 214 |
if all_params["aspect_ratio"] == "match_input_image": # This is the default
|
| 215 |
converted_ratio = convert_size_to_aspect_ratio(size, model_name)
|
| 216 |
all_params["aspect_ratio"] = converted_ratio
|
| 217 |
-
logger.info(f"Converted size '{size}' to aspect ratio '{converted_ratio}' for {model_name}")
|
| 218 |
else:
|
| 219 |
logger.info(f"Using user-selected aspect ratio '{all_params['aspect_ratio']}' for {model_name}")
|
| 220 |
|
| 221 |
-
logger.info(f"Final parameters for {model_name}: {all_params}")
|
| 222 |
|
| 223 |
# Generate image with selected model
|
| 224 |
generated_image_data = generate_image_with_model(
|
|
|
|
| 99 |
inputs = {"file_name": file_name, "mode": "img_or_zip_multimodel"}
|
| 100 |
job_id = start_job(
|
| 101 |
COL,
|
| 102 |
+
type="variation",
|
| 103 |
created_by=uid,
|
| 104 |
category=category or "general",
|
| 105 |
inputs=inputs,
|
|
|
|
| 214 |
if all_params["aspect_ratio"] == "match_input_image": # This is the default
|
| 215 |
converted_ratio = convert_size_to_aspect_ratio(size, model_name)
|
| 216 |
all_params["aspect_ratio"] = converted_ratio
|
| 217 |
+
# logger.info(f"Converted size '{size}' to aspect ratio '{converted_ratio}' for {model_name}")
|
| 218 |
else:
|
| 219 |
logger.info(f"Using user-selected aspect ratio '{all_params['aspect_ratio']}' for {model_name}")
|
| 220 |
|
| 221 |
+
# logger.info(f"Final parameters for {model_name}: {all_params}")
|
| 222 |
|
| 223 |
# Generate image with selected model
|
| 224 |
generated_image_data = generate_image_with_model(
|