Skip to content

[ARC] Improve SWASH output handling and scatter matrix visualization - #163

Closed
albaricondo wants to merge 3 commits into
developfrom
hyswash
Closed

albaricondo wants to merge 3 commits into
developfrom
hyswash

Conversation

@albaricondo

Copy link
Copy Markdown
Collaborator

No description provided.

Copilot AI lite review requested due to automatic review settings September 23, 2026 02:46

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Copilot review overview

🟡 Changes recommended

Unresolved issues affect template generation, SFINCS case creation, SWASH conversion, and scatter plotting.

Get a fresh assessment by requesting another Copilot review.

Review effort: Lite
Findings: 7 High severity · 1 Medium severity

Open (8)
What changed in this PR

This PR updates SWASH output handling, enhances scatter-matrix visualization, and refactors SFINCS case generation.

Changes:

  • Revises SWASH output conversion and dry-point masking.
  • Adds selectable variables and shared color-based visualization to scatter plots.
  • Refactors SFINCS template, forcing, and model setup.
  • Modifies template rendering during case builds.
File Summary
bluemath_tk/​wrappers/​swash/​templates/​INPUT Updates SWASH table output quantities.
bluemath_tk/​wrappers/​swash/​swash_wrapper.py Converts revised SWASH output and applies dry-point masking.
bluemath_tk/​wrappers/​sfincs/​sfincs_wrapper.py Changes SFINCS model, infiltration, forcing, and observation setup.
bluemath_tk/​wrappers/​_base_wrappers.py Modifies template rendering during case builds.
bluemath_tk/​core/​plotting/​scatter.py Adds selectable variables and color-based visualization.

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

Comment on lines +448 to +459
#for template_name in self.templates_name:
# try:
# self.render_file_from_template(
# template_name=template_name,
# context=case_context,
# output_filename=op.join(case_dir, template_name),
# )
# except UnicodeDecodeError as _ude:
# self.copy_files(
# src=op.join(self.templates_dir, template_name),
# dst=op.join(case_dir, template_name),
# )
Comment on lines +232 to +234
sf.config["tstop"] = '20100201 000000'
sf.config["tstart"] = '20100131 000000'
sf.config["tref"] = '20100131 000000'
# epsg=case_context["epsg"],
#)

sf = self.sf
Comment on lines +265 to +267
sf = self.sf

sf.config["tstop"] = tstop
sf.config["tstart"] = tstart
sf.config["dtout"] = 60
sf.config["storemeteo"] = 1
sf.set_root(root=case_dir, mode="r+")
# sf.write_forcing()

sf.write()
#sf.write()

# Set water level to NaN at dry points
dry_threshold = 0.05
dry_points = df_output["Depth"].round(12) <= dry_threshold
Comment thread bluemath_tk/wrappers/swash/templates/INPUT Outdated
Comment on lines 111 to +112
sf.setup_cn_infiltration(
dataset_inf.compute(), antecedent_moisture="{0}".format(ant_moisture)
dataset_inf.compute(), antecedent_moisture="cn"
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
@tausiaj tausiaj closed this Sep 24, 2026
@tausiaj
tausiaj deleted the hyswash branch September 24, 2026 15:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants