linop.Matrix#
- class bartorch.linop.Matrix#
Bases:
LinearOperatorMultiplication by a matrix along one axis, BART’s
linop_matrix.The matrix is an array like any other: it contracts the axis the domain and the codomain differ along and broadcasts over the axes it has only one of, so one operator can carry a different matrix per slice.
- Parameters:
matrix (tensor) – The matrix, with the domain’s size along the axis it contracts and the codomain’s along the axis it produces.
oshape (tuple of int) – Codomain and domain, C order, with the same number of axes.
ishape (tuple of int) – Codomain and domain, C order, with the same number of axes.
Examples
A basis of
kfunctions overtsamples, applied along the first axis of(t, y, x):>>> B = Matrix(basis, (k, y, x), (t, y, x))
Also has the methods and properties of LinearOperator.