From 6163a2ba44d5109e44c3ce831ee52442a42addd8 Mon Sep 17 00:00:00 2001 From: Braden Date: Thu, 4 Apr 2024 17:23:44 -0600 Subject: [PATCH] Updated sofast example docstrings to view well on sphinx --- example/camera_calibration/example_view_camera_distortion.py | 4 +--- .../example_calibrate_sofast_fixed_dot_locations.py | 1 + .../sofast_calibration/example_calibration_screen_shape.py | 3 +-- .../example_calibration_spatial_orientation.py | 3 +-- ...example_calculate_dot_locations_from_display_shape_file.py | 1 + example/sofast_fixed/example_find_blobs_in_image.py | 2 +- example/sofast_fixed/example_measurement_from_image.py | 3 ++- example/sofast_fixed/example_process_facet.py | 3 ++- example/sofast_fringe/example_process_facet_ensemble.py | 4 ++-- example/sofast_fringe/example_process_single_facet.py | 3 +-- example/sofast_fringe/example_process_undefined_shape.py | 3 +-- 11 files changed, 14 insertions(+), 16 deletions(-) diff --git a/example/camera_calibration/example_view_camera_distortion.py b/example/camera_calibration/example_view_camera_distortion.py index 5a0429b73..f1c096a3f 100644 --- a/example/camera_calibration/example_view_camera_distortion.py +++ b/example/camera_calibration/example_view_camera_distortion.py @@ -9,12 +9,10 @@ def example_show_camera_distortion(): - """Example SOFAST script + """Plots visualization of camera distortion given a saved Camera HDF file - Plots visualization of camera distortion given a saved Camera HDF file 1. Loads camera HDF file 2. Plots distortion maps - """ # Define input camera file file = join(opencsp_code_dir(), 'test/data/sofast_common/camera_sofast.h5') diff --git a/example/sofast_calibration/example_calibrate_sofast_fixed_dot_locations.py b/example/sofast_calibration/example_calibrate_sofast_fixed_dot_locations.py index 4914be220..ab74a32e1 100644 --- a/example/sofast_calibration/example_calibrate_sofast_fixed_dot_locations.py +++ b/example/sofast_calibration/example_calibrate_sofast_fixed_dot_locations.py @@ -17,6 +17,7 @@ def example_calibrate_sofast_fixed_dot_locations(): """Performs a printed fixed pattern dot location calibration using photogrammetry + 1. Load measured calibration data 2. Find origin dots in calibration images 3. Perform dot location calibration diff --git a/example/sofast_calibration/example_calibration_screen_shape.py b/example/sofast_calibration/example_calibration_screen_shape.py index e09ad7a23..62999552c 100644 --- a/example/sofast_calibration/example_calibration_screen_shape.py +++ b/example/sofast_calibration/example_calibration_screen_shape.py @@ -14,9 +14,8 @@ def example_screen_shape_calibration(): - """Example Sofast calibration script + """Calibrates the 3d shape of a screen using photogrammetry and projected Sofast fringes. - Calibrates the 3d shape of a screen: 1. Load measured calibration data 2. Perform screen shpae calibration 3. Save 3d shape data as DisplayShape object diff --git a/example/sofast_calibration/example_calibration_spatial_orientation.py b/example/sofast_calibration/example_calibration_spatial_orientation.py index e7401d7a8..071f5cdb7 100644 --- a/example/sofast_calibration/example_calibration_spatial_orientation.py +++ b/example/sofast_calibration/example_calibration_spatial_orientation.py @@ -14,9 +14,8 @@ def example_camera_position_calibration(): - """Example Sofast calibration script + """Calibrates the position of the Sofast camera. - Calibrates the position of the Sofast camera: 1. Load measured calibration data 2. Perform camera position calibration 3. Save orientation as SpatialOrientation object diff --git a/example/sofast_fixed/example_calculate_dot_locations_from_display_shape_file.py b/example/sofast_fixed/example_calculate_dot_locations_from_display_shape_file.py index ea2e78dba..30c51d47b 100644 --- a/example/sofast_fixed/example_calculate_dot_locations_from_display_shape_file.py +++ b/example/sofast_fixed/example_calculate_dot_locations_from_display_shape_file.py @@ -12,6 +12,7 @@ def example_calculate_dot_locations_from_display_shape(): """Creates a DotLocationsFixedPattern object from previously created DisplayShape and ImageProjection files. + 1. Load DisplayShape and image projection files 2. Define dot projection object 3. Define DotLocationsFixedPattern object diff --git a/example/sofast_fixed/example_find_blobs_in_image.py b/example/sofast_fixed/example_find_blobs_in_image.py index 5b87d459f..aede34e1f 100644 --- a/example/sofast_fixed/example_find_blobs_in_image.py +++ b/example/sofast_fixed/example_find_blobs_in_image.py @@ -13,7 +13,7 @@ def example_find_blobs_in_image(): - """Example script that finds blobs in image, annotates image, and saves""" + """Finds blobs in image, annotates image, and saves""" # General Setup dir_save = join(dirname(__file__), 'data/output/find_blobs_in_image') ft.create_directories_if_necessary(dir_save) diff --git a/example/sofast_fixed/example_measurement_from_image.py b/example/sofast_fixed/example_measurement_from_image.py index ca747b508..2814e3fb4 100644 --- a/example/sofast_fixed/example_measurement_from_image.py +++ b/example/sofast_fixed/example_measurement_from_image.py @@ -15,8 +15,9 @@ def example_create_measurement_file_from_image(): - """Example that creates a SofastFixed measurement file from an image. The image has + """Creates a SofastFixed measurement file from an image. The image has a point LED light near origin dot. + 1. Load image 2. Define measurement parameters 3. Find location of origin point diff --git a/example/sofast_fixed/example_process_facet.py b/example/sofast_fixed/example_process_facet.py index 3b120ee1e..e11a1259d 100644 --- a/example/sofast_fixed/example_process_facet.py +++ b/example/sofast_fixed/example_process_facet.py @@ -16,7 +16,8 @@ def example_process_facet(): - """Example Sofast script that processes a SofastFixed measurement of a single facet mirror + """Processes a SofastFixed measurement of a single facet mirror + 1. Load saved single facet SofastFixed collection data 2. Process data with SofastFixed 3. Log best-fit parabolic focal lengnths diff --git a/example/sofast_fringe/example_process_facet_ensemble.py b/example/sofast_fringe/example_process_facet_ensemble.py index e78c1831e..29911d0c7 100644 --- a/example/sofast_fringe/example_process_facet_ensemble.py +++ b/example/sofast_fringe/example_process_facet_ensemble.py @@ -20,9 +20,9 @@ def example_process_facet_ensemble(): - """Example Sofast script + """Performs processing of previously collected Sofast data + of multi facet mirror ensemble: - Performs processing of previously collected Sofast data of multi facet mirror ensemble: 1. Load saved facet ensemble Sofast collection data 2. Processes data with Sofast 3. Log best-fit parabolic focal lengths diff --git a/example/sofast_fringe/example_process_single_facet.py b/example/sofast_fringe/example_process_single_facet.py index efbbd63f4..3974ea6d6 100644 --- a/example/sofast_fringe/example_process_single_facet.py +++ b/example/sofast_fringe/example_process_single_facet.py @@ -18,9 +18,8 @@ def example_process_single_facet(): - """Example Sofast script + """Performs processing of previously collected Sofast data of single facet mirror. - Performs processing of previously collected Sofast data of single facet mirror: 1. Load saved single facet Sofast collection data 2. Processes data with Sofast 3. Log best-fit parabolic focal lengths diff --git a/example/sofast_fringe/example_process_undefined_shape.py b/example/sofast_fringe/example_process_undefined_shape.py index 4dae509c7..cae41551e 100644 --- a/example/sofast_fringe/example_process_undefined_shape.py +++ b/example/sofast_fringe/example_process_undefined_shape.py @@ -17,9 +17,8 @@ def example_process_undefined_shape_facet(): - """Example SOFAST script + """Performs processing of previously collected Sofast data of single facet mirror: - Performs processing of previously collected Sofast data of single facet mirror: 1. Load saved single facet Sofast collection data 2. Processes data with Sofast (without using facet file) 3. Log best-fit parabolic focal lengths