Spaces:
Running
on
L40S
Running
on
L40S
Update app.py
Browse files
app.py
CHANGED
@@ -149,48 +149,48 @@ div#video-out-elm{
|
|
149 |
def gradio_interface():
|
150 |
with gr.Blocks(css=css) as app:
|
151 |
with gr.Column(elem_id="col-container"):
|
152 |
-
|
153 |
-
|
154 |
-
|
155 |
-
|
156 |
-
|
157 |
-
|
158 |
-
|
159 |
-
|
160 |
-
|
161 |
-
|
162 |
-
|
163 |
-
|
164 |
-
|
165 |
-
|
166 |
-
|
167 |
-
|
168 |
-
|
169 |
-
|
170 |
-
|
171 |
-
|
172 |
-
|
173 |
-
|
174 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
175 |
|
176 |
-
|
177 |
-
|
178 |
-
|
179 |
-
image_mode="RGBA",
|
180 |
-
height=240
|
181 |
-
)
|
182 |
-
|
183 |
-
remove_bg = gr.Checkbox(label="Need to remove BG ?", value=False)
|
184 |
-
|
185 |
-
submit_button = gr.Button("Process")
|
186 |
|
187 |
-
|
188 |
-
|
189 |
-
|
190 |
-
|
191 |
-
|
192 |
-
examples_per_page = 11
|
193 |
-
)
|
194 |
|
195 |
submit_button.click(process_image, inputs=[input_image, remove_bg], outputs=[output_video])
|
196 |
|
|
|
149 |
def gradio_interface():
|
150 |
with gr.Blocks(css=css) as app:
|
151 |
with gr.Column(elem_id="col-container"):
|
152 |
+
gr.Markdown("# PSHuman: Photorealistic Single-image 3D Human Reconstruction using Cross-Scale Multiview Diffusion and Explicit Remeshing")
|
153 |
+
gr.HTML("""
|
154 |
+
<div style="display:flex;column-gap:4px;">
|
155 |
+
<a href="https://github.com/pengHTYX/PSHuman">
|
156 |
+
<img src='https://img.shields.io/badge/GitHub-Repo-blue'>
|
157 |
+
</a>
|
158 |
+
<a href="https://penghtyx.github.io/PSHuman/">
|
159 |
+
<img src='https://img.shields.io/badge/Project-Page-green'>
|
160 |
+
</a>
|
161 |
+
<a href="https://arxiv.org/pdf/2409.10141">
|
162 |
+
<img src='https://img.shields.io/badge/ArXiv-Paper-red'>
|
163 |
+
</a>
|
164 |
+
<a href="https://huggingface.co/spaces/fffiloni/PSHuman?duplicate=true">
|
165 |
+
<img src="https://huggingface.co/datasets/huggingface/badges/resolve/main/duplicate-this-space-sm.svg" alt="Duplicate this Space">
|
166 |
+
</a>
|
167 |
+
<a href="https://huggingface.co/fffiloni">
|
168 |
+
<img src="https://huggingface.co/datasets/huggingface/badges/resolve/main/follow-me-on-HF-sm-dark.svg" alt="Follow me on HF">
|
169 |
+
</a>
|
170 |
+
</div>
|
171 |
+
""")
|
172 |
+
with gr.Group():
|
173 |
+
with gr.Row():
|
174 |
+
with gr.Column(scale=2):
|
175 |
+
|
176 |
+
input_image = gr.Image(
|
177 |
+
label="Image input",
|
178 |
+
type="pil",
|
179 |
+
image_mode="RGBA",
|
180 |
+
height=240
|
181 |
+
)
|
182 |
+
|
183 |
+
remove_bg = gr.Checkbox(label="Need to remove BG ?", value=False)
|
184 |
|
185 |
+
submit_button = gr.Button("Process")
|
186 |
+
|
187 |
+
output_video= gr.Video(label="Output Video", scale=4, elem_id="video-out-elm")
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
188 |
|
189 |
+
gr.Examples(
|
190 |
+
examples = examples_folder,
|
191 |
+
inputs = [input_image],
|
192 |
+
examples_per_page = 11
|
193 |
+
)
|
|
|
|
|
194 |
|
195 |
submit_button.click(process_image, inputs=[input_image, remove_bg], outputs=[output_video])
|
196 |
|