Lazylinop philosophy – what is a LazyLinearOp object?
Starting from a numpy array, a scipy matrix, a Faust object, or potentially
many other compatible linear operators with efficient implementatons, a
LazyLinearOp object follows the lazy evaluation paradigm. In short, one can aggregate
LazyLinearOp objects into higher-level ones using many classical
operations (addition, concatenation, adjoint, real part, etc.), without
actually building arrays. The actual effect of these operations is delayed
until the resulting linear operator is actually applied to a vector (or to a
collection of vectors, seen as a matrix).
The main interest of this paradigm is to enable the construction of processing pipelines that exploit as building blocks efficient implementations of “low-level” linear operators.
LazyLinearOperators are complementary to other “lazy” objects such as LazyTensors in Kheops, or the ones of lazyarray, WeldNumpy an pylops libraries, which, to the best of our knowledge, primarily provide compact descriptions of arrays which entries can be evaluated efficiently on the fly.
lazylinop is currently in a beta stage of development. It is thus intensively evolving and we invite you to consult this documentation regularly.
pylops has a particular position among those libraries. It is
in fact a dependency of the lazylinop package because it is used as an alternative
backend for some lazylinop functions (as for instance
It’s worth noting that the way pylops exhibits
LinearOperator-s in its API is different.
Indeed, pylops provides Python classes (like Kronecker) while lazylinop is
more likely to propose Python functions in the scipy style (like scipy kron).