Update app.py
Browse files26 unmodified lines2728293031323328 unmodified lines6263646526 unmodified lines# Resize or crop image to fit the grid cell sizeimg_width = collage_width // colsimg_height = collage_height // rowsimg_resized = img.resize((img_width, img_height), Image.ANTIALIAS) # Resize to fitresized_images.append(img_resized)# Place images on the canvas in grid format without spacing28 unmodified linesdownload_button = gr.Button("Download Collage")download_button.click(create_collage, inputs=[uploaded_files, grid_layout], outputs=output)app.launch()26 unmodified lines2728293031323328 unmodified lines6263646526 unmodified lines# Resize or crop image to fit the grid cell sizeimg_width = collage_width // colsimg_height = collage_height // rowsimg_resized = img.resize((img_width, img_height), Image.Resampling.LANCZOS) # Resize to fitresized_images.append(img_resized)# Place images on the canvas in grid format without spacing28 unmodified linesdownload_button = gr.Button("Download Collage")download_button.click(create_collage, inputs=[uploaded_files, grid_layout], outputs=output)app.launch(share=True) # Public link to share the app
app.py+2-2