Spaces:
Running
on
Zero
Running
on
Zero
wzhouxiff
commited on
Commit
•
8c00727
1
Parent(s):
cecdc9f
env
Browse files- .gitignore +2 -1
- objctrl_2_5d/objctrl_2_5d.py +0 -2
- objctrl_2_5d/utils/ui_utils.py +3 -3
- requirements.txt +13 -1
.gitignore
CHANGED
@@ -1,4 +1,5 @@
|
|
1 |
outputs/
|
2 |
ckpt/
|
3 |
checkpoints/*
|
4 |
-
__pycache__/
|
|
|
|
1 |
outputs/
|
2 |
ckpt/
|
3 |
checkpoints/*
|
4 |
+
__pycache__/
|
5 |
+
env.txt
|
objctrl_2_5d/objctrl_2_5d.py
CHANGED
@@ -115,8 +115,6 @@ def run(pipeline, device):
|
|
115 |
#### preparing mask
|
116 |
|
117 |
mask = Image.fromarray(mask)
|
118 |
-
mask.save(f'{cur_OUTPUT_PATH}/org_mask_big.png')
|
119 |
-
mask = Image.open(f'{cur_OUTPUT_PATH}/org_mask_big.png')
|
120 |
mask = mask.resize((W, H))
|
121 |
mask = np.array(mask).astype(np.float32)
|
122 |
mask = np.expand_dims(mask, axis=-1)
|
|
|
115 |
#### preparing mask
|
116 |
|
117 |
mask = Image.fromarray(mask)
|
|
|
|
|
118 |
mask = mask.resize((W, H))
|
119 |
mask = np.array(mask).astype(np.float32)
|
120 |
mask = np.expand_dims(mask, axis=-1)
|
objctrl_2_5d/utils/ui_utils.py
CHANGED
@@ -190,7 +190,7 @@ def traj2cam(traj, depth, rescale):
|
|
190 |
zc = []
|
191 |
for i in range(num_frames):
|
192 |
zc.append(r_depth[int(trajectory[i][1]), int(trajectory[i][0])])
|
193 |
-
print(f'zc: {zc}')
|
194 |
|
195 |
## norm zc
|
196 |
zc_norm = np.array(zc)
|
@@ -202,8 +202,8 @@ def traj2cam(traj, depth, rescale):
|
|
202 |
if zc_grad_std > zc_threshold:
|
203 |
zc = [zc[0]] * num_frames
|
204 |
|
205 |
-
print(f'zc_grad_std: {zc_grad_std}, zc_threshold: {zc_threshold}')
|
206 |
-
print(f'zc: {zc}')
|
207 |
|
208 |
traj_w2c = trajectory_to_camera_poses_v1(trajectory, intrinsics, num_frames, zc=zc) # numpy: [n_frame, 4, 4]
|
209 |
RTs = traj_w2c[:, :3]
|
|
|
190 |
zc = []
|
191 |
for i in range(num_frames):
|
192 |
zc.append(r_depth[int(trajectory[i][1]), int(trajectory[i][0])])
|
193 |
+
# print(f'zc: {zc}')
|
194 |
|
195 |
## norm zc
|
196 |
zc_norm = np.array(zc)
|
|
|
202 |
if zc_grad_std > zc_threshold:
|
203 |
zc = [zc[0]] * num_frames
|
204 |
|
205 |
+
# print(f'zc_grad_std: {zc_grad_std}, zc_threshold: {zc_threshold}')
|
206 |
+
# print(f'zc: {zc}')
|
207 |
|
208 |
traj_w2c = trajectory_to_camera_poses_v1(trajectory, intrinsics, num_frames, zc=zc) # numpy: [n_frame, 4, 4]
|
209 |
RTs = traj_w2c[:, :3]
|
requirements.txt
CHANGED
@@ -16,4 +16,16 @@ safetensors
|
|
16 |
triton
|
17 |
termcolor==2.4.0
|
18 |
gradio-image-prompter==0.1.0
|
19 |
-
hydra-core==1.3.2
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
16 |
triton
|
17 |
termcolor==2.4.0
|
18 |
gradio-image-prompter==0.1.0
|
19 |
+
hydra-core==1.3.2
|
20 |
+
scipy
|
21 |
+
plotly
|
22 |
+
huggingface_hub==0.10.1
|
23 |
+
iopath
|
24 |
+
timm==0.6.13
|
25 |
+
numpy==1.25.2
|
26 |
+
accelerate==0.34.2
|
27 |
+
pydantic==2.8.2
|
28 |
+
starlette==0.37.2
|
29 |
+
fastapi==0.111.1
|
30 |
+
fastapi-cli==0.0.4
|
31 |
+
av==13.0.0
|