merging + text embedding bugfix

This commit is contained in:
terrancewang committed 2023-03-15 13:34:43 -07:00
1 parent 978bf1d12d
commit a449219f91
70 files changed
+2465 -735

No files matched your search

+7 -1
View File
@@ -2,6 +2,8 @@
Script for exporting NeRF into other formats.
"""
# pylint: disable=no-member
from __future__ import annotations
import json
@@ -94,7 +96,11 @@ class ExportPointCloud(Exporter):
CONSOLE.print(f"[bold green]:white_check_mark: Generated {pcd}")
CONSOLE.print("Saving Point Cloud...")
o3d.io.write_point_cloud(str(self.output_dir / "point_cloud.ply"), pcd)
tpcd = o3d.t.geometry.PointCloud.from_legacy(pcd)
# The legacy PLY writer converts colors to UInt8,
# let us do the same to save space.
tpcd.point.colors = (tpcd.point.colors * 255).to(o3d.core.Dtype.UInt8)
o3d.t.io.write_point_cloud(str(self.output_dir / "point_cloud.ply"), tpcd)
print("\033[A\033[A")
CONSOLE.print("[bold green]:white_check_mark: Saving Point Cloud")