Spaces:
Runtime error
Runtime error
Commit
·
70ff206
1
Parent(s):
6783bbb
Update app.py
Browse files
app.py
CHANGED
@@ -174,5 +174,6 @@ def infer(frameA, frameB):
|
|
174 |
return "predicted_flow.jpg", ["flofile.flo"]
|
175 |
|
176 |
description="<p style='text-align:center'>PyTorch way to Generate optical flow image & .flo file from 2 consecutive frames with RAFT model</p>"
|
177 |
-
|
178 |
-
|
|
|
|
174 |
return "predicted_flow.jpg", ["flofile.flo"]
|
175 |
|
176 |
description="<p style='text-align:center'>PyTorch way to Generate optical flow image & .flo file from 2 consecutive frames with RAFT model</p>"
|
177 |
+
examples=[["./basket1.jpg","./basket2.jpg"]]
|
178 |
+
examples=[["./basket1.jpg","./basket2.jpg"]]
|
179 |
+
gr.Interface(fn=infer, inputs=[gr.Image(source="upload", type="filepath", label="frame 1"), gr.Image(source="upload", type="filepath", label="frame 2")], outputs=[gr.Image(label="flow image"), gr.Files(label="flow file")], title="RAFT Optical Flow", description=description, examples=examples).launch(debug=True)
|