create_plan_preference#

nvmath.bindings.cutensor.create_plan_preference(
intptr_t handle,
int algo,
int jit_mode,
) intptr_t[source]#

Allocates the cutensorPlanPreference_t, enabling users to limit the applicable kernels for a given plan/operation.

Parameters:
  • handle (intptr_t) – Opaque handle holding cuTENSOR’s library context.

  • algo (Algo) – Allows users to select a specific algorithm. CUTENSOR_ALGO_DEFAULT lets the heuristic choose the algorithm. Any value >= 0 selects a specific GEMM-like algorithm and deactivates the heuristic. If a specified algorithm is not supported CUTENSOR_STATUS_NOT_SUPPORTED is returned. See cutensorAlgo_t for additional choices.

  • jit_mode (JitMode) – Determines if cuTENSOR is allowed to use JIT-compiled kernels (leading to a longer plan-creation phase); see cutensorJitMode_t.

Returns:

Pointer to the structure holding the cutensorPlanPreference_t allocated by this function. See cutensorPlanPreference_t.

Return type:

intptr_t

See also

cutensorCreatePlanPreference