Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
|
@@ -1,17 +1,4 @@
|
|
| 1 |
-
|
| 2 |
-
from gfpgan import GFPGANer
|
| 3 |
-
import cv2
|
| 4 |
|
| 5 |
-
|
| 6 |
-
|
| 7 |
-
upscale=1,
|
| 8 |
-
arch='clean',
|
| 9 |
-
channel_multiplier=2,
|
| 10 |
-
bg_upsampler=None
|
| 11 |
-
)
|
| 12 |
-
|
| 13 |
-
def restore_image(img):
|
| 14 |
-
cropped_faces, restored_faces, restored_img = restorer.enhance(img, has_aligned=False, only_center_face=False)
|
| 15 |
-
return restored_img
|
| 16 |
-
|
| 17 |
-
gr.Interface(fn=restore_image, inputs=gr.Image(type='numpy'), outputs=gr.Image(type='numpy')).launch()
|
|
|
|
| 1 |
+
from gfpgan_cpu import create_gradio_app
|
|
|
|
|
|
|
| 2 |
|
| 3 |
+
app = create_gradio_app()
|
| 4 |
+
app.launch()
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|