freealise commited on
Commit
4065c3c
1 Parent(s): 03af147

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +7 -0
app.py CHANGED
@@ -144,6 +144,13 @@ def make_video(video_path, outdir='./vis_video_depth', encoder='vits'):
144
  mask = cv2.inRange(depth_color, white_lo, white_hi)
145
  # change image to black where we found white
146
  depth_color[mask>0] = (0,0,0)
 
 
 
 
 
 
 
147
 
148
  # split_region = np.ones((frame_height, margin_width, 3), dtype=np.uint8) * 255
149
  # combined_frame = cv2.hconcat([raw_frame, split_region, depth_color])
 
144
  mask = cv2.inRange(depth_color, white_lo, white_hi)
145
  # change image to black where we found white
146
  depth_color[mask>0] = (0,0,0)
147
+
148
+ for i in range(0, 256):
149
+ blur_lo = np.array([i,i,i])
150
+ blur_hi = np.array([i+16,i+16,i+16])
151
+ blur_mask = cv2.inRange(depth_color, blur_lo, blur_hi)
152
+ raw_frame[mask>0] = cv2.blur(raw_frame,((255-i)/16,(255-i)/16))
153
+ i = i + 16
154
 
155
  # split_region = np.ones((frame_height, margin_width, 3), dtype=np.uint8) * 255
156
  # combined_frame = cv2.hconcat([raw_frame, split_region, depth_color])