Spaces:
Runtime error
Runtime error
Update app.py
Browse files59 unmodified lines6061626364656652 unmodified lines11912012112212312412512612712812913059 unmodified linesmargin = 100# Open the original imagesource = image["image"] # Changed from image["background"] to match new input format# Calculate new output sizeoutput_size = (source.width + 2*margin, source.height + 2*margin)52 unmodified linesrun_button = gr.Button("Generate")with gr.Row():input_image = gr.ImageMask(type="pil",label="Input Image",crop_size=(1024, 1024),canvas_size=(1024, 1024),layers=False,sources=["upload"],)59 unmodified lines6061626364656652 unmodified lines11912012112212312412512612759 unmodified linesmargin = 100# Open the original imagesource = image # Changed from image["background"] to match new input format# Calculate new output sizeoutput_size = (source.width + 2*margin, source.height + 2*margin)52 unmodified linesrun_button = gr.Button("Generate")with gr.Row():input_image = gr.Image(type="pil",label="Input Image",sources=["upload"],)
app.py+2-5