Gradient
- class pyoptsparse.pyOpt_gradient.Gradient(optProb, sensType, sensStep=None, sensMode='', comm=None)[source]
Gradient class for automatically computing gradients with finite difference or complex step.
- Parameters:
- optProbOptimization instance
This is the complete description of the optimization problem.
- sensTypestr
FDfor forward differenceCDfor central differenceFDRfor forward difference with relative step sizeCDRfor central difference with relative step sizeCSfor complex step
- sensStepfloat
Step size to use for differencing
- sensModestr
Flag to compute gradients in parallel.