|
nndeploy C++ API
0.2.0
nndeploy C++ API
|
Typedefs | |
| using | MIMOOpFunc = std::function< base::Status(std::initializer_list< device::Tensor * > inputs, std::initializer_list< device::Tensor * > outputs, std::shared_ptr< base::Param > op_param)> |
| using | MISOOpFunc = std::function< base::Status(std::initializer_list< device::Tensor * > inputs, device::Tensor *output, std::shared_ptr< base::Param > op_param)> |
| using | SIMOOpFunc = std::function< base::Status(device::Tensor *input, std::initializer_list< device::Tensor * > outputs, std::shared_ptr< base::Param > op_param)> |
| using | SISOOpFunc = std::function< base::Status(device::Tensor *input, device::Tensor *output, std::shared_ptr< base::Param > op_param)> |
Enumerations | |
| enum | ExprType : int { kExprTypeValueDesc = 0x0000 , kExprTypeOpDesc , kExprTypeModelDesc } |
Functions | |
| base::Status | abs (device::Tensor *input, device::Tensor *output) |
| base::Status | acos (device::Tensor *input, device::Tensor *output) |
| base::Status | add (device::Tensor *input1, device::Tensor *input2, device::Tensor *output) |
| void | adjustNegativeAxes (int &axes, int rank) |
| void | adjustNegativeAxes (std::vector< int > &axes, int rank) |
| base::Status | asin (device::Tensor *input, device::Tensor *output) |
| base::Status | atan (device::Tensor *input, device::Tensor *output) |
| base::Status | batchNorm (device::Tensor *input1, device::Tensor *scale, device::Tensor *bias, device::Tensor *mean, device::Tensor *var, std::shared_ptr< ir::BatchNormalizationParam > param, device::Tensor *output) |
| base::Status | cast (device::Tensor *input, std::shared_ptr< ir::CastParam > param, device::Tensor *output) |
| base::Status | ceil (device::Tensor *input, device::Tensor *output) |
| bool | checkAxesRange (int axes, int rank) |
| bool | checkAxesRange (std::vector< int > &axes, int rank) |
| base::Status | concat (std::vector< device::Tensor * > inputs, std::shared_ptr< ir::ConcatParam > param, device::Tensor *output) |
| base::Status | constantOfShape (device::Tensor *shape, std::shared_ptr< ir::ConstantOfShapeParam > param, device::Tensor *output) |
| base::Status | conv (device::Tensor *input, device::Tensor *weight, device::Tensor *bias, std::shared_ptr< ir::ConvParam > param, device::Tensor *output) |
| base::Status | cos (device::Tensor *input, device::Tensor *output) |
| base::Status | cosh (device::Tensor *input, device::Tensor *output) |
| Op * | createOp (base::DeviceType device_type, const std::string &name, ir::OpType op_type) |
| Op * | createOp (base::DeviceType device_type, const std::string &name, ir::OpType op_type, std::initializer_list< std::string > inputs, std::initializer_list< std::string > outputs) |
| Op * | createOp (base::DeviceType device_type, const std::string &name, ir::OpType op_type, std::vector< std::string > &inputs, std::vector< std::string > &outputs) |
| Op * | createOp (base::DeviceType device_type, const std::string &name, ir::OpType op_type, std::vector< std::string > &inputs, std::vector< std::string > &outputs, std::shared_ptr< base::Param > param) |
| Op * | createOp (base::DeviceType device_type, std::shared_ptr< ir::OpDesc > op_desc) |
| std::shared_ptr< Op > | createOpSharedPtr (base::DeviceType device_type, const std::string &name, ir::OpType op_type) |
| std::shared_ptr< Op > | createOpSharedPtr (base::DeviceType device_type, const std::string &name, ir::OpType op_type, std::initializer_list< std::string > inputs, std::initializer_list< std::string > outputs) |
| std::shared_ptr< Op > | createOpSharedPtr (base::DeviceType device_type, const std::string &name, ir::OpType op_type, std::vector< std::string > &inputs, std::vector< std::string > &outputs) |
| std::shared_ptr< Op > | createOpSharedPtr (base::DeviceType device_type, const std::string &name, ir::OpType op_type, std::vector< std::string > &inputs, std::vector< std::string > &outputs, std::shared_ptr< base::Param > param) |
| std::shared_ptr< Op > | createOpSharedPtr (base::DeviceType device_type, std::shared_ptr< ir::OpDesc > op_desc) |
| base::Status | dequantizeLinear (device::Tensor *input, device::Tensor *scale, device::Tensor *zero_point, std::shared_ptr< ir::DequantizeLinearParam > param, device::Tensor *output) |
| base::Status | div (device::Tensor *input1, device::Tensor *input2, device::Tensor *output) |
| base::Status | embedding (device::Tensor *input, device::Tensor *indice, device::Tensor *output) |
| base::Status | equal (device::Tensor *input_a, device::Tensor *input_b, device::Tensor *output) |
| base::Status | erf (device::Tensor *input, device::Tensor *output) |
| base::Status | exp (device::Tensor *input, device::Tensor *output) |
| base::Status | expand (device::Tensor *input, device::Tensor *shape, device::Tensor *output) |
| std::string | exprTypeToString (ExprType type) |
| base::Status | flatten (device::Tensor *inputs, std::shared_ptr< ir::FlattenParam > param, device::Tensor *output) |
| base::Status | floor (device::Tensor *input, device::Tensor *output) |
| base::Status | gather (device::Tensor *input, device::Tensor *index, std::shared_ptr< ir::GatherParam > param, device::Tensor *output) |
| base::Status | gelu (device::Tensor *input, device::Tensor *output) |
| base::Status | gemm (device::Tensor *inputs_a, device::Tensor *inputs_b, device::Tensor *inputs_c, std::shared_ptr< ir::GemmParam > param, device::Tensor *output) |
| std::map< base::DeviceTypeCode, std::map< ir::OpType, std::shared_ptr< OpCreator > > > & | getGlobalOpCreatorMap () |
| Get the Global Op Creator Map object. More... | |
| base::Status | globalAveragepool (device::Tensor *input, device::Tensor *output) |
| base::Status | hardsigmoid (device::Tensor *input, device::Tensor *output) |
| base::Status | log (device::Tensor *input, device::Tensor *output) |
| std::shared_ptr< Expr > | makeAdd (ir::ModelDesc *model_desc, std::shared_ptr< Expr > input_0, std::shared_ptr< Expr > input_1, std::string op_name="", std::string output_name="") |
| std::shared_ptr< Expr > | makeBatchNorm (ir::ModelDesc *model_desc, std::shared_ptr< Expr > input, std::shared_ptr< ir::BatchNormalizationParam > param, const std::string &scale, const std::string &bias, const std::string &mean, const std::string &var, std::string op_name="", std::string output_name="") |
| std::shared_ptr< Expr > | makeBlock (ir::ModelDesc *model_desc, std::shared_ptr< ir::ModelDesc > model_block) |
| std::shared_ptr< Expr > | makeConstant (ir::ModelDesc *model_desc, std::string name) |
| std::shared_ptr< Expr > | makeConv (ir::ModelDesc *model_desc, std::shared_ptr< Expr > input, std::shared_ptr< ir::ConvParam > param, const std::string &weight, const std::string &bias="", std::string op_name="", std::string output_name="") |
| std::shared_ptr< Expr > | makeEmbedding (ir::ModelDesc *model_desc, std::shared_ptr< Expr > indices, std::string op_name, std::string output_name) |
| std::shared_ptr< Expr > | makeFlatten (ir::ModelDesc *model_desc, std::shared_ptr< Expr > input, std::shared_ptr< ir::FlattenParam > param, std::string op_name="", std::string output_name="") |
| std::shared_ptr< Expr > | makeGemm (ir::ModelDesc *model_desc, std::shared_ptr< Expr > input, std::shared_ptr< ir::GemmParam > param, const std::string &weight, const std::string &bias="", std::string op_name="", std::string output_name="") |
| std::shared_ptr< Expr > | makeGlobalAveragePool (ir::ModelDesc *model_desc, std::shared_ptr< Expr > input, std::string op_name="", std::string output_name="") |
| std::shared_ptr< Expr > | makeInput (ir::ModelDesc *model_desc, std::string name, base::DataType data_type=base::dataTypeOf< float >(), base::IntVector shape=base::IntVector()) |
| 一系列创建函数 More... | |
| std::shared_ptr< Expr > | makeMaxPool (ir::ModelDesc *model_desc, std::shared_ptr< Expr > input, std::shared_ptr< ir::MaxPoolParam > param, std::string op_name="", std::string output_name="") |
| void | makeOutput (ir::ModelDesc *model_desc, std::shared_ptr< Expr > expr) |
| std::shared_ptr< Expr > | makeRelu (ir::ModelDesc *model_desc, std::shared_ptr< Expr > input, std::string op_name="", std::string output_name="") |
| std::shared_ptr< Expr > | makeSigmoid (ir::ModelDesc *model_desc, std::shared_ptr< Expr > input, std::string op_name="", std::string output_name="") |
| std::shared_ptr< Expr > | makeSoftmax (ir::ModelDesc *model_desc, std::shared_ptr< Expr > input, std::shared_ptr< ir::SoftmaxParam > param, std::string op_name="", std::string output_name="") |
| base::Status | matmul (device::Tensor *inputs_a, device::Tensor *inputs_b, std::shared_ptr< ir::MatMulParam > param, device::Tensor *output) |
| base::Status | matmul (device::Tensor *inputs_a, device::Tensor *inputs_b, std::shared_ptr< ir::MatMulParam > param, device::Tensor *output, device::Tensor *inputs_bias) |
| base::Status | maxPool (device::Tensor *input, std::shared_ptr< ir::MaxPoolParam > param, device::Tensor *output) |
| base::Status | mul (device::Tensor *input1, device::Tensor *input2, device::Tensor *output) |
| base::Status | muls (device::Tensor *scale, device::Tensor *input, device::Tensor *output) |
| int32_t | multiplyDims (const base::IntVector &shape, int from, int upto_exclusive) |
| base::Status | neg (device::Tensor *input, device::Tensor *output) |
| base::Status | pow (device::Tensor *input, device::Tensor *exponent, device::Tensor *output) |
| base::Status | qLinearConv (device::Tensor *x, device::Tensor *x_scale, device::Tensor *x_zero_point, device::Tensor *w, device::Tensor *w_scale, device::Tensor *w_zero_point, device::Tensor *y_scale, device::Tensor *y_zero_point, device::Tensor *B, std::shared_ptr< ir::QLinearConvParam > param, device::Tensor *output) |
| base::Status | quantizeLinear (device::Tensor *input, device::Tensor *scale, device::Tensor *zero_point, std::shared_ptr< ir::QuantizeLinearParam > param, device::Tensor *output) |
| base::Status | reciprocal (device::Tensor *input, device::Tensor *output) |
| base::Status | reduceMean (device::Tensor *input, device::Tensor *axes, std::shared_ptr< ir::ReduceMeanParam > param, device::Tensor *output) |
| base::Status | relu (device::Tensor *input, device::Tensor *output) |
| base::Status | reshape (device::Tensor *input, device::Tensor *shape, std::shared_ptr< ir::ReshapeParam > param, device::Tensor *output) |
| base::Status | resize (device::Tensor *input, device::Tensor *roi, device::Tensor *scales, device::Tensor *sizes, std::shared_ptr< ir::ResizeParam > param, device::Tensor *output) |
| base::Status | rmsNorm (device::Tensor *input, device::Tensor *weight, std::shared_ptr< base::Param > param, device::Tensor *output) |
| base::Status | round (device::Tensor *input, device::Tensor *output) |
| base::Status | selu (device::Tensor *input, device::Tensor *output) |
| base::Status | shape (device::Tensor *input, std::shared_ptr< ir::ShapeParam > param, device::Tensor *output) |
| base::Status | sigmoid (device::Tensor *input, device::Tensor *output) |
| base::Status | sign (device::Tensor *input, device::Tensor *output) |
| base::Status | sin (device::Tensor *input, device::Tensor *output) |
| base::Status | sinh (device::Tensor *input, device::Tensor *output) |
| base::Status | slice (device::Tensor *input, device::Tensor *starts, device::Tensor *ends, device::Tensor *axes, device::Tensor *steps, device::Tensor *output) |
| base::Status | softmax (device::Tensor *input, std::shared_ptr< ir::SoftmaxParam > param, device::Tensor *output) |
| base::Status | split (device::Tensor *input, device::Tensor *section, std::shared_ptr< ir::SplitParam > param, std::vector< device::Tensor * > outputs) |
| base::Status | sqrt (device::Tensor *input, device::Tensor *output) |
| ExprType | stringToExprType (const std::string &src) |
| base::Status | sub (device::Tensor *input1, device::Tensor *input2, device::Tensor *output) |
| base::Status | tan (device::Tensor *input, device::Tensor *output) |
| base::Status | tanh (device::Tensor *input, device::Tensor *output) |
| base::Status | transpose (device::Tensor *input, std::shared_ptr< ir::TransposeParam > param, device::Tensor *output) |
| base::Status | unsqueeze (device::Tensor *input, device::Tensor *axes, device::Tensor *output) |
| base::Status | where (device::Tensor *input1, device::Tensor *input2, device::Tensor *condition, device::Tensor *output) |
| using nndeploy::op::MIMOOpFunc = typedef std::function<base::Status(std::initializer_list<device::Tensor *> inputs, std::initializer_list<device::Tensor *> outputs, std::shared_ptr<base::Param> op_param)> |
| using nndeploy::op::MISOOpFunc = typedef std::function<base::Status( std::initializer_list<device::Tensor *> inputs, device::Tensor *output, std::shared_ptr<base::Param> op_param)> |
| using nndeploy::op::SIMOOpFunc = typedef std::function<base::Status( device::Tensor *input, std::initializer_list<device::Tensor *> outputs, std::shared_ptr<base::Param> op_param)> |
| using nndeploy::op::SISOOpFunc = typedef std::function<base::Status(device::Tensor *input, device::Tensor *output, std::shared_ptr<base::Param> op_param)> |
| enum nndeploy::op::ExprType : int |
| base::Status nndeploy::op::abs | ( | device::Tensor * | input, |
| device::Tensor * | output | ||
| ) |
| base::Status nndeploy::op::acos | ( | device::Tensor * | input, |
| device::Tensor * | output | ||
| ) |
| base::Status nndeploy::op::add | ( | device::Tensor * | input1, |
| device::Tensor * | input2, | ||
| device::Tensor * | output | ||
| ) |
| void nndeploy::op::adjustNegativeAxes | ( | int & | axes, |
| int | rank | ||
| ) |
| void nndeploy::op::adjustNegativeAxes | ( | std::vector< int > & | axes, |
| int | rank | ||
| ) |
| base::Status nndeploy::op::asin | ( | device::Tensor * | input, |
| device::Tensor * | output | ||
| ) |
| base::Status nndeploy::op::atan | ( | device::Tensor * | input, |
| device::Tensor * | output | ||
| ) |
| base::Status nndeploy::op::batchNorm | ( | device::Tensor * | input1, |
| device::Tensor * | scale, | ||
| device::Tensor * | bias, | ||
| device::Tensor * | mean, | ||
| device::Tensor * | var, | ||
| std::shared_ptr< ir::BatchNormalizationParam > | param, | ||
| device::Tensor * | output | ||
| ) |
| base::Status nndeploy::op::cast | ( | device::Tensor * | input, |
| std::shared_ptr< ir::CastParam > | param, | ||
| device::Tensor * | output | ||
| ) |
| base::Status nndeploy::op::ceil | ( | device::Tensor * | input, |
| device::Tensor * | output | ||
| ) |
| bool nndeploy::op::checkAxesRange | ( | int | axes, |
| int | rank | ||
| ) |
| bool nndeploy::op::checkAxesRange | ( | std::vector< int > & | axes, |
| int | rank | ||
| ) |
| base::Status nndeploy::op::concat | ( | std::vector< device::Tensor * > | inputs, |
| std::shared_ptr< ir::ConcatParam > | param, | ||
| device::Tensor * | output | ||
| ) |
| base::Status nndeploy::op::constantOfShape | ( | device::Tensor * | shape, |
| std::shared_ptr< ir::ConstantOfShapeParam > | param, | ||
| device::Tensor * | output | ||
| ) |
| base::Status nndeploy::op::conv | ( | device::Tensor * | input, |
| device::Tensor * | weight, | ||
| device::Tensor * | bias, | ||
| std::shared_ptr< ir::ConvParam > | param, | ||
| device::Tensor * | output | ||
| ) |
| base::Status nndeploy::op::cos | ( | device::Tensor * | input, |
| device::Tensor * | output | ||
| ) |
| base::Status nndeploy::op::cosh | ( | device::Tensor * | input, |
| device::Tensor * | output | ||
| ) |
| Op* nndeploy::op::createOp | ( | base::DeviceType | device_type, |
| const std::string & | name, | ||
| ir::OpType | op_type | ||
| ) |
| Op* nndeploy::op::createOp | ( | base::DeviceType | device_type, |
| const std::string & | name, | ||
| ir::OpType | op_type, | ||
| std::initializer_list< std::string > | inputs, | ||
| std::initializer_list< std::string > | outputs | ||
| ) |
| Op* nndeploy::op::createOp | ( | base::DeviceType | device_type, |
| const std::string & | name, | ||
| ir::OpType | op_type, | ||
| std::vector< std::string > & | inputs, | ||
| std::vector< std::string > & | outputs | ||
| ) |
| Op* nndeploy::op::createOp | ( | base::DeviceType | device_type, |
| const std::string & | name, | ||
| ir::OpType | op_type, | ||
| std::vector< std::string > & | inputs, | ||
| std::vector< std::string > & | outputs, | ||
| std::shared_ptr< base::Param > | param | ||
| ) |
| Op* nndeploy::op::createOp | ( | base::DeviceType | device_type, |
| std::shared_ptr< ir::OpDesc > | op_desc | ||
| ) |
| std::shared_ptr<Op> nndeploy::op::createOpSharedPtr | ( | base::DeviceType | device_type, |
| const std::string & | name, | ||
| ir::OpType | op_type | ||
| ) |
| std::shared_ptr<Op> nndeploy::op::createOpSharedPtr | ( | base::DeviceType | device_type, |
| const std::string & | name, | ||
| ir::OpType | op_type, | ||
| std::initializer_list< std::string > | inputs, | ||
| std::initializer_list< std::string > | outputs | ||
| ) |
| std::shared_ptr<Op> nndeploy::op::createOpSharedPtr | ( | base::DeviceType | device_type, |
| const std::string & | name, | ||
| ir::OpType | op_type, | ||
| std::vector< std::string > & | inputs, | ||
| std::vector< std::string > & | outputs | ||
| ) |
| std::shared_ptr<Op> nndeploy::op::createOpSharedPtr | ( | base::DeviceType | device_type, |
| const std::string & | name, | ||
| ir::OpType | op_type, | ||
| std::vector< std::string > & | inputs, | ||
| std::vector< std::string > & | outputs, | ||
| std::shared_ptr< base::Param > | param | ||
| ) |
| std::shared_ptr<Op> nndeploy::op::createOpSharedPtr | ( | base::DeviceType | device_type, |
| std::shared_ptr< ir::OpDesc > | op_desc | ||
| ) |
| base::Status nndeploy::op::dequantizeLinear | ( | device::Tensor * | input, |
| device::Tensor * | scale, | ||
| device::Tensor * | zero_point, | ||
| std::shared_ptr< ir::DequantizeLinearParam > | param, | ||
| device::Tensor * | output | ||
| ) |
| base::Status nndeploy::op::div | ( | device::Tensor * | input1, |
| device::Tensor * | input2, | ||
| device::Tensor * | output | ||
| ) |
| base::Status nndeploy::op::embedding | ( | device::Tensor * | input, |
| device::Tensor * | indice, | ||
| device::Tensor * | output | ||
| ) |
| base::Status nndeploy::op::equal | ( | device::Tensor * | input_a, |
| device::Tensor * | input_b, | ||
| device::Tensor * | output | ||
| ) |
| base::Status nndeploy::op::erf | ( | device::Tensor * | input, |
| device::Tensor * | output | ||
| ) |
| base::Status nndeploy::op::exp | ( | device::Tensor * | input, |
| device::Tensor * | output | ||
| ) |
| base::Status nndeploy::op::expand | ( | device::Tensor * | input, |
| device::Tensor * | shape, | ||
| device::Tensor * | output | ||
| ) |
| std::string nndeploy::op::exprTypeToString | ( | ExprType | type | ) |
| base::Status nndeploy::op::flatten | ( | device::Tensor * | inputs, |
| std::shared_ptr< ir::FlattenParam > | param, | ||
| device::Tensor * | output | ||
| ) |
| base::Status nndeploy::op::floor | ( | device::Tensor * | input, |
| device::Tensor * | output | ||
| ) |
| base::Status nndeploy::op::gather | ( | device::Tensor * | input, |
| device::Tensor * | index, | ||
| std::shared_ptr< ir::GatherParam > | param, | ||
| device::Tensor * | output | ||
| ) |
| base::Status nndeploy::op::gelu | ( | device::Tensor * | input, |
| device::Tensor * | output | ||
| ) |
| base::Status nndeploy::op::gemm | ( | device::Tensor * | inputs_a, |
| device::Tensor * | inputs_b, | ||
| device::Tensor * | inputs_c, | ||
| std::shared_ptr< ir::GemmParam > | param, | ||
| device::Tensor * | output | ||
| ) |
| std::map<base::DeviceTypeCode, std::map<ir::OpType, std::shared_ptr<OpCreator> > >& nndeploy::op::getGlobalOpCreatorMap | ( | ) |
Get the Global Op Creator Map object.
| base::Status nndeploy::op::globalAveragepool | ( | device::Tensor * | input, |
| device::Tensor * | output | ||
| ) |
| base::Status nndeploy::op::hardsigmoid | ( | device::Tensor * | input, |
| device::Tensor * | output | ||
| ) |
| base::Status nndeploy::op::log | ( | device::Tensor * | input, |
| device::Tensor * | output | ||
| ) |
| std::shared_ptr<Expr> nndeploy::op::makeAdd | ( | ir::ModelDesc * | model_desc, |
| std::shared_ptr< Expr > | input_0, | ||
| std::shared_ptr< Expr > | input_1, | ||
| std::string | op_name = "", |
||
| std::string | output_name = "" |
||
| ) |
| std::shared_ptr<Expr> nndeploy::op::makeBatchNorm | ( | ir::ModelDesc * | model_desc, |
| std::shared_ptr< Expr > | input, | ||
| std::shared_ptr< ir::BatchNormalizationParam > | param, | ||
| const std::string & | scale, | ||
| const std::string & | bias, | ||
| const std::string & | mean, | ||
| const std::string & | var, | ||
| std::string | op_name = "", |
||
| std::string | output_name = "" |
||
| ) |
| std::shared_ptr<Expr> nndeploy::op::makeBlock | ( | ir::ModelDesc * | model_desc, |
| std::shared_ptr< ir::ModelDesc > | model_block | ||
| ) |
| std::shared_ptr<Expr> nndeploy::op::makeConstant | ( | ir::ModelDesc * | model_desc, |
| std::string | name | ||
| ) |
| std::shared_ptr<Expr> nndeploy::op::makeConv | ( | ir::ModelDesc * | model_desc, |
| std::shared_ptr< Expr > | input, | ||
| std::shared_ptr< ir::ConvParam > | param, | ||
| const std::string & | weight, | ||
| const std::string & | bias = "", |
||
| std::string | op_name = "", |
||
| std::string | output_name = "" |
||
| ) |
| std::shared_ptr<Expr> nndeploy::op::makeEmbedding | ( | ir::ModelDesc * | model_desc, |
| std::shared_ptr< Expr > | indices, | ||
| std::string | op_name, | ||
| std::string | output_name | ||
| ) |
| std::shared_ptr<Expr> nndeploy::op::makeFlatten | ( | ir::ModelDesc * | model_desc, |
| std::shared_ptr< Expr > | input, | ||
| std::shared_ptr< ir::FlattenParam > | param, | ||
| std::string | op_name = "", |
||
| std::string | output_name = "" |
||
| ) |
| std::shared_ptr<Expr> nndeploy::op::makeGemm | ( | ir::ModelDesc * | model_desc, |
| std::shared_ptr< Expr > | input, | ||
| std::shared_ptr< ir::GemmParam > | param, | ||
| const std::string & | weight, | ||
| const std::string & | bias = "", |
||
| std::string | op_name = "", |
||
| std::string | output_name = "" |
||
| ) |
| std::shared_ptr<Expr> nndeploy::op::makeGlobalAveragePool | ( | ir::ModelDesc * | model_desc, |
| std::shared_ptr< Expr > | input, | ||
| std::string | op_name = "", |
||
| std::string | output_name = "" |
||
| ) |
| std::shared_ptr<Expr> nndeploy::op::makeInput | ( | ir::ModelDesc * | model_desc, |
| std::string | name, | ||
| base::DataType | data_type = base::dataTypeOf< float >(), |
||
| base::IntVector | shape = base::IntVector() |
||
| ) |
一系列创建函数
| std::shared_ptr<Expr> nndeploy::op::makeMaxPool | ( | ir::ModelDesc * | model_desc, |
| std::shared_ptr< Expr > | input, | ||
| std::shared_ptr< ir::MaxPoolParam > | param, | ||
| std::string | op_name = "", |
||
| std::string | output_name = "" |
||
| ) |
| void nndeploy::op::makeOutput | ( | ir::ModelDesc * | model_desc, |
| std::shared_ptr< Expr > | expr | ||
| ) |
| std::shared_ptr<Expr> nndeploy::op::makeRelu | ( | ir::ModelDesc * | model_desc, |
| std::shared_ptr< Expr > | input, | ||
| std::string | op_name = "", |
||
| std::string | output_name = "" |
||
| ) |
| std::shared_ptr<Expr> nndeploy::op::makeSigmoid | ( | ir::ModelDesc * | model_desc, |
| std::shared_ptr< Expr > | input, | ||
| std::string | op_name = "", |
||
| std::string | output_name = "" |
||
| ) |
| std::shared_ptr<Expr> nndeploy::op::makeSoftmax | ( | ir::ModelDesc * | model_desc, |
| std::shared_ptr< Expr > | input, | ||
| std::shared_ptr< ir::SoftmaxParam > | param, | ||
| std::string | op_name = "", |
||
| std::string | output_name = "" |
||
| ) |
| base::Status nndeploy::op::matmul | ( | device::Tensor * | inputs_a, |
| device::Tensor * | inputs_b, | ||
| std::shared_ptr< ir::MatMulParam > | param, | ||
| device::Tensor * | output | ||
| ) |
| base::Status nndeploy::op::matmul | ( | device::Tensor * | inputs_a, |
| device::Tensor * | inputs_b, | ||
| std::shared_ptr< ir::MatMulParam > | param, | ||
| device::Tensor * | output, | ||
| device::Tensor * | inputs_bias | ||
| ) |
| base::Status nndeploy::op::maxPool | ( | device::Tensor * | input, |
| std::shared_ptr< ir::MaxPoolParam > | param, | ||
| device::Tensor * | output | ||
| ) |
| base::Status nndeploy::op::mul | ( | device::Tensor * | input1, |
| device::Tensor * | input2, | ||
| device::Tensor * | output | ||
| ) |
| base::Status nndeploy::op::muls | ( | device::Tensor * | scale, |
| device::Tensor * | input, | ||
| device::Tensor * | output | ||
| ) |
| int32_t nndeploy::op::multiplyDims | ( | const base::IntVector & | shape, |
| int | from, | ||
| int | upto_exclusive | ||
| ) |
| base::Status nndeploy::op::neg | ( | device::Tensor * | input, |
| device::Tensor * | output | ||
| ) |
| base::Status nndeploy::op::pow | ( | device::Tensor * | input, |
| device::Tensor * | exponent, | ||
| device::Tensor * | output | ||
| ) |
| base::Status nndeploy::op::qLinearConv | ( | device::Tensor * | x, |
| device::Tensor * | x_scale, | ||
| device::Tensor * | x_zero_point, | ||
| device::Tensor * | w, | ||
| device::Tensor * | w_scale, | ||
| device::Tensor * | w_zero_point, | ||
| device::Tensor * | y_scale, | ||
| device::Tensor * | y_zero_point, | ||
| device::Tensor * | B, | ||
| std::shared_ptr< ir::QLinearConvParam > | param, | ||
| device::Tensor * | output | ||
| ) |
| base::Status nndeploy::op::quantizeLinear | ( | device::Tensor * | input, |
| device::Tensor * | scale, | ||
| device::Tensor * | zero_point, | ||
| std::shared_ptr< ir::QuantizeLinearParam > | param, | ||
| device::Tensor * | output | ||
| ) |
| base::Status nndeploy::op::reciprocal | ( | device::Tensor * | input, |
| device::Tensor * | output | ||
| ) |
| base::Status nndeploy::op::reduceMean | ( | device::Tensor * | input, |
| device::Tensor * | axes, | ||
| std::shared_ptr< ir::ReduceMeanParam > | param, | ||
| device::Tensor * | output | ||
| ) |
| base::Status nndeploy::op::relu | ( | device::Tensor * | input, |
| device::Tensor * | output | ||
| ) |
| base::Status nndeploy::op::reshape | ( | device::Tensor * | input, |
| device::Tensor * | shape, | ||
| std::shared_ptr< ir::ReshapeParam > | param, | ||
| device::Tensor * | output | ||
| ) |
| base::Status nndeploy::op::resize | ( | device::Tensor * | input, |
| device::Tensor * | roi, | ||
| device::Tensor * | scales, | ||
| device::Tensor * | sizes, | ||
| std::shared_ptr< ir::ResizeParam > | param, | ||
| device::Tensor * | output | ||
| ) |
| base::Status nndeploy::op::rmsNorm | ( | device::Tensor * | input, |
| device::Tensor * | weight, | ||
| std::shared_ptr< base::Param > | param, | ||
| device::Tensor * | output | ||
| ) |
| base::Status nndeploy::op::round | ( | device::Tensor * | input, |
| device::Tensor * | output | ||
| ) |
| base::Status nndeploy::op::selu | ( | device::Tensor * | input, |
| device::Tensor * | output | ||
| ) |
| base::Status nndeploy::op::shape | ( | device::Tensor * | input, |
| std::shared_ptr< ir::ShapeParam > | param, | ||
| device::Tensor * | output | ||
| ) |
| base::Status nndeploy::op::sigmoid | ( | device::Tensor * | input, |
| device::Tensor * | output | ||
| ) |
| base::Status nndeploy::op::sign | ( | device::Tensor * | input, |
| device::Tensor * | output | ||
| ) |
| base::Status nndeploy::op::sin | ( | device::Tensor * | input, |
| device::Tensor * | output | ||
| ) |
| base::Status nndeploy::op::sinh | ( | device::Tensor * | input, |
| device::Tensor * | output | ||
| ) |
| base::Status nndeploy::op::slice | ( | device::Tensor * | input, |
| device::Tensor * | starts, | ||
| device::Tensor * | ends, | ||
| device::Tensor * | axes, | ||
| device::Tensor * | steps, | ||
| device::Tensor * | output | ||
| ) |
| base::Status nndeploy::op::softmax | ( | device::Tensor * | input, |
| std::shared_ptr< ir::SoftmaxParam > | param, | ||
| device::Tensor * | output | ||
| ) |
| base::Status nndeploy::op::split | ( | device::Tensor * | input, |
| device::Tensor * | section, | ||
| std::shared_ptr< ir::SplitParam > | param, | ||
| std::vector< device::Tensor * > | outputs | ||
| ) |
| base::Status nndeploy::op::sqrt | ( | device::Tensor * | input, |
| device::Tensor * | output | ||
| ) |
| ExprType nndeploy::op::stringToExprType | ( | const std::string & | src | ) |
| base::Status nndeploy::op::sub | ( | device::Tensor * | input1, |
| device::Tensor * | input2, | ||
| device::Tensor * | output | ||
| ) |
| base::Status nndeploy::op::tan | ( | device::Tensor * | input, |
| device::Tensor * | output | ||
| ) |
| base::Status nndeploy::op::tanh | ( | device::Tensor * | input, |
| device::Tensor * | output | ||
| ) |
| base::Status nndeploy::op::transpose | ( | device::Tensor * | input, |
| std::shared_ptr< ir::TransposeParam > | param, | ||
| device::Tensor * | output | ||
| ) |
| base::Status nndeploy::op::unsqueeze | ( | device::Tensor * | input, |
| device::Tensor * | axes, | ||
| device::Tensor * | output | ||
| ) |
| base::Status nndeploy::op::where | ( | device::Tensor * | input1, |
| device::Tensor * | input2, | ||
| device::Tensor * | condition, | ||
| device::Tensor * | output | ||
| ) |