10 #define MXNET_EXTERN_C extern "C"
18 #define MXNET_DLL MXNET_EXTERN_C __declspec(dllexport)
20 #define MXNET_DLL MXNET_EXTERN_C __declspec(dllimport)
23 #define MXNET_DLL MXNET_EXTERN_C
66 void (*forward)(int,
float**,
int*,
unsigned**,
int*,
void*);
67 void (*backward)(int,
float**,
int*,
unsigned**,
int*,
void*);
68 void (*infer_shape)(int,
int*,
unsigned**,
void*);
69 void (*list_outputs)(
char***,
void*);
70 void (*list_arguments)(
char***,
void*);
76 void* p_list_arguments;
80 bool (*
forward)(int,
void**,
int*,
void*);
98 const int* ,
const bool ,
void* );
100 const int* ,
const bool ,
void* );
132 const char** ,
const char** ,
230 const char **out_buf);
256 const char*** out_names);
416 const char **description,
418 const char ***arg_names,
419 const char ***arg_type_infos,
420 const char ***arg_descriptions,
421 const char **return_type = NULL);
501 const char **description,
503 const char ***arg_names,
504 const char ***arg_type_infos,
505 const char ***arg_descriptions,
506 const char **key_var_num_args,
507 const char **return_type = NULL);
657 const char ***out_str_array);
667 const char ***out_str_array);
695 const char ***out_str_array);
757 const mx_uint ***in_shape_data,
759 const mx_uint **out_shape_ndim,
760 const mx_uint ***out_shape_data,
762 const mx_uint **aux_shape_ndim,
763 const mx_uint ***aux_shape_data,
796 const mx_uint ***in_shape_data,
798 const mx_uint **out_shape_ndim,
799 const mx_uint ***out_shape_data,
801 const mx_uint **aux_shape_ndim,
802 const mx_uint ***aux_shape_data,
826 const int *arg_type_data,
828 const int **in_type_data,
830 const int **out_type_data,
832 const int **aux_type_data,
933 const char** map_keys,
934 const int* map_dev_types,
935 const int* map_dev_ids,
969 const char** map_keys,
970 const int* map_dev_types,
971 const int* map_dev_ids,
985 void* callback_handle);
1025 const char **description,
1027 const char ***arg_names,
1028 const char ***arg_type_infos,
1029 const char ***arg_descriptions);
1067 uint64_t **out_index,
1068 uint64_t *out_size);
1174 void *updater_handle);
1248 void *controller_handle);
1260 void *controller_handle);
1272 const char* cmd_body);
1297 const char *buf,
size_t size);
1322 char const **buf,
size_t *size);
1328 char** input_names,
char** output_names,
1369 #endif // MXNET_C_API_H_
MXNET_DLL int MXKVStoreSendCommmandToServers(KVStoreHandle handle, int cmd_id, const char *cmd_body)
bool(* list_arguments)(char ***, void *)
Definition: c_api.h:84
void * OptimizerCreator
handle to a function that takes param and creates optimizer
Definition: c_api.h:56
void * p_forward
Definition: c_api.h:103
MXNET_EXTERN_C
Definition: c_api.h:64
MXNET_DLL int MXKVStoreSetUpdater(KVStoreHandle handle, MXKVStoreUpdater updater, void *updater_handle)
register an push updater
MXNET_DLL int MXKVStoreBarrier(KVStoreHandle handle)
global barrier among all worker machines
void * DataIterHandle
handle to a DataIterator
Definition: c_api.h:48
MXNET_DLL int MXSymbolListAtomicSymbolCreators(mx_uint *out_size, AtomicSymbolCreator **out_array)
list all the available AtomicSymbolEntry
void * OptimizerHandle
handle to Optimizer
Definition: c_api.h:58
MXNET_DLL int MXOptimizerFree(OptimizerHandle handle)
MXNET_DLL int MXDataIterCreateIter(DataIterCreator handle, mx_uint num_param, const char **keys, const char **vals, DataIterHandle *out)
Init an iterator, init with parameters the array size of passed in arguments.
MXNET_DLL int MXDataIterNext(DataIterHandle handle, int *out)
Move iterator to next position.
MXNET_DLL int MXNDArrayReshape(NDArrayHandle handle, int ndim, int *dims, NDArrayHandle *out)
Reshape the NDArray.
void * p_infer_shape
Definition: c_api.h:90
MXNET_DLL int MXRecordIOReaderFree(RecordIOHandle *handle)
Delete a RecordIO reader object.
MXNET_DLL int MXExecutorPrint(ExecutorHandle handle, const char **out_str)
Print the content of execution plan, used for debug.
MXNET_DLL int MXKVStoreRunServer(KVStoreHandle handle, MXKVStoreServerController controller, void *controller_handle)
MXNET_DLL int MXSymbolSaveToJSON(SymbolHandle symbol, const char **out_json)
Save a symbol into a json string.
MXNET_DLL int MXSymbolInferShape(SymbolHandle sym, mx_uint num_args, const char **keys, const mx_uint *arg_ind_ptr, const mx_uint *arg_shape_data, mx_uint *in_shape_size, const mx_uint **in_shape_ndim, const mx_uint ***in_shape_data, mx_uint *out_shape_size, const mx_uint **out_shape_ndim, const mx_uint ***out_shape_data, mx_uint *aux_shape_size, const mx_uint **aux_shape_ndim, const mx_uint ***aux_shape_data, int *complete)
infer shape of unknown input shapes given the known one. The shapes are packed into a CSR matrix repr...
MXNET_DLL int MXSymbolGetAttr(SymbolHandle symbol, const char *key, const char **out, int *success)
Get string attribute from symbol.
MXNET_DLL int MXRtcCreate(char *name, mx_uint num_input, mx_uint num_output, char **input_names, char **output_names, NDArrayHandle *inputs, NDArrayHandle *outputs, char *kernel, RtcHandle *out)
Create a MXRtc object.
MXNET_DLL int MXKVStorePull(KVStoreHandle handle, mx_uint num, const int *keys, NDArrayHandle *vals, int priority)
pull a list of (key, value) pairs from the kvstore
MXNET_DLL int MXNDArrayWaitToRead(NDArrayHandle handle)
Wait until all the pending writes with respect NDArray are finished. Always call this before read dat...
MXNET_DLL int MXExecutorBind(SymbolHandle symbol_handle, int dev_type, int dev_id, mx_uint len, NDArrayHandle *in_args, NDArrayHandle *arg_grad_store, mx_uint *grad_req_type, mx_uint aux_states_len, NDArrayHandle *aux_states, ExecutorHandle *out)
Generate Executor from symbol.
void * p_forward
Definition: c_api.h:88
void * p_backward
Definition: c_api.h:104
MXNET_DLL int MXDataIterFree(DataIterHandle handle)
Free the handle to the IO module.
void * RecordIOHandle
handle to RecordIO
Definition: c_api.h:52
MXNET_DLL int MXExecutorOutputs(ExecutorHandle handle, mx_uint *out_size, NDArrayHandle **out)
Get executor's head NDArray.
MXNET_DLL int MXNDArrayGetContext(NDArrayHandle handle, int *out_dev_type, int *out_dev_id)
get the context of the NDArray
MXNET_DLL int MXFuncDescribe(FunctionHandle fun, mx_uint *num_use_vars, mx_uint *num_scalars, mx_uint *num_mutate_vars, int *type_mask)
get the argument requirements of the function
MXNET_DLL int MXKVStoreIsServerNode(int *ret)
return whether or not this process is a server node.
MXNET_DLL int MXNDArraySlice(NDArrayHandle handle, mx_uint slice_begin, mx_uint slice_end, NDArrayHandle *out)
Slice the NDArray along axis 0.
bool(* forward)(int, void **, int *, void *)
Definition: c_api.h:80
void * ExecutorHandle
handle to an Executor
Definition: c_api.h:44
bool(* forward)(int, void **, int *, const int *, const bool, void *)
Definition: c_api.h:97
MXNET_DLL int MXSymbolSaveToFile(SymbolHandle symbol, const char *fname)
Save a symbol into a json file.
MXNET_DLL int MXRecordIOReaderReadRecord(RecordIOHandle *handle, char const **buf, size_t *size)
Write a record to a RecordIO object.
void * AtomicSymbolHandle
handle to a AtomicSymbol
Definition: c_api.h:42
MXNET_DLL int MXFuncGetInfo(FunctionHandle fun, const char **name, const char **description, mx_uint *num_args, const char ***arg_names, const char ***arg_type_infos, const char ***arg_descriptions, const char **return_type=NULL)
Get the information of the function handle.
MXNET_DLL int MXNDArrayFree(NDArrayHandle handle)
free the narray handle
MXNET_DLL int MXSymbolCreateFromJSON(const char *json, SymbolHandle *out)
Load a symbol from a json string.
bool(* infer_shape)(int, int *, unsigned **, void *)
Definition: c_api.h:82
MXNET_DLL int MXKVStoreIsSchedulerNode(int *ret)
return whether or not this process is a scheduler node.
MXNET_EXTERN_C typedef void(* ExecutorMonitorCallback)(const char *, NDArrayHandle, void *)
Definition: c_api.h:60
MXNET_DLL int MXSymbolListAttr(SymbolHandle symbol, mx_uint *out_size, const char ***out)
Get all attributes from symbol, including all descendents.
MXNET_DLL int MXNDArrayAt(NDArrayHandle handle, mx_uint idx, NDArrayHandle *out)
Index the NDArray along axis 0.
MXNET_DLL int MXNDArrayLoad(const char *fname, mx_uint *out_size, NDArrayHandle **out_arr, mx_uint *out_name_size, const char ***out_names)
Load list of narray from the file.
MXNET_DLL int MXNDArraySyncCopyFromCPU(NDArrayHandle handle, const void *data, size_t size)
Perform a synchronize copy from a continugous CPU memory region.
MXNET_DLL int MXSymbolCreateFromFile(const char *fname, SymbolHandle *out)
Load a symbol from a json file.
MXNET_DLL int MXNDArrayCreateEx(const mx_uint *shape, mx_uint ndim, int dev_type, int dev_id, int delay_alloc, int dtype, NDArrayHandle *out)
create a NDArray with specified shape and data type
MXNET_DLL int MXKVStoreCreate(const char *type, KVStoreHandle *out)
Create a kvstore.
void * p_list_outputs
Definition: c_api.h:123
void * p_declare_backward_dependency
Definition: c_api.h:93
MXNET_DLL int MXSymbolGetAtomicSymbolInfo(AtomicSymbolCreator creator, const char **name, const char **description, mx_uint *num_args, const char ***arg_names, const char ***arg_type_infos, const char ***arg_descriptions, const char **key_var_num_args, const char **return_type=NULL)
Get the detailed information about atomic symbol.
MXNET_DLL int MXNDArrayCreateNone(NDArrayHandle *out)
create a NDArray handle that is not initialized can be used to pass in as mutate variables to hold th...
MXNET_DLL int MXKVStoreFree(KVStoreHandle handle)
Delete a KVStore handle.
void * p_list_arguments
Definition: c_api.h:92
MXNET_DLL int MXCustomOpRegister(const char *op_type, CustomOpPropCreator creator)
void * SymbolHandle
handle to a symbol that can be bind as operator
Definition: c_api.h:40
MXNET_DLL int MXSymbolCopy(SymbolHandle symbol, SymbolHandle *out)
Copy the symbol to another handle.
MXNET_DLL int MXSymbolSetAttr(SymbolHandle symbol, const char *key, const char *value)
Set string attribute from symbol. NOTE: Setting attribute to a symbol can affect the semantics(mutabl...
void * p_infer_shape
Definition: c_api.h:124
MXNET_DLL int MXDataIterBeforeFirst(DataIterHandle handle)
Call iterator.Reset.
MXNET_DLL int MXSymbolInferShapePartial(SymbolHandle sym, mx_uint num_args, const char **keys, const mx_uint *arg_ind_ptr, const mx_uint *arg_shape_data, mx_uint *in_shape_size, const mx_uint **in_shape_ndim, const mx_uint ***in_shape_data, mx_uint *out_shape_size, const mx_uint **out_shape_ndim, const mx_uint ***out_shape_data, mx_uint *aux_shape_size, const mx_uint **aux_shape_ndim, const mx_uint ***aux_shape_data, int *complete)
partially infer shape of unknown input shapes given the known one.
MXNET_DLL int MXSymbolListOutputs(SymbolHandle symbol, mx_uint *out_size, const char ***out_str_array)
List returns in the symbol.
void( MXKVStoreUpdater)(int key, NDArrayHandle recv, NDArrayHandle local, void *handle)
user-defined updater for the kvstore It's this updater's responsibility to delete recv and local ...
Definition: c_api.h:1161
MXNET_DLL int MXListDataIters(mx_uint *out_size, DataIterCreator **out_array)
List all the available iterator entries.
MXNET_DLL int MXNDArrayGetShape(NDArrayHandle handle, mx_uint *out_dim, const mx_uint **out_pdata)
get the shape of the array
MXNET_DLL int MXDataIterGetPadNum(DataIterHandle handle, int *pad)
Get the padding number in current data batch.
MXNET_DLL int MXFuncInvokeEx(FunctionHandle fun, NDArrayHandle *use_vars, mx_float *scalar_args, NDArrayHandle *mutate_vars, int num_params, char **param_keys, char **param_vals)
invoke a function, the array size of passed in arguments must match the values in the ...
MXNET_DLL int MXRandomSeed(int seed)
Seed the global random number generators in mxnet.
MXNET_DLL int MXOptimizerCreateOptimizer(OptimizerCreator creator, mx_uint num_param, const char **keys, const char **vals, OptimizerHandle *out)
MXNET_DLL int MXSymbolGetOutput(SymbolHandle symbol, mx_uint index, SymbolHandle *out)
Get index-th outputs of the symbol.
MXNET_DLL int MXNDArrayGetDType(NDArrayHandle handle, int *out_dtype)
get the type of the data in NDArray
MXNET_DLL int MXRecordIOWriterWriteRecord(RecordIOHandle *handle, const char *buf, size_t size)
Write a record to a RecordIO object.
MXNET_DLL int MXSymbolGetInternals(SymbolHandle symbol, SymbolHandle *out)
Get a symbol that contains all the internals.
bool(* list_arguments)(char ***, void *)
Definition: c_api.h:109
bool(* create_operator)(const char *, int, unsigned **, int *, int *, CustomOpInfo *, void *)
Definition: c_api.h:116
MXNET_DLL int MXInitPSEnv(mx_uint num_vars, const char **keys, const char **vals)
Initialized ps-lite environment variables.
MXNET_DLL int MXDataIterGetData(DataIterHandle handle, NDArrayHandle *out)
Get the handle to the NDArray of underlying data.
void * p_declare_backward_dependency
Definition: c_api.h:125
MXNET_DLL int MXRtcFree(RtcHandle handle)
Delete a MXRtc object.
MXNET_DLL int MXOptimizerUpdate(OptimizerHandle handle, int index, NDArrayHandle weight, NDArrayHandle grad, mx_float lr, mx_float wd)
MXNET_DLL int MXNDArraySyncCopyToCPU(NDArrayHandle handle, void *data, size_t size)
Perform a synchronize copyto a continugous CPU memory region.
void * KVStoreHandle
handle to KVStore
Definition: c_api.h:50
void * NDArrayHandle
handle to NDArray
Definition: c_api.h:34
MXNET_DLL int MXNotifyShutdown()
Notify the engine about a shutdown, This can help engine to print less messages into display...
bool(* list_outputs)(char ***, void *)
Definition: c_api.h:83
void * p_list_outputs
Definition: c_api.h:91
bool(* declare_backward_dependency)(const int *, const int *, const int *, int *, int **, void *)
Definition: c_api.h:85
MXNET_DLL int MXDataIterGetIndex(DataIterHandle handle, uint64_t **out_index, uint64_t *out_size)
Get the image index by array.
MXNET_DLL int MXDataIterGetLabel(DataIterHandle handle, NDArrayHandle *out)
Get the handle to the NDArray of underlying label.
void * p_del
Definition: c_api.h:105
MXNET_DLL int MXSymbolCreateGroup(mx_uint num_symbols, SymbolHandle *symbols, SymbolHandle *out)
Create a Symbol by grouping list of symbols together.
MXNET_DLL int MXNDArrayCreate(const mx_uint *shape, mx_uint ndim, int dev_type, int dev_id, int delay_alloc, NDArrayHandle *out)
create a NDArray with specified shape
MXNET_DLL int MXFuncInvoke(FunctionHandle fun, NDArrayHandle *use_vars, mx_float *scalar_args, NDArrayHandle *mutate_vars)
invoke a function, the array size of passed in arguments must match the values in the ...
MXNET_DLL int MXSymbolListArguments(SymbolHandle symbol, mx_uint *out_size, const char ***out_str_array)
List arguments in the symbol.
MXNET_DLL int MXRecordIOWriterCreate(const char *uri, RecordIOHandle *out)
Create a RecordIO writer object.
void * p_create_operator
Definition: c_api.h:126
MXNET_DLL int MXNDArrayWaitAll()
wait until all delayed operations in the system is completed
MXNET_DLL int MXRecordIOReaderCreate(const char *uri, RecordIOHandle *out)
Create a RecordIO reader object.
void * p_del
Definition: c_api.h:128
unsigned int mx_uint
manually define unsigned int
Definition: c_api.h:27
bool(* CustomOpPropCreator)(const char *, const int, const char **, const char **, CustomOpPropInfo *)
Definition: c_api.h:131
MXNET_DLL int MXNDArraySaveRawBytes(NDArrayHandle handle, size_t *out_size, const char **out_buf)
save the NDArray into raw bytes.
MXNET_DLL int MXSymbolGetName(SymbolHandle symbol, const char **out, int *success)
Get string name from symbol.
void * p_backward
Definition: c_api.h:89
MXNET_DLL int MXExecutorBindEX(SymbolHandle symbol_handle, int dev_type, int dev_id, mx_uint num_map_keys, const char **map_keys, const int *map_dev_types, const int *map_dev_ids, mx_uint len, NDArrayHandle *in_args, NDArrayHandle *arg_grad_store, mx_uint *grad_req_type, mx_uint aux_states_len, NDArrayHandle *aux_states, ExecutorHandle shared_exec, ExecutorHandle *out)
Generate Executor from symbol, This is advanced function, allow specify group2ctx map...
bool(* infer_shape)(int, int *, unsigned **, void *)
Definition: c_api.h:111
MXNET_DLL int MXRecordIOWriterFree(RecordIOHandle handle)
Delete a RecordIO writer object.
MXNET_DLL int MXExecutorBackward(ExecutorHandle handle, mx_uint len, NDArrayHandle *head_grads)
Excecutor run backward.
MXNET_DLL int MXKVStoreGetRank(KVStoreHandle handle, int *ret)
return The rank of this node in its group, which is in [0, GroupSize).
MXNET_DLL int MXKVStoreGetGroupSize(KVStoreHandle handle, int *ret)
return The number of nodes in this group, which is
MXNET_DLL int MXSymbolCreateVariable(const char *name, SymbolHandle *out)
Create a Variable Symbol.
MXNET_DLL int MXExecutorSetMonitorCallback(ExecutorHandle handle, ExecutorMonitorCallback callback, void *callback_handle)
set a call back to notify the completion of operation
MXNET_DLL int MXKVStoreIsWorkerNode(int *ret)
return whether or not this process is a worker node.
MXNET_DLL int MXSymbolPrint(SymbolHandle symbol, const char **out_str)
Print the content of symbol, used for debug.
MXNET_DLL int MXSymbolCompose(SymbolHandle sym, const char *name, mx_uint num_args, const char **keys, SymbolHandle *args)
Compose the symbol on other symbols.
MXNET_DLL int MXSymbolGrad(SymbolHandle sym, mx_uint num_wrt, const char **wrt, SymbolHandle *out)
Get the gradient graph of the symbol.
float mx_float
manually define float
Definition: c_api.h:29
bool(* del)(void *)
Definition: c_api.h:120
#define MXNET_DLL
MXNET_DLL prefix for windows.
Definition: c_api.h:23
MXNET_DLL int MXSymbolCreateAtomicSymbol(AtomicSymbolCreator creator, mx_uint num_param, const char **keys, const char **vals, SymbolHandle *out)
Create an AtomicSymbol.
bool(* backward)(int, void **, int *, void *)
Definition: c_api.h:81
MXNET_DLL const char * MXGetLastError()
return str message of the last error all function in this file will return 0 when success and -1 when...
void * AtomicSymbolCreator
handle to a function that takes param and creates symbol
Definition: c_api.h:38
bool(* list_auxiliary_states)(char ***, void *)
Definition: c_api.h:119
MXNET_DLL int MXExecutorBindX(SymbolHandle symbol_handle, int dev_type, int dev_id, mx_uint num_map_keys, const char **map_keys, const int *map_dev_types, const int *map_dev_ids, mx_uint len, NDArrayHandle *in_args, NDArrayHandle *arg_grad_store, mx_uint *grad_req_type, mx_uint aux_states_len, NDArrayHandle *aux_states, ExecutorHandle *out)
Generate Executor from symbol, This is advanced function, allow specify group2ctx map...
void( MXKVStoreServerController)(int head, const char *body, void *controller_handle)
the prototype of a server controller
Definition: c_api.h:1246
MXNET_DLL int MXNDArraySave(const char *fname, mx_uint num_args, NDArrayHandle *args, const char **keys)
Save list of narray into the file.
MXNET_DLL int MXNDArrayLoadFromRawBytes(const void *buf, size_t size, NDArrayHandle *out)
create a NDArray handle that is loaded from raw bytes.
MXNET_DLL int MXRtcPush(RtcHandle handle, mx_uint num_input, mx_uint num_output, NDArrayHandle *inputs, NDArrayHandle *outputs, mx_uint gridDimX, mx_uint gridDimY, mx_uint gridDimZ, mx_uint blockDimX, mx_uint blockDimY, mx_uint blockDimZ)
Run cuda kernel.
MXNET_DLL int MXSymbolListAuxiliaryStates(SymbolHandle symbol, mx_uint *out_size, const char ***out_str_array)
List auxiliary states in the symbol.
bool(* declare_backward_dependency)(const int *, const int *, const int *, int *, int **, void *)
Definition: c_api.h:113
MXNET_DLL int MXGetFunction(const char *name, FunctionHandle *out)
get the function handle by name
MXNET_DLL int MXSymbolListAttrShallow(SymbolHandle symbol, mx_uint *out_size, const char ***out)
Get all attributes from symbol, excluding descendents.
void * DataIterCreator
handle a dataiter creator
Definition: c_api.h:46
MXNET_DLL int MXDataIterGetIterInfo(DataIterCreator creator, const char **name, const char **description, mx_uint *num_args, const char ***arg_names, const char ***arg_type_infos, const char ***arg_descriptions)
Get the detailed information about data iterator.
MXNET_DLL int MXKVStoreGetType(KVStoreHandle handle, const char **type)
get the type of the kvstore
void * RtcHandle
handle to MXRtc
Definition: c_api.h:54
MXNET_DLL int MXSymbolInferType(SymbolHandle sym, mx_uint num_args, const char **keys, const int *arg_type_data, mx_uint *in_type_size, const int **in_type_data, mx_uint *out_type_size, const int **out_type_data, mx_uint *aux_type_size, const int **aux_type_data, int *complete)
infer type of unknown input types given the known one. The types are packed into a CSR matrix represe...
MXNET_DLL int MXKVStoreInit(KVStoreHandle handle, mx_uint num, const int *keys, NDArrayHandle *vals)
Init a list of (key,value) pairs in kvstore.
const void * FunctionHandle
handle to a mxnet narray function that changes NDArray
Definition: c_api.h:36
void * p_list_arguments
Definition: c_api.h:122
bool(* del)(void *)
Definition: c_api.h:101
MXNET_DLL int MXKVStorePush(KVStoreHandle handle, mx_uint num, const int *keys, NDArrayHandle *vals, int priority)
Push a list of (key,value) pairs to kvstore.
MXNET_DLL int MXListFunctions(mx_uint *out_size, FunctionHandle **out_array)
list all the available functions handles most user can use it to list all the needed functions ...
void * p_list_auxiliary_states
Definition: c_api.h:127
bool(* list_outputs)(char ***, void *)
Definition: c_api.h:110
MXNET_DLL int MXSymbolFree(SymbolHandle symbol)
Free the symbol handle.
MXNET_DLL int MXExecutorFree(ExecutorHandle handle)
Delete the executor.
MXNET_DLL int MXNDArrayGetData(NDArrayHandle handle, mx_float **out_pdata)
get the content of the data in NDArray
bool(* backward)(int, void **, int *, const int *, const bool, void *)
Definition: c_api.h:99
MXNET_DLL int MXNDArrayWaitToWrite(NDArrayHandle handle)
Wait until all the pending read/write with respect NDArray are finished. Always call this before writ...
MXNET_DLL int MXExecutorForward(ExecutorHandle handle, int is_train)
Executor forward method.
MXNET_DLL int MXOptimizerFindCreator(const char *key, OptimizerCreator *out)