From fa91f2e6bc65f20be3c8533398f7e6505a2dc2a8 Mon Sep 17 00:00:00 2001 From: bell-one Date: Tue, 19 Mar 2024 06:05:19 +0900 Subject: [PATCH] Bug fix in RGBD based reconstruction system example (#6660) * Update make_fragments.py: update 'write_point_cloud' variables * Update color_map_optimization_for_reconstruction_system.py: link 'initialize_config' function in color_map_optimization --- .../color_map_optimization_for_reconstruction_system.py | 1 + examples/python/reconstruction_system/make_fragments.py | 7 +++++-- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/examples/python/reconstruction_system/color_map_optimization_for_reconstruction_system.py b/examples/python/reconstruction_system/color_map_optimization_for_reconstruction_system.py index 173f6f52c22..088ec51818a 100644 --- a/examples/python/reconstruction_system/color_map_optimization_for_reconstruction_system.py +++ b/examples/python/reconstruction_system/color_map_optimization_for_reconstruction_system.py @@ -14,6 +14,7 @@ pyexample_path = os.path.dirname(os.path.dirname(os.path.abspath(__file__))) sys.path.append(pyexample_path) from open3d_example import * +from initialize_config import initialize_config def parse_keys(filename): diff --git a/examples/python/reconstruction_system/make_fragments.py b/examples/python/reconstruction_system/make_fragments.py index dc4e59d0780..17d875aa86c 100644 --- a/examples/python/reconstruction_system/make_fragments.py +++ b/examples/python/reconstruction_system/make_fragments.py @@ -139,8 +139,11 @@ def make_pointcloud_for_fragment(path_dataset, color_files, depth_files, pcd.colors = mesh.vertex_colors pcd_name = join(path_dataset, config["template_fragment_pointcloud"] % fragment_id) - o3d.io.write_point_cloud(pcd_name, pcd, False, True) - + o3d.io.write_point_cloud(pcd_name, + pcd, + format='auto', + write_ascii=False, + compressed=True) def process_single_fragment(fragment_id, color_files, depth_files, n_files, n_fragments, config):