Skip to content

Commit 501dd04

Browse files
authored
Merge pull request #5 from mrava87/master
Changes required by 3D implementation of Marchenko application
2 parents 47632c0 + 8e4f720 commit 501dd04

File tree

4 files changed

+7
-6
lines changed

4 files changed

+7
-6
lines changed

pylops_distributed/optimization/cg.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -101,8 +101,7 @@ def cgls(A, y, x=None, niter=10, damp=0., tol=1e-4,
101101
tol : :obj:`float`, optional
102102
Tolerance on residual norm
103103
compute : :obj:`tuple`, optional
104-
Dask client. If provided when ``compute=None`` each iteration
105-
is persisted. This is the preferred method.
104+
Compute intermediate results at the end of every iteration
106105
client : :obj:`dask.distributed.client.Client`, optional
107106
Dask client. If provided when ``compute=None`` each iteration
108107
is persisted. This is the preferred method to avoid repeating

pylops_distributed/signalprocessing/Fredholm1.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,7 @@ def __init__(self, G, nz=1, saveGt=True, compute=(False, False),
6464
self.shape = (self.nsl * self.nx * self.nz,
6565
self.nsl * self.ny * self.nz)
6666
if saveGt:
67-
self.GT = G.transpose((0, 2, 1)).conj().persist()
67+
self.GT = (G.transpose((0, 2, 1)).conj()).persist()
6868
else:
6969
# choose what to transpose if Gt is not saved
7070
self.transposeG = True if self.G.size < self.shape[0] else False

pylops_distributed/waveeqprocessing/marchenko.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -371,7 +371,7 @@ def apply_multiplepoints(self, trav, dist=None, G0=None, nfft=None,
371371

372372
fd_plus = np.concatenate((np.flip(G0, axis=-1).transpose(2, 0, 1),
373373
np.zeros((self.nt - 1, self.nr, nvs))))
374-
fd_plus = da.from_array(fd_plus)
374+
fd_plus = da.from_array(fd_plus).rechunk(fd_plus.shape)
375375

376376
# Run standard redatuming as benchmark
377377
if rtm:

pylops_distributed/waveeqprocessing/mdd.py

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -62,10 +62,12 @@ def MDC(G, nt, nv, dt=1., dr=1., twosided=True,
6262
_FFT=FFT, _Fredholm1=Fredholm1,
6363
args_Fredholm1={'chunks': ((G.chunks[0], G.shape[2], nv),
6464
(G.chunks[0], G.shape[1], nv))},
65-
args_FFT={'chunks': (None, (nt, G.shape[2], nv)),
65+
args_FFT={'chunks': ((nt, G.shape[2], nv),
66+
(nt, G.shape[2], nv)),
6667
'todask':(todask[0], False),
6768
'compute': (False, compute[1])},
68-
args_FFT1={'chunks': (None, (nt, G.shape[1], nv)),
69+
args_FFT1={'chunks': ((nt, G.shape[1], nv),
70+
(nt, G.shape[1], nv)),
6971
'todask': (todask[1], False),
7072
'compute':(compute[0], False)})
7173

0 commit comments

Comments
 (0)