finesse.cymath.cmatrix.SubCCSView2DArray
¶
Overview
- class finesse.cymath.cmatrix.SubCCSView2DArray¶
Bases:
object
This is a class for storing sub-matrix views. It offers a 2D PyObject** array which can be iterated over in C for fast access matrix data without having to do reference inc/dec in fast loops.
It can be accessed from Python for setting views, however it doesn’t support slicing or wraparounds.
Examples
Cython access to views should be cast to a SubCCSView before using it:
>>>> (<SubCCSView>arr.views[i][j]).fill()
This should result in no python calls when checking the Cython analysis information.
If you store this SubCCSView into a variable then a reference count will happen.
Properties
Number of dimensions of this collection of SubCCSViews |