mirror of
https://github.com/wassname/simpeg.git
synced 2026-07-24 13:20:06 +08:00
to get working..
This commit is contained in:
@@ -1,4 +1,5 @@
|
||||
import numpy as np
|
||||
from SimPEG.utils import sdiag
|
||||
|
||||
class Inversion(object):
|
||||
"""docstring for Inversion"""
|
||||
@@ -11,20 +12,18 @@ class Inversion(object):
|
||||
self.opt = opt
|
||||
|
||||
@property
|
||||
def W(self):
|
||||
def Wd(self):
|
||||
"""
|
||||
Standard deviation weighting matrix.
|
||||
"""
|
||||
return self._W
|
||||
@W.setter
|
||||
def W(self, value):
|
||||
self._W = value
|
||||
return sdiag(1/self.prob.std)
|
||||
|
||||
def run(self, m0):
|
||||
m = m0
|
||||
self._iter = 0
|
||||
while True:
|
||||
self._beta = self.getBeta()
|
||||
self.opt.minimize(self.evalFunction,m)
|
||||
m = self.opt.minimize(self.evalFunction,m)
|
||||
if self.stoppingCriteria(): break
|
||||
self._iter += 1
|
||||
|
||||
|
||||
Reference in New Issue
Block a user