Update app.py
Browse files
app.py
CHANGED
@@ -7,7 +7,7 @@ import random
|
|
7 |
|
8 |
proc1=diff
|
9 |
proc2=diff
|
10 |
-
|
11 |
#proc2=gr.Interface.load("spaces/Omnibus/fast-diff")
|
12 |
|
13 |
sky = "https://huggingface.co/spaces/Omnibus/game-test/resolve/main/assets/sky.png"
|
@@ -70,11 +70,13 @@ def star_fn(inp):
|
|
70 |
uid=uuid.uuid4()
|
71 |
#output=proc2(inp,5,1)
|
72 |
output=proc2.send_it(inp,5,1)
|
|
|
73 |
#output=dif(inp)
|
74 |
#in_url=f'https://omnibus-fast-diff.hf.space/file={output[0]}'
|
75 |
-
|
76 |
-
print(
|
77 |
-
outp=Image.open(
|
|
|
78 |
width, height = outp.size
|
79 |
rat = width/height
|
80 |
if width > height:
|
|
|
7 |
|
8 |
proc1=diff
|
9 |
proc2=diff
|
10 |
+
bg1=gr.Interface.load("spaces/Omnibus/fast-bg-remove")
|
11 |
#proc2=gr.Interface.load("spaces/Omnibus/fast-diff")
|
12 |
|
13 |
sky = "https://huggingface.co/spaces/Omnibus/game-test/resolve/main/assets/sky.png"
|
|
|
70 |
uid=uuid.uuid4()
|
71 |
#output=proc2(inp,5,1)
|
72 |
output=proc2.send_it(inp,5,1)
|
73 |
+
print(output)
|
74 |
#output=dif(inp)
|
75 |
#in_url=f'https://omnibus-fast-diff.hf.space/file={output[0]}'
|
76 |
+
output_bg=bg1(output[0])
|
77 |
+
print(output_bg)
|
78 |
+
outp=Image.open(output_bg)
|
79 |
+
|
80 |
width, height = outp.size
|
81 |
rat = width/height
|
82 |
if width > height:
|