ishworrsubedii commited on
Commit
af9b32a
·
1 Parent(s): 71bc000

add: new endpoint product page-->batch nto,cto,mto generation

Browse files
src/components/product_page_nto_cto_gen.py CHANGED
@@ -232,41 +232,4 @@ class ProductPageImageGeneration:
232
  logger.error(f"Error processing {clothing_type}: {str(e)}")
233
  print(f"Error processing {clothing_type}: {str(e)}")
234
 
235
- return results
236
-
237
-
238
- # Example usage:
239
- """
240
- processor = FashionTryOnProcessor()
241
-
242
- # Configuration
243
- necklace_config = {
244
- "id": "necklace123",
245
- "category": "traditional",
246
- "store_name": "jewelry_store",
247
- "offset_x": 0,
248
- "offset_y": 0
249
- }
250
-
251
- clothing_list = ["silk saree", "kurti", "casual dress"]
252
-
253
- makeup_colors = MakeupColors(
254
- lipstick="Carmine Red",
255
- eyeliner="Black",
256
- eyeshadow="Maroon"
257
- )
258
-
259
- # Process everything
260
- results = processor.process_full_tryon_sequence(
261
- model_image_path="path/to/model/image.jpg",
262
- model_id="model123",
263
- necklace_config=necklace_config,
264
- clothing_list=clothing_list,
265
- makeup_colors=makeup_colors
266
- )
267
-
268
- # Print results
269
- print("Necklace try-ons:", len(results["nto_results"]))
270
- print("Clothing try-ons:", len(results["cto_results"]))
271
- print("Makeup try-ons:", len(results["mto_results"]))
272
- """
 
232
  logger.error(f"Error processing {clothing_type}: {str(e)}")
233
  print(f"Error processing {clothing_type}: {str(e)}")
234
 
235
+ return results