Package org.nd4j.linalg.api.ndarray
Class BaseShapeInfoProvider
- java.lang.Object
-
- org.nd4j.linalg.api.ndarray.BaseShapeInfoProvider
-
- All Implemented Interfaces:
ShapeInfoProvider
public abstract class BaseShapeInfoProvider extends Object implements ShapeInfoProvider
-
-
Field Summary
Fields Modifier and Type Field Description protected AtomicLongbytes
-
Constructor Summary
Constructors Constructor Description BaseShapeInfoProvider()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Pair<DataBuffer,long[]>createShapeInformation(long[] shape, char order, DataType dataType)This method creates shapeInformation buffer, based on shape & order being passed inPair<DataBuffer,long[]>createShapeInformation(long[] shape, long[] stride, long elementWiseStride, char order, long extras)Pair<DataBuffer,long[]>createShapeInformation(long[] shape, long[] stride, long elementWiseStride, char order, DataType dataType, boolean empty)This method creates long shapeInformation buffer, based on detailed shape info being passed inPair<DataBuffer,long[]>createShapeInformation(long[] shape, DataType dataType)This method creates shapeInformation buffer, based on shape being passed inlonggetCachedBytes()This method returns memory used for cache, in bytes-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.nd4j.linalg.api.ndarray.ShapeInfoProvider
purgeCache
-
-
-
-
Field Detail
-
bytes
protected AtomicLong bytes
-
-
Method Detail
-
createShapeInformation
public Pair<DataBuffer,long[]> createShapeInformation(long[] shape, DataType dataType)
This method creates shapeInformation buffer, based on shape being passed in- Specified by:
createShapeInformationin interfaceShapeInfoProvider- Parameters:
shape-- Returns:
-
createShapeInformation
public Pair<DataBuffer,long[]> createShapeInformation(long[] shape, char order, DataType dataType)
This method creates shapeInformation buffer, based on shape & order being passed in- Specified by:
createShapeInformationin interfaceShapeInfoProvider- Parameters:
shape-order-- Returns:
-
createShapeInformation
public Pair<DataBuffer,long[]> createShapeInformation(long[] shape, long[] stride, long elementWiseStride, char order, DataType dataType, boolean empty)
Description copied from interface:ShapeInfoProviderThis method creates long shapeInformation buffer, based on detailed shape info being passed in- Specified by:
createShapeInformationin interfaceShapeInfoProvider- Returns:
-
createShapeInformation
public Pair<DataBuffer,long[]> createShapeInformation(long[] shape, long[] stride, long elementWiseStride, char order, long extras)
- Specified by:
createShapeInformationin interfaceShapeInfoProvider
-
getCachedBytes
public long getCachedBytes()
Description copied from interface:ShapeInfoProviderThis method returns memory used for cache, in bytes- Specified by:
getCachedBytesin interfaceShapeInfoProvider- Returns:
-
-