Skip to content
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

[1pt] Fix inundation nation pathing errors #1026

Merged
merged 25 commits into from
Dec 8, 2023

Conversation

RobHanna-NOAA
Copy link
Contributor

@RobHanna-NOAA RobHanna-NOAA commented Nov 4, 2023

A couple of directly related issues were fixed in this PR.
The initial problem came from Issue #1025 which was about a pathing issue for the outputs directory. In testing that fix, it exposed a few other pathing and file cleanup issues which are now fixed. We also added more console output to help view variables and pathing.

Closes #1025

Changes

  • config/params_template.env: Updated for a newer mannings global file. Changed and tested by Ryan Spies.
  • tools
    • inundate_mosiac_wrapper.py: Took out a misleading and non-required print statement.
    • inundate_nation.py: As mentioned above.

Testing

  • Tested against a full BED set of FIM 4.4.5.0 successfully and with file cleanup disabled.
  • Tested against a smaller subset of a couple of HUCs with file cleanup corrected and enhanced output prints.

Issuer Checklist (For developer use)

You may update this checklist before and/or after creating the PR. If you're unsure about any of them, please ask, we're here to help! These items are what we are going to look for before merging your code.

  • Informative and human-readable title, using the format: [_pt] PR: <description>
  • Links are provided if this PR resolves an issue, or depends on another other PR
  • If submitting a PR to the dev branch (the default branch), you have a descriptive Feature Branch name using the format: dev-<description-of-change> (e.g. dev-revise-levee-masking)
  • Changes are limited to a single goal (no scope creep)
  • The feature branch you're submitting as a PR is up to date (merged) with the latest dev branch
  • pre-commit hooks were run locally
  • Any change in functionality is tested
  • n/a Passes all unit tests locally (inside interactive Docker container, at /foss_fim/, run: pytest unit_tests/)
  • n/a New functions are documented (with a description, list of inputs, and expected output)
  • Placeholder code is flagged / future todos are captured in comments
  • CHANGELOG updated with template version number, e.g. 4.x.x.x
  • Reviewers requested
  • Add yourself as an assignee in the PR as well as the FIM Technical Lead

Merge Checklist (For Technical Lead use only)

  • Update CHANGELOG with latest version number and merge date
  • Update the Citation.cff file to reflect the latest version number in the CHANGELOG
  • If applicable, update README with major alterations

@RobHanna-NOAA RobHanna-NOAA added bug Something isn't working FIM4 labels Nov 4, 2023
@RobHanna-NOAA RobHanna-NOAA linked an issue Nov 13, 2023 that may be closed by this pull request
@RobHanna-NOAA RobHanna-NOAA changed the title [1pt] WIP: fix inundation nation [1pt] Fix inundation nation pathing errors Nov 14, 2023
@RobHanna-NOAA RobHanna-NOAA marked this pull request as ready for review November 14, 2023 23:11
@RobHanna-NOAA
Copy link
Contributor Author

@RyanSpies-NOAA : Hi Ryan. I took this one to the goal line. See testing notes embedded. If you are comfortable with it, can you approve it? Your call if you want to do more testing on it but it likely is ok. Note: I did not test or understand how to test the change the newer mannings file.

@@ -47,7 +47,7 @@ export src_subdiv_toggle="True"
# text to append to output log and hydrotable file names (use for testing/debugging)
export vrough_suffix=""
# input file location with nwm feature_id and channel roughness and overbank roughness attributes
export vmann_input_file="$inputsDir/rating_curve/variable_roughness/mannings_global_06_12.csv"
export vmann_input_file="$inputsDir/rating_curve/variable_roughness/mannings_global_025_05.csv"
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't think we want this changed?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

oh sorry. Not sure why that change was made. Anyways. I fixed it and put it back. :)

RyanSpies-NOAA
RyanSpies-NOAA previously approved these changes Dec 5, 2023
Copy link
Collaborator

@RyanSpies-NOAA RyanSpies-NOAA left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Reviewed code changes and ran a successful test run with 10 hucs. Also reviewed the 3gb BED mosaic raster and confirmed inundation was generated for full domain.

@CarsonPruitt-NOAA CarsonPruitt-NOAA merged commit 5e794f5 into dev Dec 8, 2023
1 check passed
@CarsonPruitt-NOAA CarsonPruitt-NOAA deleted the dev-fix-inundate-nation branch December 8, 2023 20:40
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working FIM4
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[5pt] Inundation Nation error
3 participants