Memory-aware Array: Array Subclass in GPUData class
In this lesson, we will learn how to subclass ndarray to use it in the GPUData class.
As explained in the Subclassing ndarray
documentation, subclassing ndarray is complicated by the fact that new
instances of ndarray classes can come about in three different ways:
- Explicit constructor call
- View casting
- New from template
However, our case is simpler because we’re only interested in the view casting. We thus only need to define the ...