Skip to content

GEOPY-2898: Investigate edge cells recovered with DC2D inversions#423

Open
domfournier wants to merge 5 commits into
release/GA_4.8from
GEOPY-2898
Open

GEOPY-2898: Investigate edge cells recovered with DC2D inversions#423
domfournier wants to merge 5 commits into
release/GA_4.8from
GEOPY-2898

Conversation

@domfournier
Copy link
Copy Markdown
Collaborator

@domfournier domfournier commented Jun 4, 2026

GEOPY-2898 - Investigate edge cells recovered with DC2D inversions

Copilot AI review requested due to automatic review settings June 4, 2026 19:48
@github-actions github-actions Bot changed the title GEOPY-2898 GEOPY-2898: Investigate edge cells recovered with DC2D inversions Jun 4, 2026
Copy link
Copy Markdown
Contributor

Copilot AI left a 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 investigates/mitigates edge-cell artifacts in DC2D inversions by constraining boundary cells during optimization, then updates run-tests and dependency locks to reflect the new inversion behavior.

Changes:

  • Override 2D driver optimization to keep boundary (and bottom-row) cells fixed at the starting model via bounds + active-set gradient scaling.
  • Update DC2D run-tests to validate boundary-cell behavior and refresh expected inversion metrics.
  • Update joint-surveys option validation to derive physical property from each group’s driver class; refresh dependency/lock files (including a git-based mira-simpeg pin).

Reviewed changes

Copilot reviewed 17 out of 17 changed files in this pull request and generated 10 comments.

Show a summary per file
File Description
tests/run_tests/driver_dc_2d_test.py Updates target metrics and adds an assertion that boundary cells remain at the starting value.
tests/run_tests/driver_dc_2d_rotated_gradients_test.py Updates expected target metrics for rotated-gradient DC2D run.
simpeg_drivers/joint/joint_surveys/options.py Determines per-group physical property via the group’s run_command driver class rather than group options.
simpeg_drivers/electricals/induced_polarization/two_dimensions/inversion.py Reorders base classes so Base2DDriver behavior (e.g., optimization override) takes precedence in MRO.
simpeg_drivers/electricals/direct_current/two_dimensions/inversion.py Same base-class reorder for DC2D inversion driver.
simpeg_drivers/electricals/base_2d.py Introduces 2D-specific optimization override and logic to identify and freeze edge/bottom cells.
pyproject.toml Switches mira-simpeg dependency from version range to a git ref (GEOPY-2898 branch).
py-3.13.conda-lock.yml Regenerates lock to reflect dependency changes and updated resolution.
py-3.12.conda-lock.yml Regenerates lock to reflect dependency changes and updated resolution.
environments/py-3.13-win-64.conda.lock.yml Updates rendered env lock (incl. pip section now pointing at git mira-simpeg).
environments/py-3.13-win-64-dev.conda.lock.yml Same for dev env.
environments/py-3.13-linux-64.conda.lock.yml Same for linux env.
environments/py-3.13-linux-64-dev.conda.lock.yml Same for linux dev env.
environments/py-3.12-win-64.conda.lock.yml Same for py3.12 win env.
environments/py-3.12-win-64-dev.conda.lock.yml Same for py3.12 win dev env.
environments/py-3.12-linux-64.conda.lock.yml Same for py3.12 linux env.
environments/py-3.12-linux-64-dev.conda.lock.yml Same for py3.12 linux dev env.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread pyproject.toml
Comment thread simpeg_drivers/electricals/base_2d.py Outdated
Comment thread environments/py-3.13-linux-64.conda.lock.yml
Comment thread environments/py-3.13-linux-64-dev.conda.lock.yml
Comment thread environments/py-3.13-win-64.conda.lock.yml
Comment thread environments/py-3.13-win-64-dev.conda.lock.yml
Comment thread environments/py-3.12-linux-64.conda.lock.yml
Comment thread environments/py-3.12-linux-64-dev.conda.lock.yml
Comment thread environments/py-3.12-win-64.conda.lock.yml
Comment thread environments/py-3.12-win-64-dev.conda.lock.yml
@codecov
Copy link
Copy Markdown

codecov Bot commented Jun 4, 2026

Codecov Report

❌ Patch coverage is 97.22222% with 1 line in your changes missing coverage. Please review.
✅ Project coverage is 90.57%. Comparing base (a42dcd6) to head (57d55e0).

Files with missing lines Patch % Lines
simpeg_drivers/electricals/base_2d.py 96.42% 0 Missing and 1 partial ⚠️
Additional details and impacted files
@@                Coverage Diff                 @@
##           release/GA_4.8     #423      +/-   ##
==================================================
+ Coverage           90.55%   90.57%   +0.02%     
==================================================
  Files                 110      110              
  Lines                6508     6539      +31     
  Branches              817      822       +5     
==================================================
+ Hits                 5893     5923      +30     
  Misses                410      410              
- Partials              205      206       +1     
Files with missing lines Coverage Δ
...tricals/direct_current/two_dimensions/inversion.py 72.72% <100.00%> (ø)
...s/induced_polarization/two_dimensions/inversion.py 72.72% <100.00%> (ø)
simpeg_drivers/joint/joint_surveys/options.py 93.54% <100.00%> (+0.95%) ⬆️
simpeg_drivers/electricals/base_2d.py 98.09% <96.42%> (-0.63%) ⬇️
🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

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.

2 participants