ultimaxxl commited on
Commit
463eea2
·
verified ·
1 Parent(s): f4e1db8

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -11
app.py CHANGED
@@ -352,18 +352,9 @@ def generate_image(prompt, structure_image, style_image, depth_strength=15, cann
352
  )
353
 
354
  try:
355
- # Get the saved file path
356
- saved_filename = saved_data["ui"]["images"][0]["filename"]
357
- saved_subfolder = saved_data["ui"]["images"][0]["subfolder"]
358
- output_dir = folder_paths.get_output_directory()
359
-
360
- # Construct the full path
361
- if saved_subfolder:
362
- full_path = os.path.join(output_dir, saved_subfolder, saved_filename)
363
- else:
364
- full_path = os.path.join(output_dir, saved_filename)
365
 
366
- return full_path
367
  except Exception as e:
368
  print(f"Error getting saved image path: {e}")
369
  # Fall back to the expected path
 
352
  )
353
 
354
  try:
355
+ saved_path = f"output/{saved_data['ui']['images'][0]['filename']}"
 
 
 
 
 
 
 
 
 
356
 
357
+ return saved_path
358
  except Exception as e:
359
  print(f"Error getting saved image path: {e}")
360
  # Fall back to the expected path