-
Notifications
You must be signed in to change notification settings - Fork 509
FAST.Farm: skip writing invalid VTK slices #2952
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
FAST.Farm: skip writing invalid VTK slices #2952
Conversation
Old behavior: fatal error if outside grid New behavior: skip that slice, keep number of slices the same as input file request How: new array of logicals for `valid` slice. Cycle on invalid slices
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR modifies FAST.Farm's VTK slice writing functionality to gracefully handle invalid slice requests instead of causing fatal errors. When terrain is present, it becomes less obvious during setup whether a requested slice location is valid within the grid boundaries.
Key changes:
- Adds validity tracking arrays for each slice type (XY, YZ, XZ planes)
- Changes fatal errors to warnings when slices fall outside the grid
- Implements slice skipping logic during output generation
Reviewed Changes
Copilot reviewed 3 out of 3 changed files in this pull request and generated 1 comment.
| File | Description |
|---|---|
| AWAE_Types.f90 | Adds three new boolean arrays to track slice validity and implements corresponding memory management |
| AWAE_Registry.txt | Registers the new validity tracking arrays in the parameter type definitions |
| AWAE.f90 | Implements validation logic during initialization and skip logic during output generation |
jjonkman
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I approve of this change after you fix the comment Copilot noted is in error (Change XZ to YZ).
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
jjonkman
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for fixing this typo!
Ready to merge
Feature or improvement description
Old behavior: fatal error if outside grid
New behavior: skip that slice, keep number of slices the same as input file request
How: new array of logicals for
validslice. Cycle on invalid slicesRelated issue, if one exists
#2951
Impacted areas of the software
FAST.Farm vtk slice writing only
Additional supporting information
With terrain, it gets a little less obvious if a requested slice is actually valid during preliminary setup. @rthedin requested this feature.
Test results, if applicable
No test results change