Function nvcvTensorLayoutMakeSubRange

Function Documentation

NVCVStatus nvcvTensorLayoutMakeSubRange(NVCVTensorLayout in, int32_t beg, int32_t end, NVCVTensorLayout *layout)

Makes a tensor layout from the labels of a subrange of an existing layout .

Parameters:
  • layout[in] Layout to copy from

  • beg, end[in] Range from input layout to be copied.

    • If >= rank, consider at rank

    • If <= -rank, consider at 0

    • If < 0, consider at rank+beg (rank+end).

  • layout[out] Where the output layout will be written to

    • Must not be NULL

Return values:
  • NVCV_ERROR_INVALID_ARGUMENT – Some parameter is outside valid range.

  • NVCV_SUCCESS – Operation executed successfully.