nndeploy C++ API  0.2.0
nndeploy C++ API
shape.h
Go to the documentation of this file.
1 
2 #ifndef _NNDEPLOY_BASE_SHAPE_H_
3 #define _NNDEPLOY_BASE_SHAPE_H_
4 
5 #include "nndeploy/base/common.h"
7 #include "nndeploy/base/macro.h"
8 
9 namespace nndeploy {
10 namespace base {
11 
12 extern NNDEPLOY_CC_API size_t shapeCount(const IntVector &dims,
13  int start_index = 0,
14  int end_index = -1);
15 
17  const IntVector &dims1,
18  int start_index = 0,
19  int end_index = -1);
20 
22  const IntVector &dims1,
23  int start_index = 0,
24  int end_index = -1);
25 
26 extern NNDEPLOY_CC_API bool shapeEqual(const IntVector &dims0,
27  const IntVector &dims1,
28  int start_index = 0, int end_index = -1);
29 
31 
33 
34 extern NNDEPLOY_CC_API bool isDynamicShape(const IntVector &dims);
35 
36 } // namespace base
37 } // namespace nndeploy
38 
39 #endif
#define NNDEPLOY_CC_API
api
Definition: macro.h:29
size_t shapeCount(const IntVector &dims, int start_index=0, int end_index=-1)
std::vector< int > IntVector
Definition: common.h:379
bool isDynamicShape(const IntVector &dims)
IntVector shapeMax(const IntVector &dims0, const IntVector &dims1, int start_index=0, int end_index=-1)
bool shapeEqual(const IntVector &dims0, const IntVector &dims1, int start_index=0, int end_index=-1)
IntVector shapeMin(const IntVector &dims0, const IntVector &dims1, int start_index=0, int end_index=-1)
IntVector shapeNchw2Nhwc(const IntVector &dims)
IntVector shapeNhwc2Nchw(const IntVector &dims)