img / app.py
aamsko's picture
Update app.py
51b72e4 verified
raw
history blame contribute delete
597 Bytes
import gradio as gr
from model.face_enhancer import enhance_face
from model.dress_enhancer import enhance_clothes
def enhance_image(input_image):
face_enhanced = enhance_face(input_image)
final_image = enhance_clothes(face_enhanced)
return final_image
demo = gr.Interface(
fn=enhance_image,
inputs=gr.Image(type="pil", label="Upload an image"),
outputs=gr.Image(type="pil", label="Enhanced Image"),
title="Face + Dress Image Enhancer",
description="Enhances facial details using GFPGAN and clothing using SwinIR.",
)
if __name__ == "__main__":
demo.launch()