Skip to content

Commit a89c150

Browse files
committed
Default lower_bound active for mag scaler
1 parent be9fae3 commit a89c150

3 files changed

Lines changed: 3 additions & 2 deletions

File tree

simpeg_drivers-assets/uijson/magnetic_scalar_inversion.ui.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -410,7 +410,7 @@
410410
"property": "",
411411
"optional": true,
412412
"value": 0.0,
413-
"enabled": false
413+
"enabled": true
414414
},
415415
"upper_bound": {
416416
"association": [

simpeg_drivers/potential_fields/magnetic_scalar/params.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -118,3 +118,4 @@ class MagneticInversionOptions(BaseInversionOptions):
118118
inducing_field_strength: float | FloatData
119119
inducing_field_inclination: float | FloatData
120120
inducing_field_declination: float | FloatData
121+
lower_bound: float | FloatData | None = 0.0

tests/run_tests/driver_mag_test.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -109,14 +109,14 @@ def test_susceptibility_run(
109109
z_norm=1.0,
110110
initial_beta_ratio=1e1,
111111
gradient_type="components",
112-
lower_bound=0.0,
113112
tmi_channel=tmi,
114113
tmi_uncertainty=1.0,
115114
max_global_iterations=max_iterations,
116115
store_sensitivities="ram",
117116
)
118117
params.write_ui_json(path=tmp_path / "Inv_run.ui.json")
119118

119+
assert params.lower_bound == 0.0
120120
driver = MagneticInversionDriver.start(str(tmp_path / "Inv_run.ui.json"))
121121

122122
with Workspace(driver.params.geoh5.h5file) as run_ws:

0 commit comments

Comments
 (0)