shared
 All Classes Functions Variables Typedefs Enumerations Enumerator Friends
Public Types | Static Public Member Functions | Static Public Attributes | List of all members
DimensionOps Class Reference

A class for dimension-based operations. More...

#include <DimensionOps.hpp>

Public Types

typedef void rrOp_t (jdouble *, const jint *, jint, jint, jint)
 Defines a real reduce operation.
 

Static Public Member Functions

static void rdOp (JNIEnv *env, jobject thisObj, jint type, jdoubleArray srcV, jintArray srcD, jintArray srcS, jdoubleArray dstV, jintArray opDims)
 Performs a real dimension operation. More...
 
static void riOp (JNIEnv *env, jobject thisObj, jint type, jdoubleArray srcV, jintArray srcD, jintArray srcS, jintArray dstV, jint dim)
 Performs a real index operation. More...
 
static void rrOp (JNIEnv *env, jobject thisObj, jint type, jdoubleArray srcV, jintArray srcD, jintArray srcS, jdoubleArray dstV, jintArray dstD, jintArray dstS, jintArray opDims)
 Performs a real reduce operation. More...
 
static void assignBaseIndices (jint *srcIndices, const jint *srcDArr, jint *srcDArrModified, const jint *srcSArr, jint *srcSArrModified, jint nDims, jint dim)
 Assigns base indices when excluding a dimension. More...
 
static void riMax (jdouble *, const jint *, jint *, jint, jint, jint)
 Real index maximum.
 
static void riMin (jdouble *, const jint *, jint *, jint, jint, jint)
 Real index minimum.
 
static void riZero (jdouble *, const jint *, jint *, jint, jint, jint)
 Real index find zeroes.
 
static void riGZero (jdouble *, const jint *, jint *, jint, jint, jint)
 Real index find greater-than-zeroes.
 
static void riLZero (jdouble *, const jint *, jint *, jint, jint, jint)
 Real index find less-than-zeroes.
 
static void riSort (jdouble *, const jint *, jint *, jint, jint, jint)
 Real index sort.
 
static void rdSum (jdouble *, const jint *, const jint *, jdouble *, const jint *, jint, jint, jint)
 Real dimension sum.
 
static void rdProd (jdouble *, const jint *, const jint *, jdouble *, const jint *, jint, jint, jint)
 Real dimension product.
 

Static Public Attributes

static rrOp_t rrSum
 Real reduce sum.
 
static rrOp_t rrProd
 Real reduce product.
 
static rrOp_t rrMax
 Real reduce maximum.
 
static rrOp_t rrMin
 Real reduce minimum.
 
static rrOp_t rrVar
 Real reduce variance.
 

Detailed Description

A class for dimension-based operations.

Member Function Documentation

void DimensionOps::assignBaseIndices ( jint *  srcIndices,
const jint *  srcDArr,
jint *  srcDArrModified,
const jint *  srcSArr,
jint *  srcSArrModified,
jint  nDims,
jint  dim 
)
static

Assigns base indices when excluding a dimension.

Parameters
srcIndicesthe source indices.
srcDArrthe dimensions.
srcDArrModifiedthe modified dimensions.
srcSArrthe strides.
srcSArrModifiedthe modified strides.
nDimsthe number of dimensions.
dimthe dimension to exclude.
void DimensionOps::rdOp ( JNIEnv *  env,
jobject  thisObj,
jint  type,
jdoubleArray  srcV,
jintArray  srcD,
jintArray  srcS,
jdoubleArray  dstV,
jintArray  opDims 
)
static

Performs a real dimension operation.

Parameters
envthe JNI environment.
thisObjthis object.
typethe operation type.
srcVthe source values.
srcDthe source dimensions.
srcSthe source strides.
dstVthe destination values.
opDimsthe dimensions of interest.
void DimensionOps::riOp ( JNIEnv *  env,
jobject  thisObj,
jint  type,
jdoubleArray  srcV,
jintArray  srcD,
jintArray  srcS,
jintArray  dstV,
jint  dim 
)
static

Performs a real index operation.

Parameters
envthe JNI environment.
thisObjthis object.
typethe operation type.
srcVthe source values.
srcDthe source dimensions.
srcSthe source strides.
dstVthe destination values.
dimthe dimension of interest.
void DimensionOps::rrOp ( JNIEnv *  env,
jobject  thisObj,
jint  type,
jdoubleArray  srcV,
jintArray  srcD,
jintArray  srcS,
jdoubleArray  dstV,
jintArray  dstD,
jintArray  dstS,
jintArray  opDims 
)
static

Performs a real reduce operation.

Parameters
envthe JNI environment.
thisObjthis object.
typethe operation type.
srcVthe source values.
srcDthe source dimensions.
srcSthe source strides.
dstVthe destination values.
dstDthe destination dimensions.
dstSthe destination strides.
opDimsthe dimensions of interest.