/home/docs/checkouts/readthedocs.org/user_builds/advanced-micro-devices-rpp/checkouts/develop/api/rppdefs.h Source File

/home/docs/checkouts/readthedocs.org/user_builds/advanced-micro-devices-rpp/checkouts/develop/api/rppdefs.h Source File#

RPP: /home/docs/checkouts/readthedocs.org/user_builds/advanced-micro-devices-rpp/checkouts/develop/api/rppdefs.h Source File
rppdefs.h
Go to the documentation of this file.
1 /*
2 MIT License
3 
4 Copyright (c) 2019 - 2025 Advanced Micro Devices, Inc.
5 
6 Permission is hereby granted, free of charge, to any person obtaining a copy
7 of this software and associated documentation files (the "Software"), to deal
8 in the Software without restriction, including without limitation the rights
9 to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
10 copies of the Software, and to permit persons to whom the Software is
11 furnished to do so, subject to the following conditions:
12 
13 The above copyright notice and this permission notice shall be included in all
14 copies or substantial portions of the Software.
15 
16 THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
17 IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
18 FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
19 AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
20 LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
21 OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
22 SOFTWARE.
23 */
24 
25 #ifndef RPPDEFS_H
26 #define RPPDEFS_H
27 
34 #include <stddef.h>
35 #include <cmath>
36 #ifdef RPP_BACKEND_HIP
37  #include <hip/hip_fp16.h>
38 #endif // RPP_BACKEND_HIP
39 #if __has_include(<half/half.hpp>)
40  #include <half/half.hpp>
41 #else
42  #include <half.hpp>
43 #endif
44 using halfhpp = half_float::half;
45 typedef halfhpp Rpp16f;
46 
47 #if _WIN32
48 #include <intrin.h>
49 #else
50 #include <x86intrin.h>
51 #include <smmintrin.h>
52 #include <immintrin.h>
53 #endif
54 #include<vector>
55 
57 #define RPP_MIN_8U ( 0 )
59 #define RPP_MAX_8U ( 255 )
61 #define RPPT_MAX_DIMS ( 5 )
63 #define RPPT_MAX_DIMS_SAMPLE ( 4 )
65 #define RPPT_MAX_AUDIO_CHANNELS ( 16 )
66 
67 #define CHECK_RETURN_STATUS(x) do { \
68  int retval = (x); \
69  if (retval != 0) { \
70  fprintf(stderr, "Runtime error: %s returned %d at %s:%d", #x, retval, __FILE__, __LINE__); \
71  exit(-1); \
72  } \
73 } while (0)
74 
75 #ifdef RPP_BACKEND_HIP
76 #include <hip/hip_runtime.h>
77 #define RPP_HOST_DEVICE __host__ __device__
79 #define HIP_CHECK_LAUNCH_RETURN() \
80  do { \
81  hipError_t status = hipGetLastError(); \
82  if (status != hipSuccess) { \
83  std::cerr << "AMD RPP: HIP Error Reported -- " \
84  << hipGetErrorString(status) << std::endl; \
85  return RPP_ERROR_HIP_LAUNCH; \
86  } \
87  } while (0)
88 #else
89 #define RPP_HOST_DEVICE
90 #endif
91 
92 const float ONE_OVER_6 = 1.0f / 6;
93 const float ONE_OVER_3 = 1.0f / 3;
94 const float TWO_OVER_3 = 2.0f / 3;
95 const float ONE_OVER_255 = 1.0f / 255;
96 const uint MMS_MAX_SCRATCH_MEMORY = 115293120; // maximum scratch memory size (in number of floats) needed for MMS buffer in RNNT training
97 const uint SPECTROGRAM_MAX_SCRATCH_MEMORY = 372877312; // maximum scratch memory size (in number of floats) needed for spectrogram HIP kernel in RNNT training
98 #define DROPOUT_FIXED_SEED 42 // Constant fixed seed for reproducing the dropout output
99 #define RANDOM_ERASE_NOISE_BUFFER_SIDE 255 // Random erase spatial noise buffer height and width. Changing this constant will result in QA test failures for tiled noise mapping
100 
101 /******************** RPP typedefs ********************/
102 
104 typedef unsigned char Rpp8u;
106 typedef signed char Rpp8s;
108 typedef unsigned short Rpp16u;
110 typedef short Rpp16s;
112 typedef unsigned int Rpp32u;
114 typedef int Rpp32s;
116 typedef unsigned long long Rpp64u;
118 typedef long long Rpp64s;
120 typedef float Rpp32f;
122 typedef double Rpp64f;
124 typedef void* RppPtr_t;
126 typedef size_t RppSize_t;
127 
131 typedef enum
132 {
136  RPP_ERROR = -1,
192 
196 typedef enum
197 {
198  RPP_HOST_BACKEND,
199  RPP_HIP_BACKEND
200 } RppBackend;
201 
205 typedef enum
206 {
207  rppStatusSuccess = 0,
208  rppStatusBadParm = -1,
209  rppStatusUnknownError = -2,
210  rppStatusNotInitialized = -3,
211  rppStatusInvalidValue = -4,
212  rppStatusAllocFailed = -5,
213  rppStatusInternalError = -6,
214  rppStatusNotImplemented = -7,
215  rppStatusUnsupportedOp = -8,
216 } rppStatus_t;
217 
221 typedef enum
222 {
223  RPP_TENSOR_OP_ADD,
224  RPP_TENSOR_OP_SUBTRACT,
225  RPP_TENSOR_OP_MULTIPLY,
226  RPP_TENSOR_OP_DIVIDE
227 } RpptOp;
228 
232 typedef enum
233 {
234  RPP_TENSOR_OP_AND,
235  RPP_TENSOR_OP_OR,
236  RPP_TENSOR_OP_XOR
237 } RpptBitwiseOp;
238 
246 typedef enum
247 {
248  RPP_BROADCAST_ENABLE,
249  RPP_BROADCAST_DISABLE // Broadcasting is disabled; Requires input tensors to be of the same shape
251 
255 typedef struct
256 {
257  Rpp32u channelParam;
258  Rpp32u bufferMultiplier;
260 
264 typedef struct
265 {
266  Rpp32f data[6];
267 } Rpp32f6;
268 
272 typedef struct
273 {
274  Rpp32f data[9];
275 } Rpp32f9;
276 
280 typedef struct
281 {
282  Rpp32s data[24];
283 } Rpp32s24;
284 
288 typedef struct
289 {
290  Rpp32f data[24];
291 } Rpp32f24;
292 
293 /******************** RPPT typedefs ********************/
294 
298 typedef enum
299 {
300  U8,
301  F32,
302  F16,
303  I8,
304  I16,
305  U16,
306  I32,
307  U32
308 } RpptDataType;
309 
313 typedef enum
314 {
315  NCHW, // BatchSize-Channels-Height-Width
316  NHWC, // BatchSize-Height-Width-Channels
317  NCDHW, // BatchSize-Channels-Depth-Height-Width
318  NDHWC, // BatchSize-Depth-Height-Width-Channels
319  NHW, // BatchSize-Height-Width
320  NFT, // BatchSize-Frequency-Time -> Frequency Major used for Spectrogram / MelfilterBank
321  NTF // BatchSize-Time-Frequency -> Time Major used for Spectrogram / MelfilterBank
322 } RpptLayout;
323 
328 typedef enum
329 {
338 
345 typedef enum
346 {
350 
354 typedef enum
355 {
356  LTRB, // Left-Top-Right-Bottom
357  XYWH // X-Y-Width-Height
358 } RpptRoiType;
359 
363 typedef enum
364 {
365  LTFRBB, // Left-Top-Front-Right-Bottom-Back
366  XYZWHD // X-Y-Z-Width-Height-Depth
367 } RpptRoi3DType;
368 
372 typedef enum
373 {
374  RGBtype,
375  BGRtype
377 
381 typedef enum
382 {
383  NEAREST_NEIGHBOR = 0,
384  BILINEAR,
385  BICUBIC,
386  LANCZOS,
387  GAUSSIAN,
388  TRIANGULAR
390 
394 typedef enum
395 {
396  ZERO = 0,
397  CLAMP,
398  REFLECT
400 
404 typedef enum
405 {
406  TOP_EDGE = 0,
407  BOTTOM_EDGE,
408  LEFT_EDGE,
409  RIGHT_EDGE
411 
415 typedef enum
416 {
417  REPLICATE = 0, // Similar to Nearest Neighbors Padding
418  CONSTANT, // Unsupported Border Type
419  REFLECT_NO_EDGE // Unsupported Border Type
421 
425 typedef enum
426 {
427  SLANEY = 0, // Follows Slaney’s MATLAB Auditory Modelling Work behavior
428  HTK, // Follows O’Shaughnessy’s book formula, consistent with Hidden Markov Toolkit(HTK), m = 2595 * log10(1 + (f/700))
430 
434 typedef struct
435 {
436  int x;
437  int y;
438 } RpptPoint2D;
439 
443 typedef struct
444 {
445  int x;
446  int y;
447  int z;
448 } RpptPoint3D;
449 
453 typedef struct
454 {
455  RpptPoint2D lt, rb; // Left-Top point and Right-Bottom point
456 
457 } RpptRoiLtrb;
458 
462 typedef struct
463 {
464  RpptPoint2D r;
465  RpptPoint2D g;
466  RpptPoint2D b;
468 
472 typedef struct
473 {
474  RpptPoint3D ltf, rbb; // Left-Top-Front point and Right-Bottom-Back point
475 
476 } RpptRoiLtfrbb;
477 
481 typedef struct
482 {
483  RpptPoint2D xy;
484  int roiWidth, roiHeight;
485 
486 } RpptRoiXywh;
487 
491 typedef struct
492 {
493  RpptPoint3D xyz;
494  int roiWidth, roiHeight, roiDepth;
495 
496 } RpptRoiXyzwhd;
497 
501 typedef union
502 {
503  RpptRoiLtrb ltrbROI; // ROI defined as Left-Top-Right-Bottom
504  RpptRoiXywh xywhROI; // ROI defined as X-Y-Width-Height
505 
506 } RpptROI, *RpptROIPtr;
507 
511 typedef union
512 {
513  RpptRoiLtfrbb ltfrbbROI; // ROI defined as Left-Top-Front-Right-Bottom-Back
514  RpptRoiXyzwhd xyzwhdROI; // ROI defined as X-Y-Z-Width-Height-Depth
515 
517 
521 typedef struct
522 {
523  Rpp32u nStride;
524  Rpp32u cStride;
525  Rpp32u hStride;
526  Rpp32u wStride;
527 } RpptStrides;
528 
532 typedef struct
533 {
534  RppSize_t numDims;
535  Rpp32u offsetInBytes;
536  RpptDataType dataType;
537  Rpp32u n, c, h, w;
538  RpptStrides strides;
539  RpptLayout layout;
541 
545 typedef struct
546 {
547  RppSize_t numDims;
548  Rpp32u offsetInBytes;
549  RpptDataType dataType;
550  Rpp32u dims[RPPT_MAX_DIMS];
551  Rpp32u strides[RPPT_MAX_DIMS];
552  RpptLayout layout;
554 
558 typedef struct
559 {
560  Rpp8u R;
561  Rpp8u G;
562  Rpp8u B;
563 } RpptRGB;
564 
568 typedef struct
569 {
570  Rpp32f R;
571  Rpp32f G;
572  Rpp32f B;
573 } RpptFloatRGB;
574 
578 typedef struct
579 {
580  Rpp32u x;
581  Rpp32u y;
583 
587 typedef struct
588 {
589  Rpp32f x;
590  Rpp32f y;
592 
596 typedef struct
597 {
598  Rpp32u width;
599  Rpp32u height;
601 
605 typedef struct
606 { Rpp32u x[5];
607  Rpp32u counter;
609 
613 typedef struct
614 { Rpp32s x[5];
615  Rpp32s counter;
616  int boxMullerFlag;
617  float boxMullerExtra;
619 
623 typedef struct
624 {
625  Rpp32s24 srcLocsTL;
626  Rpp32s24 srcLocsTR;
627  Rpp32s24 srcLocsBL;
628  Rpp32s24 srcLocsBR;
630 
634 typedef struct
635 {
636  Rpp32f24 srcValsTL;
637  Rpp32f24 srcValsTR;
638  Rpp32f24 srcValsBL;
639  Rpp32f24 srcValsBR;
641 
645 typedef struct GenericFilter
646 {
647  Rpp32f scale = 1.0f;
648  Rpp32f radius = 1.0f;
649  Rpp32s size;
650  GenericFilter(RpptInterpolationType interpolationType, Rpp32s in_size, Rpp32s out_size, Rpp32f scaleRatio)
651  {
652  switch(interpolationType)
653  {
654  case RpptInterpolationType::BICUBIC:
655  {
656  this->radius = 2.0f;
657  break;
658  }
659  case RpptInterpolationType::LANCZOS:
660  {
661  if(in_size > out_size)
662  {
663  this->radius = 3.0f * scaleRatio;
664  this->scale = (1 / scaleRatio);
665  }
666  else
667  this->radius = 3.0f;
668  break;
669  }
670  case RpptInterpolationType::GAUSSIAN:
671  {
672  if(in_size > out_size)
673  {
674  this->radius = scaleRatio;
675  this->scale = (1 / scaleRatio);
676  }
677  break;
678  }
679  case RpptInterpolationType::TRIANGULAR:
680  {
681  if(in_size > out_size)
682  {
683  this->radius = scaleRatio;
684  this->scale = (1 / scaleRatio);
685  }
686  break;
687  }
688  default:
689  {
690  this->radius = 1.0f;
691  this->scale = 1.0f;
692  break;
693  }
694  }
695  this->size = std::ceil(2 * this->radius);
696  }
698 
702 typedef struct RpptResamplingWindow
703 {
704  inline RPP_HOST_DEVICE void input_range(Rpp32f x, Rpp32s *loc0, Rpp32s *loc1)
705  {
706  Rpp32s xc = std::ceil(x);
707  *loc0 = xc - lobes;
708  *loc1 = xc + lobes;
709  }
710 
711  inline Rpp32f operator()(Rpp32f x)
712  {
713  Rpp32f locRaw = x * scale + center;
714  Rpp32s locFloor = std::floor(locRaw);
715  Rpp32f weight = locRaw - locFloor;
716  locFloor = std::max(std::min(locFloor, lookupSize - 2), 0);
717  Rpp32f current = lookup[locFloor];
718  Rpp32f next = lookup[locFloor + 1];
719  return current + weight * (next - current);
720  }
721 
722  inline __m128 operator()(__m128 x)
723  {
724  __m128 pLocRaw = _mm_add_ps(_mm_mul_ps(x, pScale), pCenter);
725  __m128i pxLocFloor = _mm_cvttps_epi32(pLocRaw);
726  __m128 pLocFloor = _mm_cvtepi32_ps(pxLocFloor);
727  __m128 pWeight = _mm_sub_ps(pLocRaw, pLocFloor);
728  Rpp32s idx[4];
729  _mm_storeu_si128(reinterpret_cast<__m128i*>(idx), pxLocFloor);
730  __m128 pCurrent = _mm_setr_ps(lookup[idx[0]], lookup[idx[1]], lookup[idx[2]], lookup[idx[3]]);
731  __m128 pNext = _mm_setr_ps(lookup[idx[0] + 1], lookup[idx[1] + 1], lookup[idx[2] + 1], lookup[idx[3] + 1]);
732  return _mm_add_ps(pCurrent, _mm_mul_ps(pWeight, _mm_sub_ps(pNext, pCurrent)));
733  }
734 
735  Rpp32f scale = 1, center = 1;
736  Rpp32s lobes = 0, coeffs = 0;
737  Rpp32s lookupSize = 0;
738  Rpp32f *lookupPinned = nullptr;
739  std::vector<Rpp32f> lookup;
740  __m128 pCenter, pScale;
742 
747 {
748  public:
749  inline RPP_HOST_DEVICE virtual Rpp32f hz_to_mel(Rpp32f hz) = 0;
750  inline RPP_HOST_DEVICE virtual Rpp32f mel_to_hz(Rpp32f mel) = 0;
751  virtual ~BaseMelScale() = default;
752 };
753 
757 struct HtkMelScale : public BaseMelScale
758 {
759  inline RPP_HOST_DEVICE Rpp32f hz_to_mel(Rpp32f hz) { return 1127.0f * std::log(1.0f + (hz / 700.0f)); }
760  inline RPP_HOST_DEVICE Rpp32f mel_to_hz(Rpp32f mel) { return 700.0f * (std::exp(mel / 1127.0f) - 1.0f); }
761  public:
762  ~HtkMelScale() {};
763 };
764 
769 {
770  const Rpp32f freqLow = 0;
771  const Rpp32f fsp = 66.666667f;
772  const Rpp32f minLogHz = 1000.0;
773  const Rpp32f minLogMel = (minLogHz - freqLow) / fsp;
774  const Rpp32f stepLog = 0.068751777; // Equivalent to std::log(6.4) / 27.0;
775 
776  const Rpp32f invMinLogHz = 0.001f;
777  const Rpp32f invStepLog = 1.0f / stepLog;
778  const Rpp32f invFsp = 1.0f / fsp;
779 
780  inline RPP_HOST_DEVICE Rpp32f hz_to_mel(Rpp32f hz)
781  {
782  Rpp32f mel = 0.0f;
783  if (hz >= minLogHz)
784  mel = minLogMel + std::log(hz * invMinLogHz) * invStepLog;
785  else
786  mel = (hz - freqLow) * invFsp;
787 
788  return mel;
789  }
790 
791  inline RPP_HOST_DEVICE Rpp32f mel_to_hz(Rpp32f mel)
792  {
793  Rpp32f hz = 0.0f;
794  if (mel >= minLogMel)
795  hz = minLogHz * std::exp(stepLog * (mel - minLogMel));
796  else
797  hz = freqLow + mel * fsp;
798  return hz;
799  }
800  public:
801  ~SlaneyMelScale() {};
802 };
803 
804 /******************** HOST memory typedefs ********************/
805 
809 typedef struct {
810  Rpp32f *scratchBufferHost;
811 } memCPU;
812 
813 #ifdef RPP_BACKEND_HIP
814 
815 /******************** HIP memory typedefs ********************/
816 
820 typedef struct
821 {
822  Rpp32f* floatmem;
823 } hipMemRpp32f;
824 
828 typedef struct
829 {
830  hipMemRpp32f scratchBufferHip;
831  hipMemRpp32f scratchBufferPinned;
832 } memGPU;
833 
837 typedef struct
838 {
839  memCPU mcpu;
840  memGPU mgpu;
841 } memMgmt;
842 
843 #else
844 
848 typedef struct
849 {
850  memCPU mcpu;
851 } memMgmt;
852 
853 #endif //BACKEND
854 
858 typedef struct
859 {
860  RppPtr_t cpuHandle;
861  Rpp32u nbatchSize;
862  memMgmt mem;
863 } InitHandle;
864 
865 #endif /* RPPDEFS_H */
unsigned int Rpp32u
32 bit unsigned int
Definition: rppdefs.h:112
int Rpp32s
32 bit signed int
Definition: rppdefs.h:114
signed char Rpp8s
8 bit signed char
Definition: rppdefs.h:106
RpptMelScaleFormula
RPPT Mel Scale Formula.
Definition: rppdefs.h:426
unsigned short Rpp16u
16 bit unsigned short
Definition: rppdefs.h:108
unsigned char Rpp8u
8 bit unsigned char
Definition: rppdefs.h:104
void * RppPtr_t
void pointer
Definition: rppdefs.h:124
RpptLayout
RPPT Tensor layout type enum.
Definition: rppdefs.h:314
RpptRoiType
RPPT Tensor 2D ROI type enum.
Definition: rppdefs.h:355
RpptDataType
RPPT Tensor datatype enum.
Definition: rppdefs.h:299
RpptImageBorderType
RPPT Image Border Type.
Definition: rppdefs.h:416
struct RpptResamplingWindow RpptResamplingWindow
RPPT Tensor RpptResamplingWindow type struct.
double Rpp64f
64 bit double
Definition: rppdefs.h:122
RpptImageBorderEdge
RPPT Image Border Edge type enum.
Definition: rppdefs.h:405
RpptAudioBorderType
RPPT Audio Border Type.
Definition: rppdefs.h:395
size_t RppSize_t
size_t
Definition: rppdefs.h:126
RpptBitwiseOp
RPPT Broadcast Mode type enum.
Definition: rppdefs.h:233
RpptColorStandard
Color space standard for NV12 to RGB (YUV/YCbCr to RGB matrix).
Definition: rppdefs.h:329
struct GenericFilter GenericFilter
RPPT Tensor GenericFilter type struct.
RppStatus
RPP RppStatus type enums.
Definition: rppdefs.h:132
RpptColorRange
Color range (luma/chroma legal levels) for NV12 to RGB.
Definition: rppdefs.h:346
RpptRoi3DType
RPPT Tensor 3D ROI type enum.
Definition: rppdefs.h:364
unsigned long long Rpp64u
64 bit unsigned long long
Definition: rppdefs.h:116
#define RPPT_MAX_DIMS
RPP maximum dimensions in tensor .
Definition: rppdefs.h:61
RpptInterpolationType
RPPT Tensor interpolation type enum.
Definition: rppdefs.h:382
RpptSubpixelLayout
RPPT Tensor subpixel layout type enum.
Definition: rppdefs.h:373
RpptOp
RPP Tensor Operations type enum.
Definition: rppdefs.h:222
short Rpp16s
16 bit signed short
Definition: rppdefs.h:110
float Rpp32f
32 bit float
Definition: rppdefs.h:120
RppBackend
RPP RppBackend type enums.
Definition: rppdefs.h:197
long long Rpp64s
64 bit long long
Definition: rppdefs.h:118
rppStatus_t
RPP rppStatus_t type enums.
Definition: rppdefs.h:206
@ RpptColorStandard_FCC
Definition: rppdefs.h:331
@ RpptColorStandard_SMPTE240M
Definition: rppdefs.h:334
@ RpptColorStandard_BT601
Definition: rppdefs.h:333
@ RpptColorStandard_BT470BG
Definition: rppdefs.h:332
@ RpptColorStandard_BT709
Definition: rppdefs.h:330
@ RpptColorStandard_BT2020_NCL
Definition: rppdefs.h:335
@ RpptColorStandard_BT2020_CL
Definition: rppdefs.h:336
@ RPP_ERROR_NOT_IMPLEMENTED
Function variant requested is not implemented / unsupported.
Definition: rppdefs.h:146
@ RPP_ERROR_INVALID_DST_DATATYPE
Invalid dst tensor datatype. (Needs to adhere to function specification.)
Definition: rppdefs.h:158
@ RPP_ERROR_INVALID_OUTPUT_TILE_LENGTH
Invalid output tile length (Needs to adhere to function specification.)
Definition: rppdefs.h:174
@ RPP_ERROR_INVALID_DIM_LENGTHS
Length in some dimensions are invalid. (Needs to adhere to function specification....
Definition: rppdefs.h:184
@ RPP_ERROR_OUT_OF_BOUND_SRC_ROI
Out of bound source ROI.
Definition: rppdefs.h:168
@ RPP_ERROR_OUT_OF_BOUND_SHARED_MEMORY_SIZE
Shared memory size needed is beyond the bounds (Needs to adhere to function specification....
Definition: rppdefs.h:176
@ RPP_ERROR_INCOMPATIBLE_BACKEND
The user specified backend is not compatible with the initialized handle.
Definition: rppdefs.h:188
@ RPP_ERROR_HIP_LAUNCH
HIP/GPU runtime or kernel launch error.
Definition: rppdefs.h:190
@ RPP_ERROR_ZERO_DIVISION
Arguments provided will result in zero division error.
Definition: rppdefs.h:142
@ RPP_ERROR_INVALID_ARGUMENTS
One or more arguments invalid. (Needs to adhere to function specification.)
Definition: rppdefs.h:138
@ RPP_ERROR_LAYOUT_MISMATCH
src and dst layout mismatch
Definition: rppdefs.h:170
@ RPP_ERROR_INVALID_CHANNELS
Number of channels is invalid. (Needs to adhere to function specification.)
Definition: rppdefs.h:172
@ RPP_ERROR_INVALID_SRC_CHANNELS
Invalid src tensor number of channels. (Needs to adhere to function specification....
Definition: rppdefs.h:148
@ RPP_ERROR_INVALID_SRC_OR_DST_DATATYPE
Invalid src/dst tensor datatype. (Needs to adhere to function specification.)
Definition: rppdefs.h:160
@ RPP_ERROR_INVALID_PARAMETER_DATATYPE
Invalid datatype.
Definition: rppdefs.h:164
@ RPP_ERROR_NOT_ENOUGH_MEMORY
Not enough memory to write outputs, as per dim-lengths and strides set in descriptor.
Definition: rppdefs.h:166
@ RPP_ERROR
Unspecified error.
Definition: rppdefs.h:136
@ RPP_ERROR_INVALID_SRC_DIMS
Number of src dims is invalid. (Needs to adhere to function specification.)
Definition: rppdefs.h:180
@ RPP_ERROR_OUT_OF_BOUND_SCRATCH_MEMORY_SIZE
Scratch memory size needed is beyond the bounds (Needs to adhere to function specification....
Definition: rppdefs.h:178
@ RPP_ERROR_INVALID_DST_LAYOUT
Invalid dst tensor layout. (Needs to adhere to function specification.)
Definition: rppdefs.h:154
@ RPP_ERROR_INVALID_AXIS
The specified axis is invalid or out of range. (Needs to adhere to function specification....
Definition: rppdefs.h:186
@ RPP_ERROR_INVALID_DST_CHANNELS
Invalid dst tensor number of channels. (Needs to adhere to function specification....
Definition: rppdefs.h:150
@ RPP_ERROR_INVALID_SRC_DATATYPE
Invalid src tensor datatype. (Needs to adhere to function specification.)
Definition: rppdefs.h:156
@ RPP_ERROR_INVALID_SRC_LAYOUT
Invalid src tensor layout. (Needs to adhere to function specification.)
Definition: rppdefs.h:152
@ RPP_ERROR_HIGH_SRC_DIMENSION
Src tensor / src ROI dimension too high. (Needs to adhere to function specification....
Definition: rppdefs.h:144
@ RPP_SUCCESS
No error.
Definition: rppdefs.h:134
@ RPP_ERROR_INSUFFICIENT_DST_BUFFER_LENGTH
Insufficient dst buffer length provided. (Needs to adhere to function specification....
Definition: rppdefs.h:162
@ RPP_ERROR_INVALID_DST_DIMS
Number of dst dims is invalid. (Needs to adhere to function specification.)
Definition: rppdefs.h:182
@ RPP_ERROR_LOW_OFFSET
Low tensor offsetInBytes provided for src/dst tensor.
Definition: rppdefs.h:140
@ RpptColorRange_FULL
Definition: rppdefs.h:348
@ RpptColorRange_STUDIO
Definition: rppdefs.h:347
RpptBroadcastMode
Broadcast support mode for RPP Tensor operations.
Definition: rppdefs.h:247
Base class for Mel scale conversions.
Definition: rppdefs.h:747
RPPT Tensor GenericFilter type struct.
Definition: rppdefs.h:646
Derived class for HTK Mel scale conversions.
Definition: rppdefs.h:758
RPP initialize handle.
Definition: rppdefs.h:859
RPP 24 float vector.
Definition: rppdefs.h:289
RPP 6 float vector.
Definition: rppdefs.h:265
RPP 9 float vector.
Definition: rppdefs.h:273
RPP 24 signed int vector.
Definition: rppdefs.h:281
RPP layout params.
Definition: rppdefs.h:256
RPPT Tensor 2D bilinear neighborhood 32-bit signed int 8-length-vectors type struct.
Definition: rppdefs.h:624
RPPT Tensor 2D bilinear neighborhood 32-bit float 8-length-vectors type struct.
Definition: rppdefs.h:635
RPPT Tensor Channel Offsets struct.
Definition: rppdefs.h:463
RPPT Tensor descriptor type struct.
Definition: rppdefs.h:533
RPPT Tensor 32-bit float RGB type struct.
Definition: rppdefs.h:569
RPPT Tensor 2D 32-bit float vector type struct.
Definition: rppdefs.h:588
RPPT Tensor Generic descriptor type struct.
Definition: rppdefs.h:546
RPPT Tensor 2D image patch dimensions type struct.
Definition: rppdefs.h:597
RPPT Image 2D cartesian point type struct.
Definition: rppdefs.h:435
RPPT Image 3D point type struct.
Definition: rppdefs.h:444
RPPT Tensor 8-bit uchar RGB type struct.
Definition: rppdefs.h:559
RPPT Tensor RpptResamplingWindow type struct.
Definition: rppdefs.h:703
RPPT Tensor 3D ROI LTFRBB struct.
Definition: rppdefs.h:473
RPPT Tensor 2D ROI LTRB struct.
Definition: rppdefs.h:454
RPPT Tensor 2D ROI XYWH struct.
Definition: rppdefs.h:482
RPPT Tensor 3D ROI XYZWHD struct.
Definition: rppdefs.h:492
RPPT Tensor strides type struct.
Definition: rppdefs.h:522
RPPT Tensor 2D 32-bit uint vector type struct.
Definition: rppdefs.h:579
RPPT Tensor random number generator state (xorwow box muller state) type struct.
Definition: rppdefs.h:614
RPPT Tensor random number generator state (xorwow state) type struct.
Definition: rppdefs.h:606
Derived class for Slaney Mel scale conversions.
Definition: rppdefs.h:769
RPP HIP 32-bit float memory.
Definition: rppdefs.h:821
RPP HOST memory type struct.
Definition: rppdefs.h:809
RPP HIP memory management type struct.
Definition: rppdefs.h:829
RPP HIP-HOST memory management.
Definition: rppdefs.h:838
RPPT Tensor 3D ROI union.
Definition: rppdefs.h:512
RPPT Tensor 2D ROI union.
Definition: rppdefs.h:502