The standard way of computing a nonlinear model using AOCL-DA is as follows.
Initialize a
aoclda.nonlinear_model.nlls()object with some options set in the class constructor.Fit a nonlinear model to the data using
aoclda.nonlinear_model.nlls.fit(). Here you will have to provide some functions that define the nonlinear model’s residual vector and a function to return the residual Jacobian matrix. The optimized parameters, \(x\), are modified in-place and returned on the interface ofaoclda.nonlinear_model.nlls.fit().Extract results from the
aoclda.nonlinear_model.nlls()object via its class attributes.
Initialize a
da_handlewithda_handle_typeda_handle_nlls.Pass the model to the handle using da_nlls_define_residuals_?.
Customize the model using da_options_set_? (see below for a list of the available options).
Train the nonlinear model using da_nlls_fit_? (you will have to provide an initial guess).
Optimized coefficients \(x\) are returned on the interface.
Extract results using da_handle_get_result_? using
da_result_::da_rinfo.The following results are available in the
info[100]array:info[0]: objective value,
info[1]: norm of objective gradient,
info[2]: number of iterations,
info[3]: reserved for future use,
info[4]: number of function callback evaluations (includes
info[9]),info[5]: number of gradient callback evaluations,
info[6]: number of Hessian callback evaluations,
info[7]: number of Hessian-vector callback evaluations,
info[8]: scaled gradient norm of objective,
info[9]: number of objective function callback evaluations used for approximating the derivatives or due to derivative checker,
info[10-99]: reserved for future use.