mirror of
https://github.com/wassname/simpeg.git
synced 2026-08-05 13:20:43 +08:00
Better fields object.
This commit is contained in:
@@ -146,14 +146,11 @@ class SurveyTDEM(Survey.BaseSurvey):
|
||||
for tx in self.txList:
|
||||
for rx in tx.rxList:
|
||||
Ptv = rx.projectFieldsDeriv(tx, self.mesh, self.prob.timeMesh, u, v, adjoint=True)
|
||||
Ptv = Ptv.reshape((-1, self.prob.timeMesh.nN), order='F')
|
||||
if rx.projField not in f: # first time we are projecting
|
||||
Ptv = Ptv.reshape((-1, 1, self.prob.timeMesh.nN), order='F')
|
||||
f[tx, rx.projField, :] = Ptv
|
||||
else:
|
||||
Ptv = Ptv.reshape((-1, self.prob.timeMesh.nN), order='F')
|
||||
addedPtv = f[tx, rx.projField, :] + Ptv
|
||||
addedPtv = addedPtv.reshape((-1, 1, self.prob.timeMesh.nN), order='F')
|
||||
f[tx, rx.projField, :] = addedPtv
|
||||
else: # there are already fields, so let's add to them!
|
||||
f[tx, rx.projField, :] += Ptv
|
||||
return f
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user