public Operator(string operatorName) { this._OpName = operatorName; this._Handle = OpMap.GetSymbolCreator(operatorName); var return_type = System.IntPtr.Zero; Logging.CHECK_EQ(NativeMethods.MXSymbolGetAtomicSymbolInfo(this._Handle, out var name, out var description, out var numArgs, out var argNames, out var argTypeInfos, out var argDescriptions, out var keyVarNumArgs, ref return_type), NativeMethods.OK); var argNamesArray = InteropHelper.ToPointerArray(argNames, numArgs); for (var i = 0; i < numArgs; ++i) { var pArgName = argNamesArray[i]; this._ArgNames.Add(Marshal.PtrToStringAnsi(pArgName)); } }
public AdamOptimizer(uint beginNumUpdate) : base(beginNumUpdate) { this._UpdateHandle = OpMap.GetSymbolCreator("adam_update"); this.SetParam("beta1", 0.9f); this.SetParam("beta2", 0.999f); this.SetParam("epsilon", 1e-8); }
public RMSPropOptimizer(uint beginNumUpdate) : base(beginNumUpdate) { this._UpdateHandle = OpMap.GetSymbolCreator("rmsprop_update"); this._AlexUpdateHandle = OpMap.GetSymbolCreator("rmspropalex_update"); this.SetParam("gamma1", 0.9f); this.SetParam("gamma2", 0.9f); this.SetParam("epsilon", 1e-8); }
public SignumOptimizer(uint beginNumUpdate) : base(beginNumUpdate) { this._UpdateHandle = OpMap.GetSymbolCreator("signsgd_update"); this._MomUpdateHandle = OpMap.GetSymbolCreator("signum_update"); }