8 #ifndef MXNET_CPP_OP_H_ 9 #define MXNET_CPP_OP_H_ 17 #include "dmlc/optional.h" 63 const std::vector<Symbol>& args) {
66 .CreateSymbol(symbol_name);
85 const std::vector<Symbol>& data,
86 const std::string& op_type) {
89 .CreateSymbol(symbol_name);
150 return Operator(
"broadcast_maximum")
183 return Operator(
"broadcast_minimum")
307 bool keep_highest =
false) {
311 .
SetParam(
"target_shape", target_shape)
312 .
SetParam(
"keep_highest", keep_highest)
530 dmlc::optional<int> end) {
693 dmlc::optional<int> axis = dmlc::optional<int>()) {
811 const std::vector<Symbol>& data,
818 .CreateSymbol(symbol_name);
844 const std::vector<Symbol>& data,
845 dmlc::optional<Shape> axis = dmlc::optional<Shape>()) {
849 .CreateSymbol(symbol_name);
1214 const std::vector<Symbol>& args) {
1217 .CreateSymbol(symbol_name);
1253 dmlc::optional<int> axis = dmlc::optional<int>(),
1254 bool keepdims =
false) {
1295 dmlc::optional<int> axis = dmlc::optional<int>(),
1296 bool keepdims =
false) {
1401 dmlc::optional<int> axis = dmlc::optional<int>(-1),
1402 bool keepdims =
false,
1404 static const char *PickModeValues[] = {
1411 .
SetParam(
"mode", PickModeValues[
int(mode)])
1489 bool transpose_a =
false,
1490 bool transpose_b =
false,
1492 static const char *DotForwardStypeValues[] = {
1499 .
SetParam(
"transpose_a", transpose_a)
1500 .
SetParam(
"transpose_b", transpose_b)
1501 .
SetParam(
"forward_stype", DotForwardStypeValues[
int(forward_stype)])
1546 bool transpose_a =
false,
1547 bool transpose_b =
false,
1549 static const char *Batch_dotForwardStypeValues[] = {
1556 .
SetParam(
"transpose_a", transpose_a)
1557 .
SetParam(
"transpose_b", transpose_b)
1558 .
SetParam(
"forward_stype", Batch_dotForwardStypeValues[
int(forward_stype)])
1799 dmlc::optional<int> lhs_begin = dmlc::optional<int>(),
1800 dmlc::optional<int> lhs_end = dmlc::optional<int>(),
1801 dmlc::optional<int> rhs_begin = dmlc::optional<int>(),
1802 dmlc::optional<int> rhs_end = dmlc::optional<int>()) {
1867 static const char *CastDtypeValues[] = {
1877 .
SetParam(
"dtype", CastDtypeValues[
int(dtype)])
2548 dmlc::optional<Shape> axis = dmlc::optional<Shape>(),
2549 bool keepdims =
false,
2550 bool exclude =
false) {
2585 dmlc::optional<Shape> axis = dmlc::optional<Shape>(),
2586 bool keepdims =
false,
2587 bool exclude =
false) {
2622 dmlc::optional<Shape> axis = dmlc::optional<Shape>(),
2623 bool keepdims =
false,
2624 bool exclude =
false) {
2661 dmlc::optional<Shape> axis = dmlc::optional<Shape>(),
2662 bool keepdims =
false,
2663 bool exclude =
false) {
2700 dmlc::optional<Shape> axis = dmlc::optional<Shape>(),
2701 bool keepdims =
false,
2702 bool exclude =
false) {
2737 dmlc::optional<Shape> axis = dmlc::optional<Shape>(),
2738 bool keepdims =
false,
2739 bool exclude =
false) {
2774 dmlc::optional<Shape> axis = dmlc::optional<Shape>(),
2775 bool keepdims =
false,
2776 bool exclude =
false) {
2941 dmlc::optional<Shape> axis = dmlc::optional<Shape>(),
2942 bool keepdims =
false) {
3018 dmlc::optional<int> axis = dmlc::optional<int>(-1),
3021 bool is_ascend =
false,
3023 static const char *TopkRetTypValues[] = {
3029 static const char *TopkDtypeValues[] = {
3039 .
SetParam(
"ret_typ", TopkRetTypValues[
int(ret_typ)])
3041 .
SetParam(
"dtype", TopkDtypeValues[
int(dtype)])
3080 dmlc::optional<int> axis = dmlc::optional<int>(-1),
3081 bool is_ascend =
true) {
3134 dmlc::optional<int> axis = dmlc::optional<int>(-1),
3135 bool is_ascend =
true,
3137 static const char *ArgsortDtypeValues[] = {
3147 .
SetParam(
"dtype", ArgsortDtypeValues[
int(dtype)])
3336 bool sparse_grad =
false) {
3337 static const char *EmbeddingDtypeValues[] = {
3348 .
SetParam(
"output_dim", output_dim)
3349 .
SetParam(
"dtype", EmbeddingDtypeValues[
int(dtype)])
3350 .
SetParam(
"sparse_grad", sparse_grad)
3424 static const char *TakeModeValues[] = {
3431 .
SetParam(
"mode", TakeModeValues[
int(mode)])
3533 double on_value = 1,
3534 double off_value = 0,
3536 static const char *One_hotDtypeValues[] = {
3549 .
SetParam(
"dtype", One_hotDtypeValues[
int(dtype)])
3712 return Operator(
"broadcast_not_equal")
3743 return Operator(
"broadcast_greater")
3774 return Operator(
"broadcast_greater_equal")
3805 return Operator(
"broadcast_lesser")
3836 return Operator(
"broadcast_lesser_equal")
3867 return Operator(
"broadcast_logical_and")
3898 return Operator(
"broadcast_logical_or")
3929 return Operator(
"broadcast_logical_xor")
3980 dmlc::optional<int> k = dmlc::optional<int>(0)) {
4123 static const char *Cast_storageStypeValues[] = {
4129 .
SetParam(
"stype", Cast_storageStypeValues[
int(stype)])
4578 bool global_pool =
false,
4579 bool cudnn_off =
false,
4583 dmlc::optional<int> p_value = dmlc::optional<int>(),
4584 dmlc::optional<bool> count_include_pad = dmlc::optional<bool>()) {
4585 static const char *PoolingPoolTypeValues[] = {
4591 static const char *PoolingPoolingConventionValues[] = {
4597 .
SetParam(
"pool_type", PoolingPoolTypeValues[
int(pool_type)])
4598 .
SetParam(
"global_pool", global_pool)
4600 .
SetParam(
"pooling_convention", PoolingPoolingConventionValues[
int(pooling_convention)])
4604 .
SetParam(
"count_include_pad", count_include_pad)
4644 dmlc::optional<double> temperature = dmlc::optional<double>()) {
4647 .
SetParam(
"temperature", temperature)
4678 dmlc::optional<double> temperature = dmlc::optional<double>()) {
4681 .
SetParam(
"temperature", temperature)
4740 uint32_t num_filter,
4746 uint32_t num_group = 1,
4747 uint64_t workspace = 512,
4748 bool no_bias =
true,
4750 bool cudnn_off =
false,
4752 static const char *DeconvolutionCudnnTuneValues[] = {
4755 "limited_workspace",
4758 static const char *DeconvolutionLayoutValues[] = {
4768 .
SetParam(
"num_filter", num_filter)
4773 .
SetParam(
"target_shape", target_shape)
4777 .
SetParam(
"cudnn_tune", DeconvolutionCudnnTuneValues[
int(cudnn_tune)])
4779 .
SetParam(
"layout", DeconvolutionLayoutValues[
int(layout)])
4818 static const char *ActivationActTypeValues[] = {
4826 .
SetParam(
"act_type", ActivationActTypeValues[
int(act_type)])
4908 bool fix_gamma =
true,
4909 bool use_global_stats =
false,
4910 bool output_mean_var =
false,
4912 bool cudnn_off =
false) {
4917 .
SetParam(
"use_global_stats", use_global_stats)
4918 .
SetParam(
"output_mean_var", output_mean_var)
4924 .
SetInput(
"moving_mean", moving_mean)
4925 .
SetInput(
"moving_var", moving_var)
5052 uint32_t num_filter,
5056 uint32_t num_group = 1,
5057 uint64_t workspace = 1024,
5058 bool no_bias =
false,
5060 bool cudnn_off =
false,
5062 static const char *ConvolutionCudnnTuneValues[] = {
5065 "limited_workspace",
5068 static const char *ConvolutionLayoutValues[] = {
5078 .
SetParam(
"num_filter", num_filter)
5085 .
SetParam(
"cudnn_tune", ConvolutionCudnnTuneValues[
int(cudnn_tune)])
5087 .
SetParam(
"layout", ConvolutionLayoutValues[
int(layout)])
5125 const std::vector<Symbol>& data,
5129 uint32_t num_filter = 0,
5131 uint64_t workspace = 512) {
5132 static const char *UpSamplingSampleTypeValues[] = {
5136 static const char *UpSamplingMultiInputModeValues[] = {
5142 .
SetParam(
"sample_type", UpSamplingSampleTypeValues[
int(sample_type)])
5144 .
SetParam(
"num_filter", num_filter)
5145 .
SetParam(
"multi_input_mode", UpSamplingMultiInputModeValues[
int(multi_input_mode)])
5148 .CreateSymbol(symbol_name);
5198 const std::vector<Symbol>& data,
5205 .CreateSymbol(symbol_name);
5252 bool output_mean_var =
false) {
5256 .
SetParam(
"output_mean_var", output_mean_var)
5357 static const char *DropoutModeValues[] = {
5363 .
SetParam(
"mode", DropoutModeValues[
int(mode)])
5413 static const char *SoftmaxActivationModeValues[] = {
5417 return Operator(
"SoftmaxActivation")
5418 .
SetParam(
"mode", SoftmaxActivationModeValues[
int(mode)])
5471 bool no_bias =
false,
5472 bool flatten =
true) {
5474 .
SetParam(
"num_hidden", num_hidden)
5592 double constant_value = 0) {
5593 static const char *PadModeValues[] = {
5599 .
SetParam(
"mode", PadModeValues[
int(mode)])
5601 .
SetParam(
"constant_value", constant_value)
5653 static const char *LeakyReLUActTypeValues[] = {
5661 .
SetParam(
"act_type", LeakyReLUActTypeValues[
int(act_type)])
5663 .
SetParam(
"lower_bound", lower_bound)
5664 .
SetParam(
"upper_bound", upper_bound)
5701 uint32_t dim2 = 0) {
5775 bool fix_gamma =
true,
5776 bool use_global_stats =
false,
5777 bool output_mean_var =
false) {
5782 .
SetParam(
"use_global_stats", use_global_stats)
5783 .
SetParam(
"output_mean_var", output_mean_var)
5830 return Operator(
"softmax_cross_entropy")
5869 return Operator(
"LinearRegressionOutput")
5870 .
SetParam(
"grad_scale", grad_scale)
5910 return Operator(
"MAERegressionOutput")
5911 .
SetParam(
"grad_scale", grad_scale)
5957 return Operator(
"LogisticRegressionOutput")
5958 .
SetParam(
"grad_scale", grad_scale)
5978 return Operator(
"IdentityAttachKLSparseReg")
5979 .
SetParam(
"sparseness_target", sparseness_target)
6024 .
SetParam(
"rescale_grad", rescale_grad)
6025 .
SetParam(
"clip_gradient", clip_gradient)
6079 .
SetParam(
"rescale_grad", rescale_grad)
6080 .
SetParam(
"clip_gradient", clip_gradient)
6123 bool lazy_update =
true) {
6127 .
SetParam(
"rescale_grad", rescale_grad)
6128 .
SetParam(
"clip_gradient", clip_gradient)
6129 .
SetParam(
"lazy_update", lazy_update)
6188 bool lazy_update =
true) {
6193 .
SetParam(
"rescale_grad", rescale_grad)
6194 .
SetParam(
"clip_gradient", clip_gradient)
6195 .
SetParam(
"lazy_update", lazy_update)
6225 bool lazy_update =
true) {
6229 .
SetParam(
"rescale_grad", rescale_grad)
6230 .
SetParam(
"clip_gradient", clip_gradient)
6231 .
SetParam(
"lazy_update", lazy_update)
6265 bool lazy_update =
true) {
6266 return Operator(
"mp_sgd_mom_update")
6270 .
SetParam(
"rescale_grad", rescale_grad)
6271 .
SetParam(
"clip_gradient", clip_gradient)
6272 .
SetParam(
"lazy_update", lazy_update)
6325 double epsilon = 1e-08,
6336 .
SetParam(
"rescale_grad", rescale_grad)
6407 bool lazy_update =
true) {
6414 .
SetParam(
"rescale_grad", rescale_grad)
6415 .
SetParam(
"clip_gradient", clip_gradient)
6416 .
SetParam(
"lazy_update", lazy_update)
6493 .
SetParam(
"rescale_grad", rescale_grad)
6494 .
SetParam(
"clip_gradient", clip_gradient)
6495 .
SetParam(
"clip_weights", clip_weights)
6561 return Operator(
"rmspropalex_update")
6567 .
SetParam(
"rescale_grad", rescale_grad)
6568 .
SetParam(
"clip_gradient", clip_gradient)
6569 .
SetParam(
"clip_weights", clip_weights)
6633 .
SetParam(
"rescale_grad", rescale_grad)
6634 .
SetParam(
"clip_gradient", clip_gradient)
6717 bool squeeze_axis =
false) {
6719 .
SetParam(
"num_outputs", num_outputs)
6721 .
SetParam(
"squeeze_axis", squeeze_axis)
6811 static const char *GridGeneratorTransformTypeValues[] = {
6816 .
SetParam(
"transform_type", GridGeneratorTransformTypeValues[
int(transform_type)])
6817 .
SetParam(
"target_shape", target_shape)
6892 bool global_pool =
false,
6896 static const char *Pooling_v1PoolTypeValues[] = {
6901 static const char *Pooling_v1PoolingConventionValues[] = {
6907 .
SetParam(
"pool_type", Pooling_v1PoolTypeValues[
int(pool_type)])
6908 .
SetParam(
"global_pool", global_pool)
6909 .
SetParam(
"pooling_convention", Pooling_v1PoolingConventionValues[
int(pooling_convention)])
6996 uint32_t state_size,
6997 uint32_t num_layers,
6999 bool bidirectional =
false,
7001 bool state_outputs =
false,
7002 dmlc::optional<int> projection_size = dmlc::optional<int>(),
7003 dmlc::optional<double> lstm_state_clip_min = dmlc::optional<double>(),
7004 dmlc::optional<double> lstm_state_clip_max = dmlc::optional<double>(),
7005 bool lstm_state_clip_nan =
false) {
7006 static const char *RNNModeValues[] = {
7013 .
SetParam(
"state_size", state_size)
7014 .
SetParam(
"num_layers", num_layers)
7015 .
SetParam(
"mode", RNNModeValues[
int(mode)])
7016 .
SetParam(
"bidirectional", bidirectional)
7018 .
SetParam(
"state_outputs", state_outputs)
7019 .
SetParam(
"projection_size", projection_size)
7020 .
SetParam(
"lstm_state_clip_min", lstm_state_clip_min)
7021 .
SetParam(
"lstm_state_clip_max", lstm_state_clip_max)
7022 .
SetParam(
"lstm_state_clip_nan", lstm_state_clip_nan)
7024 .
SetInput(
"parameters", parameters)
7026 .
SetInput(
"state_cell", state_cell)
7092 uint32_t num_filter,
7096 uint32_t num_group = 1,
7097 uint64_t workspace = 1024,
7098 bool no_bias =
false,
7100 bool cudnn_off =
false,
7102 static const char *Convolution_v1CudnnTuneValues[] = {
7105 "limited_workspace",
7108 static const char *Convolution_v1LayoutValues[] = {
7117 .
SetParam(
"num_filter", num_filter)
7124 .
SetParam(
"cudnn_tune", Convolution_v1CudnnTuneValues[
int(cudnn_tune)])
7126 .
SetParam(
"layout", Convolution_v1LayoutValues[
int(layout)])
7154 const std::vector<Symbol>& data,
7158 bool center_crop =
false) {
7163 .
SetParam(
"center_crop", center_crop)
7165 .CreateSymbol(symbol_name);
7247 bool use_sequence_length =
false,
7250 .
SetParam(
"use_sequence_length", use_sequence_length)
7253 .
SetInput(
"sequence_length", sequence_length)
7285 static const char *SpatialTransformerTransformTypeValues[] = {
7288 static const char *SpatialTransformerSamplerTypeValues[] = {
7291 return Operator(
"SpatialTransformer")
7292 .
SetParam(
"transform_type", SpatialTransformerTransformTypeValues[
int(transform_type)])
7293 .
SetParam(
"sampler_type", SpatialTransformerSamplerTypeValues[
int(sampler_type)])
7294 .
SetParam(
"target_shape", target_shape)
7408 bool multi_output =
false,
7409 bool use_ignore =
false,
7410 bool preserve_shape =
false,
7412 bool out_grad =
false,
7414 static const char *SoftmaxOutputNormalizationValues[] = {
7420 .
SetParam(
"grad_scale", grad_scale)
7421 .
SetParam(
"ignore_label", ignore_label)
7422 .
SetParam(
"multi_output", multi_output)
7423 .
SetParam(
"use_ignore", use_ignore)
7424 .
SetParam(
"preserve_shape", preserve_shape)
7425 .
SetParam(
"normalization", SoftmaxOutputNormalizationValues[
int(normalization)])
7427 .
SetParam(
"smooth_alpha", smooth_alpha)
7472 bool multi_output =
false,
7473 bool use_ignore =
false,
7474 bool preserve_shape =
false,
7476 bool out_grad =
false,
7478 static const char *SoftmaxNormalizationValues[] = {
7484 .
SetParam(
"grad_scale", grad_scale)
7485 .
SetParam(
"ignore_label", ignore_label)
7486 .
SetParam(
"multi_output", multi_output)
7487 .
SetParam(
"use_ignore", use_ignore)
7488 .
SetParam(
"preserve_shape", preserve_shape)
7489 .
SetParam(
"normalization", SoftmaxNormalizationValues[
int(normalization)])
7491 .
SetParam(
"smooth_alpha", smooth_alpha)
7647 .
SetParam(
"pooled_size", pooled_size)
7648 .
SetParam(
"spatial_scale", spatial_scale)
7712 bool use_sequence_length =
false,
7715 .
SetParam(
"use_sequence_length", use_sequence_length)
7718 .
SetInput(
"sequence_length", sequence_length)
7796 static const char *L2NormalizationModeValues[] = {
7803 .
SetParam(
"mode", L2NormalizationModeValues[
int(mode)])
7857 static const char *MakeLossNormalizationValues[] = {
7863 .
SetParam(
"grad_scale", grad_scale)
7864 .
SetParam(
"valid_thresh", valid_thresh)
7865 .
SetParam(
"normalization", MakeLossNormalizationValues[
int(normalization)])
7889 mx_float regularization_coefficient = 1,
7890 bool use_linear =
false) {
7893 .
SetParam(
"regularization_coefficient", regularization_coefficient)
7894 .
SetParam(
"use_linear", use_linear)
7952 uint32_t kernel_size = 1,
7953 uint32_t max_displacement = 1,
7954 uint32_t stride1 = 1,
7955 uint32_t stride2 = 1,
7956 uint32_t pad_size = 0,
7957 bool is_multiply =
true) {
7959 .
SetParam(
"kernel_size", kernel_size)
7960 .
SetParam(
"max_displacement", max_displacement)
7964 .
SetParam(
"is_multiply", is_multiply)
8051 bool use_sequence_length =
false,
8055 .
SetParam(
"use_sequence_length", use_sequence_length)
8059 .
SetInput(
"sequence_length", sequence_length)
8074 return Operator(
"choose_element_0index")
8093 return Operator(
"fill_element_0index")
8160 const std::string& op_type) {
8220 return Operator(
"broadcast_maximum")
8251 return Operator(
"broadcast_minimum")
8371 bool keep_highest =
false) {
8375 .
SetParam(
"target_shape", target_shape)
8376 .
SetParam(
"keep_highest", keep_highest)
8584 dmlc::optional<int> end) {
8659 .
SetInput(
"shape_like", shape_like)
8741 dmlc::optional<int> axis = dmlc::optional<int>()) {
8885 dmlc::optional<Shape> axis = dmlc::optional<Shape>()) {
8935 .
SetParam(
"block_size", block_size)
8985 .
SetParam(
"block_size", block_size)
9271 dmlc::optional<int> axis = dmlc::optional<int>(),
9272 bool keepdims =
false) {
9311 dmlc::optional<int> axis = dmlc::optional<int>(),
9312 bool keepdims =
false) {
9404 dmlc::optional<int> axis = dmlc::optional<int>(-1),
9405 bool keepdims =
false,
9407 static const char *PickModeValues[] = {
9414 .
SetParam(
"mode", PickModeValues[
int(mode)])
9479 bool transpose_a =
false,
9480 bool transpose_b =
false,
9482 static const char *DotForwardStypeValues[] = {
9489 .
SetParam(
"transpose_a", transpose_a)
9490 .
SetParam(
"transpose_b", transpose_b)
9491 .
SetParam(
"forward_stype", DotForwardStypeValues[
int(forward_stype)])
9523 bool transpose_a =
false,
9524 bool transpose_b =
false,
9526 static const char *Batch_dotForwardStypeValues[] = {
9533 .
SetParam(
"transpose_a", transpose_a)
9534 .
SetParam(
"transpose_b", transpose_b)
9535 .
SetParam(
"forward_stype", Batch_dotForwardStypeValues[
int(forward_stype)])
9760 dmlc::optional<int> lhs_begin = dmlc::optional<int>(),
9761 dmlc::optional<int> lhs_end = dmlc::optional<int>(),
9762 dmlc::optional<int> rhs_begin = dmlc::optional<int>(),
9763 dmlc::optional<int> rhs_end = dmlc::optional<int>()) {
9812 static const char *CastDtypeValues[] = {
9822 .
SetParam(
"dtype", CastDtypeValues[
int(dtype)])
10443 dmlc::optional<Shape> axis = dmlc::optional<Shape>(),
10444 bool keepdims =
false,
10445 bool exclude =
false) {
10478 dmlc::optional<Shape> axis = dmlc::optional<Shape>(),
10479 bool keepdims =
false,
10480 bool exclude =
false) {
10513 dmlc::optional<Shape> axis = dmlc::optional<Shape>(),
10514 bool keepdims =
false,
10515 bool exclude =
false) {
10550 dmlc::optional<Shape> axis = dmlc::optional<Shape>(),
10551 bool keepdims =
false,
10552 bool exclude =
false) {
10587 dmlc::optional<Shape> axis = dmlc::optional<Shape>(),
10588 bool keepdims =
false,
10589 bool exclude =
false) {
10622 dmlc::optional<Shape> axis = dmlc::optional<Shape>(),
10623 bool keepdims =
false,
10624 bool exclude =
false) {
10657 dmlc::optional<Shape> axis = dmlc::optional<Shape>(),
10658 bool keepdims =
false,
10659 bool exclude =
false) {
10816 dmlc::optional<Shape> axis = dmlc::optional<Shape>(),
10817 bool keepdims =
false) {
10869 dmlc::optional<int> axis = dmlc::optional<int>(-1),
10872 bool is_ascend =
false,
10874 static const char *TopkRetTypValues[] = {
10880 static const char *TopkDtypeValues[] = {
10890 .
SetParam(
"ret_typ", TopkRetTypValues[
int(ret_typ)])
10892 .
SetParam(
"dtype", TopkDtypeValues[
int(dtype)])
10929 dmlc::optional<int> axis = dmlc::optional<int>(-1),
10930 bool is_ascend =
true) {
10970 dmlc::optional<int> axis = dmlc::optional<int>(-1),
10971 bool is_ascend =
true,
10973 static const char *ArgsortDtypeValues[] = {
10983 .
SetParam(
"dtype", ArgsortDtypeValues[
int(dtype)])
11150 bool sparse_grad =
false) {
11151 static const char *EmbeddingDtypeValues[] = {
11162 .
SetParam(
"output_dim", output_dim)
11163 .
SetParam(
"dtype", EmbeddingDtypeValues[
int(dtype)])
11164 .
SetParam(
"sparse_grad", sparse_grad)
11226 static const char *TakeModeValues[] = {
11233 .
SetParam(
"mode", TakeModeValues[
int(mode)])
11319 double on_value = 1,
11320 double off_value = 0,
11322 static const char *One_hotDtypeValues[] = {
11335 .
SetParam(
"dtype", One_hotDtypeValues[
int(dtype)])
11461 return Operator(
"broadcast_equal")
11490 return Operator(
"broadcast_not_equal")
11519 return Operator(
"broadcast_greater")
11548 return Operator(
"broadcast_greater_equal")
11577 return Operator(
"broadcast_lesser")
11606 return Operator(
"broadcast_lesser_equal")
11635 return Operator(
"broadcast_logical_and")
11664 return Operator(
"broadcast_logical_or")
11693 return Operator(
"broadcast_logical_xor")
11742 dmlc::optional<int> k = dmlc::optional<int>(0)) {
11871 static const char *Cast_storageStypeValues[] = {
11877 .
SetParam(
"stype", Cast_storageStypeValues[
int(stype)])
12280 bool global_pool =
false,
12281 bool cudnn_off =
false,
12285 dmlc::optional<int> p_value = dmlc::optional<int>(),
12286 dmlc::optional<bool> count_include_pad = dmlc::optional<bool>()) {
12287 static const char *PoolingPoolTypeValues[] = {
12293 static const char *PoolingPoolingConventionValues[] = {
12299 .
SetParam(
"pool_type", PoolingPoolTypeValues[
int(pool_type)])
12300 .
SetParam(
"global_pool", global_pool)
12302 .
SetParam(
"pooling_convention", PoolingPoolingConventionValues[
int(pooling_convention)])
12306 .
SetParam(
"count_include_pad", count_include_pad)
12344 dmlc::optional<double> temperature = dmlc::optional<double>()) {
12347 .
SetParam(
"temperature", temperature)
12376 dmlc::optional<double> temperature = dmlc::optional<double>()) {
12379 .
SetParam(
"temperature", temperature)
12416 uint32_t num_filter,
12422 uint32_t num_group = 1,
12423 uint64_t workspace = 512,
12424 bool no_bias =
true,
12426 bool cudnn_off =
false,
12428 static const char *DeconvolutionCudnnTuneValues[] = {
12431 "limited_workspace",
12434 static const char *DeconvolutionLayoutValues[] = {
12444 .
SetParam(
"num_filter", num_filter)
12449 .
SetParam(
"target_shape", target_shape)
12453 .
SetParam(
"cudnn_tune", DeconvolutionCudnnTuneValues[
int(cudnn_tune)])
12455 .
SetParam(
"layout", DeconvolutionLayoutValues[
int(layout)])
12482 static const char *ActivationActTypeValues[] = {
12490 .
SetParam(
"act_type", ActivationActTypeValues[
int(act_type)])
12568 double eps = 0.001,
12570 bool fix_gamma =
true,
12571 bool use_global_stats =
false,
12572 bool output_mean_var =
false,
12574 bool cudnn_off =
false) {
12579 .
SetParam(
"use_global_stats", use_global_stats)
12580 .
SetParam(
"output_mean_var", output_mean_var)
12586 .
SetInput(
"moving_mean", moving_mean)
12587 .
SetInput(
"moving_var", moving_var)
12691 uint32_t num_filter,
12695 uint32_t num_group = 1,
12696 uint64_t workspace = 1024,
12697 bool no_bias =
false,
12699 bool cudnn_off =
false,
12701 static const char *ConvolutionCudnnTuneValues[] = {
12704 "limited_workspace",
12707 static const char *ConvolutionLayoutValues[] = {
12717 .
SetParam(
"num_filter", num_filter)
12724 .
SetParam(
"cudnn_tune", ConvolutionCudnnTuneValues[
int(cudnn_tune)])
12726 .
SetParam(
"layout", ConvolutionLayoutValues[
int(layout)])
12751 uint32_t num_filter = 0,
12753 uint64_t workspace = 512) {
12754 static const char *UpSamplingSampleTypeValues[] = {
12758 static const char *UpSamplingMultiInputModeValues[] = {
12764 .
SetParam(
"sample_type", UpSamplingSampleTypeValues[
int(sample_type)])
12766 .
SetParam(
"num_filter", num_filter)
12767 .
SetParam(
"multi_input_mode", UpSamplingMultiInputModeValues[
int(multi_input_mode)])
12870 bool output_mean_var =
false) {
12874 .
SetParam(
"output_mean_var", output_mean_var)
12964 static const char *DropoutModeValues[] = {
12970 .
SetParam(
"mode", DropoutModeValues[
int(mode)])
13010 static const char *SoftmaxActivationModeValues[] = {
13014 return Operator(
"SoftmaxActivation")
13015 .
SetParam(
"mode", SoftmaxActivationModeValues[
int(mode)])
13066 bool no_bias =
false,
13067 bool flatten =
true) {
13069 .
SetParam(
"num_hidden", num_hidden)
13176 double constant_value = 0) {
13177 static const char *PadModeValues[] = {
13183 .
SetParam(
"mode", PadModeValues[
int(mode)])
13185 .
SetParam(
"constant_value", constant_value)
13225 static const char *LeakyReLUActTypeValues[] = {
13233 .
SetParam(
"act_type", LeakyReLUActTypeValues[
int(act_type)])
13235 .
SetParam(
"lower_bound", lower_bound)
13236 .
SetParam(
"upper_bound", upper_bound)
13271 uint32_t dim2 = 0) {
13343 bool fix_gamma =
true,
13344 bool use_global_stats =
false,
13345 bool output_mean_var =
false) {
13350 .
SetParam(
"use_global_stats", use_global_stats)
13351 .
SetParam(
"output_mean_var", output_mean_var)
13396 return Operator(
"softmax_cross_entropy")
13433 return Operator(
"LinearRegressionOutput")
13434 .
SetParam(
"grad_scale", grad_scale)
13472 return Operator(
"MAERegressionOutput")
13473 .
SetParam(
"grad_scale", grad_scale)
13517 return Operator(
"LogisticRegressionOutput")
13518 .
SetParam(
"grad_scale", grad_scale)
13536 return Operator(
"IdentityAttachKLSparseReg")
13537 .
SetParam(
"sparseness_target", sparseness_target)
13580 .
SetParam(
"rescale_grad", rescale_grad)
13581 .
SetParam(
"clip_gradient", clip_gradient)
13633 .
SetParam(
"rescale_grad", rescale_grad)
13634 .
SetParam(
"clip_gradient", clip_gradient)
13675 bool lazy_update =
true) {
13679 .
SetParam(
"rescale_grad", rescale_grad)
13680 .
SetParam(
"clip_gradient", clip_gradient)
13681 .
SetParam(
"lazy_update", lazy_update)
13738 bool lazy_update =
true) {
13743 .
SetParam(
"rescale_grad", rescale_grad)
13744 .
SetParam(
"clip_gradient", clip_gradient)
13745 .
SetParam(
"lazy_update", lazy_update)
13773 bool lazy_update =
true) {
13777 .
SetParam(
"rescale_grad", rescale_grad)
13778 .
SetParam(
"clip_gradient", clip_gradient)
13779 .
SetParam(
"lazy_update", lazy_update)
13811 bool lazy_update =
true) {
13812 return Operator(
"mp_sgd_mom_update")
13816 .
SetParam(
"rescale_grad", rescale_grad)
13817 .
SetParam(
"clip_gradient", clip_gradient)
13818 .
SetParam(
"lazy_update", lazy_update)
13869 double epsilon = 1e-08,
13880 .
SetParam(
"rescale_grad", rescale_grad)
13949 bool lazy_update =
true) {
13956 .
SetParam(
"rescale_grad", rescale_grad)
13957 .
SetParam(
"clip_gradient", clip_gradient)
13958 .
SetParam(
"lazy_update", lazy_update)
14033 .
SetParam(
"rescale_grad", rescale_grad)
14034 .
SetParam(
"clip_gradient", clip_gradient)
14035 .
SetParam(
"clip_weights", clip_weights)
14099 return Operator(
"rmspropalex_update")
14105 .
SetParam(
"rescale_grad", rescale_grad)
14106 .
SetParam(
"clip_gradient", clip_gradient)
14107 .
SetParam(
"clip_weights", clip_weights)
14169 .
SetParam(
"rescale_grad", rescale_grad)
14170 .
SetParam(
"clip_gradient", clip_gradient)
14251 bool squeeze_axis =
false) {
14253 .
SetParam(
"num_outputs", num_outputs)
14255 .
SetParam(
"squeeze_axis", squeeze_axis)
14333 static const char *GridGeneratorTransformTypeValues[] = {
14338 .
SetParam(
"transform_type", GridGeneratorTransformTypeValues[
int(transform_type)])
14339 .
SetParam(
"target_shape", target_shape)
14397 bool global_pool =
false,
14401 static const char *Pooling_v1PoolTypeValues[] = {
14406 static const char *Pooling_v1PoolingConventionValues[] = {
14412 .
SetParam(
"pool_type", Pooling_v1PoolTypeValues[
int(pool_type)])
14413 .
SetParam(
"global_pool", global_pool)
14414 .
SetParam(
"pooling_convention", Pooling_v1PoolingConventionValues[
int(pooling_convention)])
14490 uint32_t state_size,
14491 uint32_t num_layers,
14493 bool bidirectional =
false,
14495 bool state_outputs =
false,
14496 dmlc::optional<int> projection_size = dmlc::optional<int>(),
14497 dmlc::optional<double> lstm_state_clip_min = dmlc::optional<double>(),
14498 dmlc::optional<double> lstm_state_clip_max = dmlc::optional<double>(),
14499 bool lstm_state_clip_nan =
false) {
14500 static const char *RNNModeValues[] = {
14507 .
SetParam(
"state_size", state_size)
14508 .
SetParam(
"num_layers", num_layers)
14509 .
SetParam(
"mode", RNNModeValues[
int(mode)])
14510 .
SetParam(
"bidirectional", bidirectional)
14512 .
SetParam(
"state_outputs", state_outputs)
14513 .
SetParam(
"projection_size", projection_size)
14514 .
SetParam(
"lstm_state_clip_min", lstm_state_clip_min)
14515 .
SetParam(
"lstm_state_clip_max", lstm_state_clip_max)
14516 .
SetParam(
"lstm_state_clip_nan", lstm_state_clip_nan)
14518 .
SetInput(
"parameters", parameters)
14520 .
SetInput(
"state_cell", state_cell)
14557 uint32_t num_filter,
14561 uint32_t num_group = 1,
14562 uint64_t workspace = 1024,
14563 bool no_bias =
false,
14565 bool cudnn_off =
false,
14567 static const char *Convolution_v1CudnnTuneValues[] = {
14570 "limited_workspace",
14573 static const char *Convolution_v1LayoutValues[] = {
14582 .
SetParam(
"num_filter", num_filter)
14589 .
SetParam(
"cudnn_tune", Convolution_v1CudnnTuneValues[
int(cudnn_tune)])
14591 .
SetParam(
"layout", Convolution_v1LayoutValues[
int(layout)])
14621 bool center_crop =
false) {
14626 .
SetParam(
"center_crop", center_crop)
14708 bool use_sequence_length =
false,
14710 return Operator(
"SequenceReverse")
14711 .
SetParam(
"use_sequence_length", use_sequence_length)
14714 .
SetInput(
"sequence_length", sequence_length)
14732 static const char *SpatialTransformerTransformTypeValues[] = {
14735 static const char *SpatialTransformerSamplerTypeValues[] = {
14738 return Operator(
"SpatialTransformer")
14739 .
SetParam(
"transform_type", SpatialTransformerTransformTypeValues[
int(transform_type)])
14740 .
SetParam(
"sampler_type", SpatialTransformerSamplerTypeValues[
int(sampler_type)])
14741 .
SetParam(
"target_shape", target_shape)
14845 bool multi_output =
false,
14846 bool use_ignore =
false,
14847 bool preserve_shape =
false,
14849 bool out_grad =
false,
14851 static const char *SoftmaxOutputNormalizationValues[] = {
14857 .
SetParam(
"grad_scale", grad_scale)
14858 .
SetParam(
"ignore_label", ignore_label)
14859 .
SetParam(
"multi_output", multi_output)
14860 .
SetParam(
"use_ignore", use_ignore)
14861 .
SetParam(
"preserve_shape", preserve_shape)
14862 .
SetParam(
"normalization", SoftmaxOutputNormalizationValues[
int(normalization)])
14864 .
SetParam(
"smooth_alpha", smooth_alpha)
14899 bool multi_output =
false,
14900 bool use_ignore =
false,
14901 bool preserve_shape =
false,
14903 bool out_grad =
false,
14905 static const char *SoftmaxNormalizationValues[] = {
14911 .
SetParam(
"grad_scale", grad_scale)
14912 .
SetParam(
"ignore_label", ignore_label)
14913 .
SetParam(
"multi_output", multi_output)
14914 .
SetParam(
"use_ignore", use_ignore)
14915 .
SetParam(
"preserve_shape", preserve_shape)
14916 .
SetParam(
"normalization", SoftmaxNormalizationValues[
int(normalization)])
14918 .
SetParam(
"smooth_alpha", smooth_alpha)
15004 return Operator(
"BilinearSampler")
15070 .
SetParam(
"pooled_size", pooled_size)
15071 .
SetParam(
"spatial_scale", spatial_scale)
15133 bool use_sequence_length =
false,
15136 .
SetParam(
"use_sequence_length", use_sequence_length)
15139 .
SetInput(
"sequence_length", sequence_length)
15207 static const char *L2NormalizationModeValues[] = {
15212 return Operator(
"L2Normalization")
15214 .
SetParam(
"mode", L2NormalizationModeValues[
int(mode)])
15256 static const char *MakeLossNormalizationValues[] = {
15262 .
SetParam(
"grad_scale", grad_scale)
15263 .
SetParam(
"valid_thresh", valid_thresh)
15264 .
SetParam(
"normalization", MakeLossNormalizationValues[
int(normalization)])
15286 mx_float regularization_coefficient = 1,
15287 bool use_linear =
false) {
15290 .
SetParam(
"regularization_coefficient", regularization_coefficient)
15291 .
SetParam(
"use_linear", use_linear)
15347 uint32_t kernel_size = 1,
15348 uint32_t max_displacement = 1,
15349 uint32_t stride1 = 1,
15350 uint32_t stride2 = 1,
15351 uint32_t pad_size = 0,
15352 bool is_multiply =
true) {
15354 .
SetParam(
"kernel_size", kernel_size)
15355 .
SetParam(
"max_displacement", max_displacement)
15359 .
SetParam(
"is_multiply", is_multiply)
15444 bool use_sequence_length =
false,
15448 .
SetParam(
"use_sequence_length", use_sequence_length)
15452 .
SetInput(
"sequence_length", sequence_length)
15465 return Operator(
"choose_element_0index")
15482 return Operator(
"fill_element_0index")
15491 #endif // MXNET_CPP_OP_H_ Symbol Convolution(const std::string &symbol_name, Symbol data, Symbol weight, Symbol bias, Shape kernel, uint32_t num_filter, Shape stride=Shape(), Shape dilate=Shape(), Shape pad=Shape(), uint32_t num_group=1, uint64_t workspace=1024, bool no_bias=false, ConvolutionCudnnTune cudnn_tune=ConvolutionCudnnTune::kNone, bool cudnn_off=false, ConvolutionLayout layout=ConvolutionLayout::kNone)
Definition: op.h:5047
Symbol Pooling(const std::string &symbol_name, Symbol data, Shape kernel=Shape(), PoolingPoolType pool_type=PoolingPoolType::kMax, bool global_pool=false, bool cudnn_off=false, PoolingPoolingConvention pooling_convention=PoolingPoolingConvention::kValid, Shape stride=Shape(), Shape pad=Shape(), dmlc::optional< int > p_value=dmlc::optional< int >(), dmlc::optional< bool > count_include_pad=dmlc::optional< bool >())
Definition: op.h:4574
Symbol mp_sgd_mom_update(const std::string &symbol_name, Symbol weight, Symbol grad, Symbol mom, Symbol weight32, mx_float lr, mx_float momentum=0, mx_float wd=0, mx_float rescale_grad=1, mx_float clip_gradient=-1, bool lazy_update=true)
Definition: op.h:6255
Symbol fix(const std::string &symbol_name, Symbol data)
Definition: op.h:2147
Symbol Crop(const std::string &symbol_name, const std::vector< Symbol > &data, int num_args, Shape offset=Shape(0, 0), Shape h_w=Shape(0, 0), bool center_crop=false)
Definition: op.h:7153
Symbol broadcast_mul(const std::string &symbol_name, Symbol lhs, Symbol rhs)
Definition: op.h:1116
Symbol arcsin(const std::string &symbol_name, Symbol data)
Definition: op.h:4236
Symbol FullyConnected(const std::string &symbol_name, Symbol data, Symbol weight, Symbol bias, int num_hidden, bool no_bias=false, bool flatten=true)
Definition: op.h:5466
Symbol arccosh(const std::string &symbol_name, Symbol data)
Definition: op.h:4459
Symbol arctan(const std::string &symbol_name, Symbol data)
Definition: op.h:4289
Symbol SwapAxis(const std::string &symbol_name, Symbol data, uint32_t dim1=0, uint32_t dim2=0)
Definition: op.h:5698
Symbol cast_storage(const std::string &symbol_name, Symbol data, Cast_storageStype stype)
Definition: op.h:4120
Symbol add_n(const std::string &symbol_name, const std::vector< Symbol > &args)
Definition: op.h:1213
Symbol log1p(const std::string &symbol_name, Symbol data)
Definition: op.h:2402
SoftmaxActivationMode
Definition: op.h:5372
Symbol SpatialTransformer(const std::string &symbol_name, Symbol data, Symbol loc, SpatialTransformerTransformType transform_type, SpatialTransformerSamplerType sampler_type, Shape target_shape=Shape(0, 0))
Definition: op.h:7279
Symbol argsort(const std::string &symbol_name, Symbol data, dmlc::optional< int > axis=dmlc::optional< int >(-1), bool is_ascend=true, ArgsortDtype dtype=ArgsortDtype::kFloat32)
Definition: op.h:3132
Symbol slice(const std::string &symbol_name, Symbol data, Shape begin, Shape end, Shape step=Shape())
Definition: op.h:481
Symbol exp(const std::string &symbol_name, Symbol data)
Definition: op.h:2313
Symbol transpose(const std::string &symbol_name, Symbol data, Shape axes=Shape())
Definition: op.h:393
Symbol RNN(const std::string &symbol_name, Symbol data, Symbol parameters, Symbol state, Symbol state_cell, uint32_t state_size, uint32_t num_layers, RNNMode mode, bool bidirectional=false, mx_float p=0, bool state_outputs=false, dmlc::optional< int > projection_size=dmlc::optional< int >(), dmlc::optional< double > lstm_state_clip_min=dmlc::optional< double >(), dmlc::optional< double > lstm_state_clip_max=dmlc::optional< double >(), bool lstm_state_clip_nan=false)
Definition: op.h:6991
Symbol clip(const std::string &symbol_name, Symbol data, mx_float a_min, mx_float a_max)
Definition: op.h:645
Symbol elemwise_div(const std::string &symbol_name, Symbol lhs, Symbol rhs)
Definition: op.h:3246
Symbol Embedding(const std::string &symbol_name, Symbol data, Symbol weight, int input_dim, int output_dim, EmbeddingDtype dtype=EmbeddingDtype::kFloat32, bool sparse_grad=false)
Definition: op.h:3330
Symbol ROIPooling(const std::string &symbol_name, Symbol data, Symbol rois, Shape pooled_size, mx_float spatial_scale)
Definition: op.h:7641
Symbol broadcast_div(const std::string &symbol_name, Symbol lhs, Symbol rhs)
Definition: op.h:1151
Convolution_v1Layout
Definition: op.h:7049
Symbol argmin(const std::string &symbol_name, Symbol data, dmlc::optional< int > axis=dmlc::optional< int >(), bool keepdims=false)
Definition: op.h:1293
Symbol dot(const std::string &symbol_name, Symbol lhs, Symbol rhs, bool transpose_a=false, bool transpose_b=false, DotForwardStype forward_stype=DotForwardStype::kNone)
Definition: op.h:1486
Symbol topk(const std::string &symbol_name, Symbol data, dmlc::optional< int > axis=dmlc::optional< int >(-1), int k=1, TopkRetTyp ret_typ=TopkRetTyp::kIndices, bool is_ascend=false, TopkDtype dtype=TopkDtype::kFloat32)
Definition: op.h:3016
Symbol SequenceReverse(const std::string &symbol_name, Symbol data, Symbol sequence_length, bool use_sequence_length=false, int axis=0)
Definition: op.h:7244
Symbol broadcast_lesser(const std::string &symbol_name, Symbol lhs, Symbol rhs)
Definition: op.h:3802
Symbol fill_element_0index(const std::string &symbol_name, Symbol lhs, Symbol mhs, Symbol rhs)
Definition: op.h:8089
Symbol Convolution_v1(const std::string &symbol_name, Symbol data, Symbol weight, Symbol bias, Shape kernel, uint32_t num_filter, Shape stride=Shape(), Shape dilate=Shape(), Shape pad=Shape(), uint32_t num_group=1, uint64_t workspace=1024, bool no_bias=false, Convolution_v1CudnnTune cudnn_tune=Convolution_v1CudnnTune::kNone, bool cudnn_off=false, Convolution_v1Layout layout=Convolution_v1Layout::kNone)
Definition: op.h:7087
Symbol broadcast_not_equal(const std::string &symbol_name, Symbol lhs, Symbol rhs)
Definition: op.h:3709
TakeMode
Definition: op.h:3360
Symbol SequenceLast(const std::string &symbol_name, Symbol data, Symbol sequence_length, bool use_sequence_length=false, int axis=0)
Definition: op.h:7709
Symbol ftrl_update(const std::string &symbol_name, Symbol weight, Symbol grad, Symbol z, Symbol n, mx_float lr, mx_float lamda1=0.01, mx_float beta=1, mx_float wd=0, mx_float rescale_grad=1, mx_float clip_gradient=-1)
Definition: op.h:6617
Symbol reciprocal(const std::string &symbol_name, Symbol data)
Definition: op.h:1919
TopkRetTyp
Definition: op.h:2956
namespace of mxnet
Definition: base.h:118
Symbol reshape_like(const std::string &symbol_name, Symbol lhs, Symbol rhs)
Definition: op.h:1770
Pooling_v1PoolingConvention
Definition: op.h:6832
Symbol broadcast_lesser_equal(const std::string &symbol_name, Symbol lhs, Symbol rhs)
Definition: op.h:3833
Operator & SetInput(const std::string &name, Symbol symbol)
add an input symbol
Symbol InstanceNorm(const std::string &symbol_name, Symbol data, Symbol gamma, Symbol beta, mx_float eps=0.001)
Definition: op.h:6776
Symbol sign(const std::string &symbol_name, Symbol data)
Definition: op.h:1973
GridGeneratorTransformType
Definition: op.h:6792
Cast_storageStype
Definition: op.h:4069
Symbol log_softmax(const std::string &symbol_name, Symbol data, int axis=-1, dmlc::optional< double > temperature=dmlc::optional< double >())
Definition: op.h:4675
dynamic shape class that can hold shape of arbirary dimension
Definition: shape.h:43
Symbol ones_like(const std::string &symbol_name, Symbol data)
Definition: op.h:1001
RNNMode
Definition: op.h:6918
PadMode
Definition: op.h:5486
Symbol smooth_l1(const std::string &symbol_name, Symbol data, mx_float scalar)
Definition: op.h:4058
Symbol where(const std::string &symbol_name, Symbol condition, Symbol x, Symbol y)
Definition: op.h:4022
Symbol space_to_depth(const std::string &symbol_name, Symbol data, int block_size)
Definition: op.h:945
Symbol expm1(const std::string &symbol_name, Symbol data)
Definition: op.h:2427
Symbol elemwise_add(const std::string &symbol_name, Symbol lhs, Symbol rhs)
Definition: op.h:3171
PoolingPoolType
Definition: op.h:4492
Symbol relu(const std::string &symbol_name, Symbol data)
Definition: op.h:1583
Symbol reverse(const std::string &symbol_name, Symbol data, Shape axis)
Definition: op.h:778
Symbol rsqrt(const std::string &symbol_name, Symbol data)
Definition: op.h:2233
Symbol mp_sgd_update(const std::string &symbol_name, Symbol weight, Symbol grad, Symbol weight32, mx_float lr, mx_float wd=0, mx_float rescale_grad=1, mx_float clip_gradient=-1, bool lazy_update=true)
Definition: op.h:6217
Symbol batch_dot(const std::string &symbol_name, Symbol lhs, Symbol rhs, bool transpose_a=false, bool transpose_b=false, Batch_dotForwardStype forward_stype=Batch_dotForwardStype::kNone)
Definition: op.h:1543
SpatialTransformerTransformType
Definition: op.h:7259
ActivationActType
Definition: op.h:4788
Symbol sqrt(const std::string &symbol_name, Symbol data)
Definition: op.h:2207
Symbol Softmax(const std::string &symbol_name, Symbol data, mx_float grad_scale=1, mx_float ignore_label=-1, bool multi_output=false, bool use_ignore=false, bool preserve_shape=false, SoftmaxNormalization normalization=SoftmaxNormalization::kNull, bool out_grad=false, mx_float smooth_alpha=0)
Definition: op.h:7468
Symbol rint(const std::string &symbol_name, Symbol data)
Definition: op.h:2031
Symbol IdentityAttachKLSparseReg(const std::string &symbol_name, Symbol data, mx_float sparseness_target=0.1, mx_float penalty=0.001, mx_float momentum=0.9)
Definition: op.h:5973
Symbol sinh(const std::string &symbol_name, Symbol data)
Definition: op.h:4367
Symbol scatter_nd(const std::string &symbol_name, Symbol data, Symbol indices, Shape shape)
Definition: op.h:3645
Symbol broadcast_greater_equal(const std::string &symbol_name, Symbol lhs, Symbol rhs)
Definition: op.h:3771
Symbol LRN(const std::string &symbol_name, Symbol data, uint32_t nsize, mx_float alpha=0.0001, mx_float beta=0.75, mx_float knorm=2)
Definition: op.h:5290
Symbol LayerNorm(const std::string &symbol_name, Symbol data, Symbol gamma, Symbol beta, int axis=-1, mx_float eps=1e-05, bool output_mean_var=false)
Definition: op.h:5246
Symbol arcsinh(const std::string &symbol_name, Symbol data)
Definition: op.h:4439
Symbol MAERegressionOutput(const std::string &symbol_name, Symbol data, Symbol label, mx_float grad_scale=1)
Definition: op.h:5906
Symbol SliceChannel(const std::string &symbol_name, Symbol data, int num_outputs, int axis=1, bool squeeze_axis=false)
Definition: op.h:6713
PoolingPoolingConvention
Definition: op.h:4501
Symbol broadcast_minimum(const std::string &symbol_name, Symbol lhs, Symbol rhs)
Definition: op.h:180
ArgsortDtype
Definition: op.h:3092
Symbol broadcast_maximum(const std::string &symbol_name, Symbol lhs, Symbol rhs)
Definition: op.h:147
Symbol Cast(const std::string &symbol_name, Symbol data, CastDtype dtype)
Definition: op.h:1864
DeconvolutionLayout
Definition: op.h:4697
Symbol trunc(const std::string &symbol_name, Symbol data)
Definition: op.h:2119
Pooling_v1PoolType
Definition: op.h:6824
Symbol round(const std::string &symbol_name, Symbol data)
Definition: op.h:2000
Symbol adam_update(const std::string &symbol_name, Symbol weight, Symbol grad, Symbol mean, Symbol var, mx_float lr, mx_float beta1=0.9, mx_float beta2=0.999, mx_float epsilon=1e-08, mx_float wd=0, mx_float rescale_grad=1, mx_float clip_gradient=-1, bool lazy_update=true)
Definition: op.h:6395
Symbol Dropout(const std::string &symbol_name, Symbol data, mx_float p=0.5, DropoutMode mode=DropoutMode::kTraining, Shape axes=Shape())
Definition: op.h:5352
Symbol squeeze(const std::string &symbol_name, const std::vector< Symbol > &data, dmlc::optional< Shape > axis=dmlc::optional< Shape >())
Definition: op.h:843
TopkDtype
Definition: op.h:2965
Symbol broadcast_logical_or(const std::string &symbol_name, Symbol lhs, Symbol rhs)
Definition: op.h:3895
Symbol khatri_rao(const std::string &symbol_name, const std::vector< Symbol > &args)
Definition: op.h:62
Symbol cos(const std::string &symbol_name, Symbol data)
Definition: op.h:4179
Symbol L2Normalization(const std::string &symbol_name, Symbol data, mx_float eps=1e-10, L2NormalizationMode mode=L2NormalizationMode::kInstance)
Definition: op.h:7792
Symbol max(const std::string &symbol_name, Symbol data, dmlc::optional< Shape > axis=dmlc::optional< Shape >(), bool keepdims=false, bool exclude=false)
Definition: op.h:2735
Symbol Correlation(const std::string &symbol_name, Symbol data1, Symbol data2, uint32_t kernel_size=1, uint32_t max_displacement=1, uint32_t stride1=1, uint32_t stride2=1, uint32_t pad_size=0, bool is_multiply=true)
Definition: op.h:7949
Symbol zeros_like(const std::string &symbol_name, Symbol data)
Definition: op.h:977
EmbeddingDtype
Definition: op.h:3257
Symbol broadcast_mod(const std::string &symbol_name, Symbol lhs, Symbol rhs)
Definition: op.h:1182
Symbol cbrt(const std::string &symbol_name, Symbol data)
Definition: op.h:2263
operator helper functions
Symbol broadcast_logical_and(const std::string &symbol_name, Symbol lhs, Symbol rhs)
Definition: op.h:3864
Symbol logical_not(const std::string &symbol_name, Symbol data)
Definition: op.h:2481
Symbol tanh(const std::string &symbol_name, Symbol data)
Definition: op.h:4415
Symbol broadcast_to(const std::string &symbol_name, Symbol data, Shape shape=Shape())
Definition: op.h:2853
Symbol elemwise_sub(const std::string &symbol_name, Symbol lhs, Symbol rhs)
Definition: op.h:3199
Symbol diag(const std::string &symbol_name, Symbol data, dmlc::optional< int > k=dmlc::optional< int >(0))
Definition: op.h:3978
DropoutMode
Definition: op.h:5307
Symbol norm(const std::string &symbol_name, Symbol data, int ord=2, dmlc::optional< Shape > axis=dmlc::optional< Shape >(), bool keepdims=false)
Definition: op.h:2938
Symbol MakeLoss(const std::string &symbol_name, Symbol data, mx_float grad_scale=1, mx_float valid_thresh=0, MakeLossNormalization normalization=MakeLossNormalization::kNull)
Definition: op.h:7852
Symbol log(const std::string &symbol_name, Symbol data)
Definition: op.h:2334
Symbol broadcast_logical_xor(const std::string &symbol_name, Symbol lhs, Symbol rhs)
Definition: op.h:3926
Symbol sigmoid(const std::string &symbol_name, Symbol data)
Definition: op.h:1605
CastDtype
Definition: op.h:1835
DotForwardStype
Definition: op.h:1421
ConvolutionLayout
Definition: op.h:4941
Symbol LogisticRegressionOutput(const std::string &symbol_name, Symbol data, Symbol label, mx_float grad_scale=1)
Definition: op.h:5953
Symbol gamma(const std::string &symbol_name, Symbol data)
Definition: op.h:2445
Symbol sin(const std::string &symbol_name, Symbol data)
Definition: op.h:4155
UpSamplingMultiInputMode
Definition: op.h:5104
Symbol CreateSymbol(const std::string &name="")
create a Symbol from the current operator
Symbol elemwise_mul(const std::string &symbol_name, Symbol lhs, Symbol rhs)
Definition: op.h:3226
Symbol softmax(const std::string &symbol_name, Symbol data, int axis=-1, dmlc::optional< double > temperature=dmlc::optional< double >())
Definition: op.h:4641
Batch_dotForwardStype
Definition: op.h:1511
SpatialTransformerSamplerType
Definition: op.h:7265
Symbol Pad(const std::string &symbol_name, Symbol data, PadMode mode, Shape pad_width, double constant_value=0)
Definition: op.h:5588
Symbol square(const std::string &symbol_name, Symbol data)
Definition: op.h:2177
Symbol LeakyReLU(const std::string &symbol_name, Symbol data, Symbol gamma, LeakyReLUActType act_type=LeakyReLUActType::kLeaky, mx_float slope=0.25, mx_float lower_bound=0.125, mx_float upper_bound=0.334)
Definition: op.h:5646
One_hotDtype
Definition: op.h:3476
Symbol nansum(const std::string &symbol_name, Symbol data, dmlc::optional< Shape > axis=dmlc::optional< Shape >(), bool keepdims=false, bool exclude=false)
Definition: op.h:2659
UpSamplingSampleType
Definition: op.h:5096
Symbol rmsprop_update(const std::string &symbol_name, Symbol weight, Symbol grad, Symbol n, mx_float lr, mx_float gamma1=0.95, mx_float epsilon=1e-08, mx_float wd=0, mx_float rescale_grad=1, mx_float clip_gradient=-1, mx_float clip_weights=-1)
Definition: op.h:6477
Symbol make_loss(const std::string &symbol_name, Symbol data)
Definition: op.h:1729
Symbol SoftmaxActivation(const std::string &symbol_name, Symbol data, SoftmaxActivationMode mode=SoftmaxActivationMode::kInstance)
Definition: op.h:5410
Symbol broadcast_equal(const std::string &symbol_name, Symbol lhs, Symbol rhs)
Definition: op.h:3678
Symbol nanprod(const std::string &symbol_name, Symbol data, dmlc::optional< Shape > axis=dmlc::optional< Shape >(), bool keepdims=false, bool exclude=false)
Definition: op.h:2698
Symbol Deconvolution(const std::string &symbol_name, Symbol data, Symbol weight, Symbol bias, Shape kernel, uint32_t num_filter, Shape stride=Shape(), Shape dilate=Shape(), Shape pad=Shape(), Shape adj=Shape(), Shape target_shape=Shape(), uint32_t num_group=1, uint64_t workspace=512, bool no_bias=true, DeconvolutionCudnnTune cudnn_tune=DeconvolutionCudnnTune::kNone, bool cudnn_off=false, DeconvolutionLayout layout=DeconvolutionLayout::kNone)
Definition: op.h:4735
Symbol broadcast_add(const std::string &symbol_name, Symbol lhs, Symbol rhs)
Definition: op.h:1040
Operator & SetParam(const std::string &name, const T &value)
set config parameters
Definition: operator.h:58
Symbol tan(const std::string &symbol_name, Symbol data)
Definition: op.h:4207
Convolution_v1CudnnTune
Definition: op.h:7039
Symbol repeat(const std::string &symbol_name, Symbol data, int repeats, dmlc::optional< int > axis=dmlc::optional< int >())
Definition: op.h:690
Symbol slice_axis(const std::string &symbol_name, Symbol data, int axis, int begin, dmlc::optional< int > end)
Definition: op.h:526
Symbol expand_dims(const std::string &symbol_name, Symbol data, int axis)
Definition: op.h:417
Symbol arctanh(const std::string &symbol_name, Symbol data)
Definition: op.h:4483
Symbol softmax_cross_entropy(const std::string &symbol_name, Symbol data, Symbol label)
Definition: op.h:5827
Symbol broadcast_axis(const std::string &symbol_name, Symbol data, Shape axis=Shape(), Shape size=Shape())
Definition: op.h:2814
Symbol abs(const std::string &symbol_name, Symbol data)
Definition: op.h:1946
Symbol cosh(const std::string &symbol_name, Symbol data)
Definition: op.h:4389
Symbol sort(const std::string &symbol_name, Symbol data, dmlc::optional< int > axis=dmlc::optional< int >(-1), bool is_ascend=true)
Definition: op.h:3078
Symbol gather_nd(const std::string &symbol_name, Symbol data, Symbol indices)
Definition: op.h:3585
Symbol slice_like(const std::string &symbol_name, Symbol data, Symbol shape_like, Shape axes=Shape())
Definition: op.h:600
Symbol BilinearSampler(const std::string &symbol_name, Symbol data, Symbol grid)
Definition: op.h:7576
Symbol Custom(const std::string &symbol_name, const std::vector< Symbol > &data, const std::string &op_type)
Definition: op.h:84
Symbol Pooling_v1(const std::string &symbol_name, Symbol data, Shape kernel=Shape(), Pooling_v1PoolType pool_type=Pooling_v1PoolType::kMax, bool global_pool=false, Pooling_v1PoolingConvention pooling_convention=Pooling_v1PoolingConvention::kValid, Shape stride=Shape(), Shape pad=Shape())
Definition: op.h:6888
Symbol broadcast_hypot(const std::string &symbol_name, Symbol lhs, Symbol rhs)
Definition: op.h:219
Symbol BatchNorm_v1(const std::string &symbol_name, Symbol data, Symbol gamma, Symbol beta, mx_float eps=0.001, mx_float momentum=0.9, bool fix_gamma=true, bool use_global_stats=false, bool output_mean_var=false)
Definition: op.h:5769
Symbol UpSampling(const std::string &symbol_name, const std::vector< Symbol > &data, uint32_t scale, UpSamplingSampleType sample_type, int num_args, uint32_t num_filter=0, UpSamplingMultiInputMode multi_input_mode=UpSamplingMultiInputMode::kConcat, uint64_t workspace=512)
Definition: op.h:5124
Symbol Activation(const std::string &symbol_name, Symbol data, ActivationActType act_type)
Definition: op.h:4815
float mx_float
manually define float
Definition: c_api.h:60
Symbol SVMOutput(const std::string &symbol_name, Symbol data, Symbol label, mx_float margin=1, mx_float regularization_coefficient=1, bool use_linear=false)
Definition: op.h:7885
Symbol radians(const std::string &symbol_name, Symbol data)
Definition: op.h:4341
Symbol Concat(const std::string &symbol_name, const std::vector< Symbol > &data, int num_args, int dim=1)
Definition: op.h:5197
L2NormalizationMode
Definition: op.h:7724
Symbol SequenceMask(const std::string &symbol_name, Symbol data, Symbol sequence_length, bool use_sequence_length=false, mx_float value=0, int axis=0)
Definition: op.h:8048
Symbol stack(const std::string &symbol_name, const std::vector< Symbol > &data, int num_args, int axis=0)
Definition: op.h:810
Symbol floor(const std::string &symbol_name, Symbol data)
Definition: op.h:2089
Symbol broadcast_sub(const std::string &symbol_name, Symbol lhs, Symbol rhs)
Definition: op.h:1081
Symbol take(const std::string &symbol_name, Symbol a, Symbol indices, int axis=0, TakeMode mode=TakeMode::kClip)
Definition: op.h:3419
Symbol ceil(const std::string &symbol_name, Symbol data)
Definition: op.h:2060
Symbol gammaln(const std::string &symbol_name, Symbol data)
Definition: op.h:2463
Symbol tile(const std::string &symbol_name, Symbol data, Shape reps)
Definition: op.h:746
Symbol min(const std::string &symbol_name, Symbol data, dmlc::optional< Shape > axis=dmlc::optional< Shape >(), bool keepdims=false, bool exclude=false)
Definition: op.h:2772
Symbol signum_update(const std::string &symbol_name, Symbol weight, Symbol grad, Symbol mom, mx_float lr, mx_float momentum=0, mx_float wd=0, mx_float rescale_grad=1, mx_float clip_gradient=-1, mx_float wd_lh=0)
Definition: op.h:6065
Symbol depth_to_space(const std::string &symbol_name, Symbol data, int block_size)
Definition: op.h:893
Symbol rmspropalex_update(const std::string &symbol_name, Symbol weight, Symbol grad, Symbol n, Symbol g, Symbol delta, mx_float lr, mx_float gamma1=0.95, mx_float gamma2=0.9, mx_float epsilon=1e-08, mx_float wd=0, mx_float rescale_grad=1, mx_float clip_gradient=-1, mx_float clip_weights=-1)
Definition: op.h:6547
Symbol ftml_update(const std::string &symbol_name, Symbol weight, Symbol grad, Symbol d, Symbol v, Symbol z, mx_float lr, int t, mx_float beta1=0.6, mx_float beta2=0.999, double epsilon=1e-08, mx_float wd=0, mx_float rescale_grad=1, mx_float clip_grad=-1)
Definition: op.h:6315
SoftmaxNormalization
Definition: op.h:7435
DeconvolutionCudnnTune
Definition: op.h:4688
ConvolutionCudnnTune
Definition: op.h:4931
Symbol prod(const std::string &symbol_name, Symbol data, dmlc::optional< Shape > axis=dmlc::optional< Shape >(), bool keepdims=false, bool exclude=false)
Definition: op.h:2620
Symbol pick(const std::string &symbol_name, Symbol data, Symbol index, dmlc::optional< int > axis=dmlc::optional< int >(-1), bool keepdims=false, PickMode mode=PickMode::kClip)
Definition: op.h:1398
Symbol broadcast_greater(const std::string &symbol_name, Symbol lhs, Symbol rhs)
Definition: op.h:3740
Symbol BatchNorm(const std::string &symbol_name, Symbol data, Symbol gamma, Symbol beta, Symbol moving_mean, Symbol moving_var, double eps=0.001, mx_float momentum=0.9, bool fix_gamma=true, bool use_global_stats=false, bool output_mean_var=false, int axis=1, bool cudnn_off=false)
Definition: op.h:4900
Symbol rcbrt(const std::string &symbol_name, Symbol data)
Definition: op.h:2287
PickMode
Definition: op.h:1337
Symbol signsgd_update(const std::string &symbol_name, Symbol weight, Symbol grad, mx_float lr, mx_float wd=0, mx_float rescale_grad=1, mx_float clip_gradient=-1)
Definition: op.h:6014
Symbol broadcast_power(const std::string &symbol_name, Symbol lhs, Symbol rhs)
Definition: op.h:114
SoftmaxOutputNormalization
Definition: op.h:7302
Symbol SoftmaxOutput(const std::string &symbol_name, Symbol data, Symbol label, mx_float grad_scale=1, mx_float ignore_label=-1, bool multi_output=false, bool use_ignore=false, bool preserve_shape=false, SoftmaxOutputNormalization normalization=SoftmaxOutputNormalization::kNull, bool out_grad=false, mx_float smooth_alpha=0)
Definition: op.h:7403
Symbol Flatten(const std::string &symbol_name, Symbol data)
Definition: op.h:350
Symbol BlockGrad(const std::string &symbol_name, Symbol data)
Definition: op.h:1693
LeakyReLUActType
Definition: op.h:5608
Symbol sgd_mom_update(const std::string &symbol_name, Symbol weight, Symbol grad, Symbol mom, mx_float lr, mx_float momentum=0, mx_float wd=0, mx_float rescale_grad=1, mx_float clip_gradient=-1, bool lazy_update=true)
Definition: op.h:6179
Symbol arccos(const std::string &symbol_name, Symbol data)
Definition: op.h:4261
Symbol hard_sigmoid(const std::string &symbol_name, Symbol data, mx_float alpha=0.2, mx_float beta=0.5)
Definition: op.h:1627
Symbol argmax_channel(const std::string &symbol_name, Symbol data)
Definition: op.h:1326
Symbol batch_take(const std::string &symbol_name, Symbol a, Symbol indices)
Definition: op.h:3465
Symbol mean(const std::string &symbol_name, Symbol data, dmlc::optional< Shape > axis=dmlc::optional< Shape >(), bool keepdims=false, bool exclude=false)
Definition: op.h:2583
Symbol LinearRegressionOutput(const std::string &symbol_name, Symbol data, Symbol label, mx_float grad_scale=1)
Definition: op.h:5865
Symbol softsign(const std::string &symbol_name, Symbol data)
Definition: op.h:1653
Symbol broadcast_like(const std::string &symbol_name, Symbol lhs, Symbol rhs)
Definition: op.h:2886
Symbol sgd_update(const std::string &symbol_name, Symbol weight, Symbol grad, mx_float lr, mx_float wd=0, mx_float rescale_grad=1, mx_float clip_gradient=-1, bool lazy_update=true)
Definition: op.h:6116
Symbol choose_element_0index(const std::string &symbol_name, Symbol lhs, Symbol rhs)
Definition: op.h:8071
Symbol Reshape(const std::string &symbol_name, Symbol data, Shape shape=Shape(), bool reverse=false, Shape target_shape=Shape(), bool keep_highest=false)
Definition: op.h:302
Symbol degrees(const std::string &symbol_name, Symbol data)
Definition: op.h:4315
Symbol shape_array(const std::string &symbol_name, Symbol data, dmlc::optional< int > lhs_begin=dmlc::optional< int >(), dmlc::optional< int > lhs_end=dmlc::optional< int >(), dmlc::optional< int > rhs_begin=dmlc::optional< int >(), dmlc::optional< int > rhs_end=dmlc::optional< int >())
Definition: op.h:1797
Symbol one_hot(const std::string &symbol_name, Symbol indices, int depth, double on_value=1, double off_value=0, One_hotDtype dtype=One_hotDtype::kFloat32)
Definition: op.h:3530
Symbol negative(const std::string &symbol_name, Symbol data)
Definition: op.h:1896
Symbol sum(const std::string &symbol_name, Symbol data, dmlc::optional< Shape > axis=dmlc::optional< Shape >(), bool keepdims=false, bool exclude=false)
Definition: op.h:2546
Symbol GridGenerator(const std::string &symbol_name, Symbol data, GridGeneratorTransformType transform_type, Shape target_shape=Shape(0, 0))
Definition: op.h:6807
Symbol size_array(const std::string &symbol_name, Symbol data)
Definition: op.h:1826
Symbol argmax(const std::string &symbol_name, Symbol data, dmlc::optional< int > axis=dmlc::optional< int >(), bool keepdims=false)
Definition: op.h:1251
Operator interface.
Definition: operator.h:43
Symbol interface.
Definition: symbol.h:72
MakeLossNormalization
Definition: op.h:7812
Symbol log10(const std::string &symbol_name, Symbol data)
Definition: op.h:2355
Symbol log2(const std::string &symbol_name, Symbol data)
Definition: op.h:2376