nndeploy C++ API
0.2.0
nndeploy C++ API
framework
include
nndeploy
op
util.h
Go to the documentation of this file.
1
2
#ifndef _NNDEPLOY_OP_UTIL_H_
3
#define _NNDEPLOY_OP_UTIL_H_
4
5
#include "
nndeploy/base/any.h
"
6
#include "
nndeploy/base/common.h
"
7
#include "
nndeploy/base/glic_stl_include.h
"
8
#include "
nndeploy/base/log.h
"
9
#include "
nndeploy/base/macro.h
"
10
#include "
nndeploy/base/object.h
"
11
#include "
nndeploy/base/param.h
"
12
#include "
nndeploy/base/status.h
"
13
#include "
nndeploy/base/string.h
"
14
#include "
nndeploy/base/time_profiler.h
"
15
#include "
nndeploy/device/buffer.h
"
16
#include "
nndeploy/device/device.h
"
17
#include "
nndeploy/device/memory_pool.h
"
18
#include "
nndeploy/device/tensor.h
"
19
#include "
nndeploy/ir/ir.h
"
20
21
namespace
nndeploy
{
22
namespace
op {
23
24
// adjustNegativeAxes: Negative axes values are translated to the right axis in
25
// the positive range
26
void
adjustNegativeAxes
(
int
& axes,
int
rank);
27
28
void
adjustNegativeAxes
(std::vector<int>& axes,
int
rank);
29
30
// checkAxesRange: Checks that values are within the range [-rank, rank)
31
bool
checkAxesRange
(
int
axes,
int
rank);
32
bool
checkAxesRange
(std::vector<int>& axes,
int
rank);
33
34
int32_t
multiplyDims
(
const
base::IntVector
&
shape
,
int
from,
35
int
upto_exclusive);
36
37
}
// namespace op
38
}
// namespace nndeploy
39
40
#endif
/* _NNDEPLOY_OP_UTIL_H_ */
any.h
buffer.h
common.h
device.h
glic_stl_include.h
ir.h
log.h
macro.h
memory_pool.h
nndeploy::base::IntVector
std::vector< int > IntVector
Definition:
common.h:379
nndeploy::op::multiplyDims
int32_t multiplyDims(const base::IntVector &shape, int from, int upto_exclusive)
nndeploy::op::checkAxesRange
bool checkAxesRange(int axes, int rank)
nndeploy::op::shape
base::Status shape(device::Tensor *input, std::shared_ptr< ir::ShapeParam > param, device::Tensor *output)
nndeploy::op::adjustNegativeAxes
void adjustNegativeAxes(int &axes, int rank)
nndeploy
Definition:
common.h:10
object.h
param.h
status.h
string.h
tensor.h
time_profiler.h
Generated by
1.9.1