# sigpy.linop.Linop¶

class sigpy.linop.Linop(oshape, ishape, repr_str=None)[source]

Abstraction for linear operator.

Linop can be called on a NumPy or CuPy array to perform a linear operation. The output can be on a different device.

Given a Linop A, and an appropriately shaped input x, the following are both valid operations to compute x -> A(x):

>>> y = A * x
>>> y = A(x)


Its adjoint linear operator can be obtained using the .H attribute. Linops can be scaled, added, subtracted, stacked and composed. Here are some example of valid operations on Linop A, Linop B, and a scalar a:

>>> A.H
>>> a * A + B
>>> a * A * B

Parameters: oshape – Output shape. ishape – Input shape. repr_str (string or None) – default: class name.
oshape

output shape.

ishape

input shape.

H

N

normal linear operator.

__init__(oshape, ishape, repr_str=None)[source]

Initialize self. See help(type(self)) for accurate signature.

Methods

 __init__(oshape, ishape[, repr_str]) Initialize self. apply(input) Apply linear operation on input.

Attributes

 H Return adjoint linear operator. N Return normal linear operator.