pylops_distributed.signalprocessing.Convolve1D

class pylops_distributed.signalprocessing.Convolve1D(N, h, offset=0, dims=None, dir=0, compute=(False, False), chunks=(None, None), todask=(False, False), dtype='float64')[source]

1D convolution operator.

Apply one-dimensional convolution with a compact filter to model (and data) along a specific direction of a multi-dimensional array depending on the choice of dir.

Note that if a multi-dimensional array is provided the array can also be chuncked along the direction dir where convolution is performed. In this case, dask handles the communication of borders between neighboring blocks.

Parameters:
N : int

Number of samples in model.

h : numpy.ndarray

1d compact filter to be convolved to input signal

offset : int

Index of the center of the compact filter

dims : tuple

Number of samples for each dimension (None if only one dimension is available)

dir : int, optional

Direction along which convolution is applied

compute : tuple, optional

Compute the outcome of forward and adjoint or simply define the graph and return a dask.array.array

chunks : tuple, optional

Chunk size for model and data. If provided it will rechunk the model before applying the forward pass and the data before applying the adjoint pass

todask : tuple, optional

Apply dask.array.from_array to model and data before applying forward and adjoint respectively

dtype : str, optional

Type of elements in input array.

Raises:
ValueError

If offset is bigger than len(h) - 1

Notes

Refer to pylops.signalprocessing.Convolve1D for implementation details.

Attributes:
shape : tuple

Operator shape

explicit : bool

Operator contains a matrix that can be solved explicitly (True) or not (False)

Methods

__init__(N, h[, offset, dims, dir, compute, …]) Initialize this LinearOperator.
adjoint() Hermitian adjoint.
apply_columns(cols) Apply subset of columns of operator
cond([uselobpcg]) Condition number of linear operator.
conj() Complex conjugate operator
div(y[, niter]) Solve the linear problem \(\mathbf{y}=\mathbf{A}\mathbf{x}\).
dot(x) Matrix-vector multiplication.
eigs([neigs, symmetric, niter, uselobpcg]) Most significant eigenvalues of linear operator.
matmat(X) Matrix-matrix multiplication.
matvec(x) Matrix-vector multiplication.
rmatmat(X) Adjoint matrix-matrix multiplication.
rmatvec(x) Adjoint Matrix-vector multiplication.
todense() Return dense matrix.
tosparse() Return sparse matrix.
transpose() Transpose this linear operator.

Examples using pylops_distributed.signalprocessing.Convolve1D