Skip to content

Commit 87cfa93

Browse files
committed
Fix driver for 1d inversions
1 parent 94e3673 commit 87cfa93

1 file changed

Lines changed: 8 additions & 1 deletion

File tree

simpeg_drivers/driver.py

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -466,7 +466,14 @@ def get_regularization(self):
466466
neighbors = cell_neighbors(reg_func.regularization_mesh.mesh)
467467

468468
# Adjustment for 2D versus 3D problems
469-
components = "sxz" if "2d" in self.params.inversion_type else "sxyz"
469+
components = (
470+
"sxz"
471+
if (
472+
"2d" in self.params.inversion_type
473+
or "1d" in self.params.inversion_type
474+
)
475+
else "sxyz"
476+
)
470477
weight_names = ["alpha_s"] + [f"length_scale_{k}" for k in components[1:]]
471478
functions = []
472479
for comp, weight_name, fun in zip(

0 commit comments

Comments
 (0)