Spaces:
Build error
Build error
Sophie98
commited on
Commit
β’
f496440
1
Parent(s):
f6357b6
try to fix error
Browse files- app.py +6 -12
- requirements.txt +1 -1
app.py
CHANGED
@@ -112,21 +112,15 @@ def style_sofa(input_img: np.ndarray, style_img: np.ndarray):
|
|
112 |
print('Finishing job', id)
|
113 |
return new_sofa
|
114 |
|
115 |
-
image = gr.inputs.Image()
|
116 |
-
style = gr.inputs.Image()
|
117 |
-
|
118 |
-
# Examples
|
119 |
-
example1 = ['sofa_example1.jpg','style_example1.jpg']
|
120 |
-
example2 = ['sofa_example1.jpg','style_example2.jpg']
|
121 |
-
example3 = ['sofa_example1.jpg','style_example3.jpg']
|
122 |
-
example4 = ['sofa_example1.jpg','style_example4.jpg']
|
123 |
-
example5 = ['sofa_example1.jpg','style_example5.jpg']
|
124 |
-
|
125 |
demo = gr.Interface(
|
126 |
style_sofa,
|
127 |
-
inputs = [
|
128 |
outputs = 'image',
|
129 |
-
examples= [
|
|
|
|
|
|
|
|
|
130 |
title="π Style your sofa π ",
|
131 |
description="Customize your sofa to your wildest dreams π!\
|
132 |
\nProvide a picture of your sofa and a desired pattern\
|
|
|
112 |
print('Finishing job', id)
|
113 |
return new_sofa
|
114 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
115 |
demo = gr.Interface(
|
116 |
style_sofa,
|
117 |
+
inputs = [gr.inputs.Image(),gr.inputs.Image()],
|
118 |
outputs = 'image',
|
119 |
+
examples= [['sofa_example1.jpg','style_example1.jpg'],
|
120 |
+
['sofa_example1.jpg','style_example2.jpg'],
|
121 |
+
['sofa_example1.jpg','style_example3.jpg'],
|
122 |
+
['sofa_example1.jpg','style_example4.jpg'],
|
123 |
+
['sofa_example1.jpg','style_example5.jpg']],
|
124 |
title="π Style your sofa π ",
|
125 |
description="Customize your sofa to your wildest dreams π!\
|
126 |
\nProvide a picture of your sofa and a desired pattern\
|
requirements.txt
CHANGED
@@ -9,7 +9,7 @@ gradio
|
|
9 |
|
10 |
segmentation_models
|
11 |
opencv-python-headless
|
12 |
-
tensorflow
|
13 |
tensorflow_hub
|
14 |
|
15 |
paddlepaddle
|
|
|
9 |
|
10 |
segmentation_models
|
11 |
opencv-python-headless
|
12 |
+
tensorflow
|
13 |
tensorflow_hub
|
14 |
|
15 |
paddlepaddle
|