diff --git a/camera_visualizer/vizu.py b/camera_visualizer/vizu.py new file mode 100644 index 0000000..699959a --- /dev/null +++ b/camera_visualizer/vizu.py @@ -0,0 +1,19 @@ +"""Visualise the cameras using the ouptut from run_colmap.py""" +from camera_visualizer import visualize_cameras + +import open3d as o3d +import json +import os + +sphere_radius = 1. +camera_size = 0.1 + +base_dir = "./lupo_output_dir_4/" + +cam_dict_path = os.path.join(base_dir, "posed_images/kai_cameras_normalized.json") +with open(cam_dict_path) as fd: + cam_dict = json.load(fd) + +colored_camera_dicts = [([0,1,0], cam_dict)] + +visualize_cameras.visualize_cameras(colored_camera_dicts, sphere_radius, camera_size=camera_size)