scipy 1.8.0 Pypi GitHub Homepage
Other Docs
NotesBackRef
aslinearoperator(A)

'A' may be any of the following types:

  • ndarray

  • matrix

  • sparse matrix (e.g. csr_matrix, lil_matrix, etc.)

  • LinearOperator

  • An object with .shape and .matvec attributes

See the LinearOperator documentation for additional information.

Notes

If 'A' has no .dtype attribute, the data type is determined by calling LinearOperator.matvec() - set the .dtype attribute to prevent this call upon the linear operator creation.

Return A as a LinearOperator.

Examples

>>> from scipy.sparse.linalg import aslinearoperator
... M = np.array([[1,2,3],[4,5,6]], dtype=np.int32)
... aslinearoperator(M) <2x3 MatrixLinearOperator with dtype=int32>
See :

Back References

The following pages refer to to this document either explicitly or contain code examples using this.

scipy.sparse.linalg._interface.LinearOperator scipy.sparse.linalg._interface.aslinearoperator

Local connectivity graph

Hover to see nodes names; edges to Self not shown, Caped at 50 nodes.

Using a canvas is more power efficient and can get hundred of nodes ; but does not allow hyperlinks; , arrows or text (beyond on hover)

SVG is more flexible but power hungry; and does not scale well to 50 + nodes.

All aboves nodes referred to, (or are referred from) current nodes; Edges from Self to other have been omitted (or all nodes would be connected to the central node "self" which is not useful). Nodes are colored by the library they belong to, and scaled with the number of references pointing them


GitHub : /scipy/sparse/linalg/_interface.py#773
type: <class 'function'>
Commit: