Skip to content

Commit

Permalink
Added more context to warnings in PSF.
Browse files Browse the repository at this point in the history
  • Loading branch information
braden6521 committed Dec 13, 2024
1 parent 520ebcd commit 7ed0195
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions opencsp/app/sofast/lib/ProcessSofastFixed.py
Original file line number Diff line number Diff line change
Expand Up @@ -155,8 +155,9 @@ def _process_optic_common_geometry(
# Remove nans if any present
if np.any(nan_mask):
lt.warn(
f'{nan_mask.sum():d} / {nan_mask.size:d} points are NANs in calculated '
f'screen points for facet 0. These data points will be removed.'
'ProcessSofastFixed._process_optic_common_geometry(): '
f'{nan_mask.sum():d} / {nan_mask.size:d} screen points are undefined '
f'for facet {idx_facet:d}. These data points will be removed.'
)
# Remove nan data points from screen points
pts_image = pts_image[active_point_mask]
Expand Down Expand Up @@ -326,7 +327,7 @@ def process_multi_facet_optic(
if len(data_facet_def) != len(surfaces) != len(pts_known) != len(xys_known):
lt.error_and_raise(
ValueError,
'Length of data_facet_def does not equal length of data_surfaces'
'ProcessSofastFixed: Length of data_facet_def does not equal length of data_surfaces'
+ f'data_facet_def={len(data_facet_def)}, surface_data={len(surfaces)}, '
+ f'pts_known={len(pts_known)}, xys_known={len(xys_known)}',
)
Expand Down

0 comments on commit 7ed0195

Please sign in to comment.