From 11f4ddc033c972c150e028ee47dde411ff46ead8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Thomas=20G=C3=BCnther?= Date: Tue, 26 Mar 2024 07:57:36 +0100 Subject: [PATCH] ADD: shortcut inv.setInterfaceConstraint (#658) --- pygimli/frameworks/inversion.py | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/pygimli/frameworks/inversion.py b/pygimli/frameworks/inversion.py index c926de24d..507d16395 100644 --- a/pygimli/frameworks/inversion.py +++ b/pygimli/frameworks/inversion.py @@ -508,6 +508,19 @@ def setInterRegionConstraint(self, region1, region2, strength): self.fop.regionManager().setInterRegionConstraint( region1, region2, strength) + def setInterfaceConstraint(self, marker, strength): + """Set regularization strength on specific interface. + + Parameters + ---------- + marker : int + Boundary marker of the interface + strength : float + weighting factor for roughness across boundary + """ + self.fop.regionManager().setInterfaceConstraint( + marker, strength) + def setConstraintWeights(self, cWeight): """Set weighting factors for the invidual rows of the C matrix.""" self.inv.setCWeight(cWeight)