Spaces:
Runtime error
Runtime error
jens
commited on
Commit
·
c09fa67
1
Parent(s):
0b87dc6
depth adjusted
Browse files- inference.py +2 -2
inference.py
CHANGED
|
@@ -36,10 +36,10 @@ class DepthPredictor:
|
|
| 36 |
output = prediction.cpu().numpy()
|
| 37 |
formatted = (output * 255 / np.max(output)).astype('uint8')
|
| 38 |
#img = Image.fromarray(formatted)
|
| 39 |
-
return
|
| 40 |
|
| 41 |
def generate_pcl(self, image):
|
| 42 |
-
depth =
|
| 43 |
# Step 2: Create an RGBD image from the RGB and depth image
|
| 44 |
depth_o3d = o3d.geometry.Image(depth)
|
| 45 |
image_o3d = o3d.geometry.Image(np.array(image))
|
|
|
|
| 36 |
output = prediction.cpu().numpy()
|
| 37 |
formatted = (output * 255 / np.max(output)).astype('uint8')
|
| 38 |
#img = Image.fromarray(formatted)
|
| 39 |
+
return output
|
| 40 |
|
| 41 |
def generate_pcl(self, image):
|
| 42 |
+
depth = self.predict(image)
|
| 43 |
# Step 2: Create an RGBD image from the RGB and depth image
|
| 44 |
depth_o3d = o3d.geometry.Image(depth)
|
| 45 |
image_o3d = o3d.geometry.Image(np.array(image))
|