Spaces:
Running
on
Zero
Running
on
Zero
ThunderVVV
commited on
Commit
·
7268007
1
Parent(s):
a18bffa
update
Browse files- app.py +3 -1
- example/segment_017.mp4 +3 -0
- example/segment_018.mp4 +3 -0
- scripts/scripts_test_video/hawor_slam.py +6 -1
app.py
CHANGED
@@ -223,7 +223,9 @@ with gr.Blocks(title="HaWoR: World-Space Hand Motion Reconstruction from Egocent
|
|
223 |
with gr.Row():
|
224 |
|
225 |
example_images = gr.Examples([
|
226 |
-
['./example/video_0.mp4']
|
|
|
|
|
227 |
],
|
228 |
inputs=input_video)
|
229 |
|
|
|
223 |
with gr.Row():
|
224 |
|
225 |
example_images = gr.Examples([
|
226 |
+
['./example/video_0.mp4'],
|
227 |
+
['./example/segment_017.mp4'],
|
228 |
+
['./example/segment_018.mp4']
|
229 |
],
|
230 |
inputs=input_video)
|
231 |
|
example/segment_017.mp4
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:c5ac8fe771aaa3770cdc85f16fb23529bab1fdd4947352f27a8fce145bf753ce
|
3 |
+
size 11142819
|
example/segment_018.mp4
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:77000ba3105c4086fec2bfd4ea7fc02aeffef223b5314456f8c8fbe88a7b708e
|
3 |
+
size 9416730
|
scripts/scripts_test_video/hawor_slam.py
CHANGED
@@ -1,3 +1,4 @@
|
|
|
|
1 |
import sys
|
2 |
import os
|
3 |
|
@@ -119,7 +120,11 @@ def hawor_slam(args, start_idx, end_idx):
|
|
119 |
|
120 |
# Estimate scene scale
|
121 |
msk = masks[t].numpy().astype(np.uint8)
|
122 |
-
scale = est_scale_hybrid(slam_depth, pred_depth, sigma=0.5, msk=msk, near_thresh=min_threshold, far_thresh=max_threshold)
|
|
|
|
|
|
|
|
|
123 |
scales_.append(scale)
|
124 |
|
125 |
median_s = np.median(scales_)
|
|
|
1 |
+
import math
|
2 |
import sys
|
3 |
import os
|
4 |
|
|
|
120 |
|
121 |
# Estimate scene scale
|
122 |
msk = masks[t].numpy().astype(np.uint8)
|
123 |
+
scale = est_scale_hybrid(slam_depth, pred_depth, sigma=0.5, msk=msk, near_thresh=min_threshold, far_thresh=max_threshold)
|
124 |
+
while math.isnan(scale):
|
125 |
+
min_threshold -= 0.1
|
126 |
+
max_threshold += 0.1
|
127 |
+
scale = est_scale_hybrid(slam_depth, pred_depth, sigma=0.5, msk=msk, near_thresh=min_threshold, far_thresh=max_threshold)
|
128 |
scales_.append(scale)
|
129 |
|
130 |
median_s = np.median(scales_)
|