Cite Us
pyOpt

Table Of Contents

Previous topic

Optimizers

Next topic

NLPQL - Non-Linear Programming by Quadratic Lagrangian

SNOPT - Sparse NOnlinear OPTimizer

SNOPT is a sparse nonlinear optimizer that is particularly useful for solving large-scale constrained problems with smooth objective functions and constraints. The algorithm consists of a sequential quadratic programming (SQP) algorithm that uses a smooth augmented Lagrangian merit function, while making explicit provision for infeasibility in the original problem and in the quadratic programming subproblems. The Hessian of the Lagrangian is approximated using a limited-memory quasi-Newton method. [Gill2002] [LICENSE]

class pySNOPT.SNOPT(pll_type=None, *args, **kwargs)

Bases: pyOpt.pyOpt_optimizer.Optimizer

SNOPT Optimizer Class - Inherited from Optimizer Abstract Class

SNOPT Optimizer Class Initialization

Keyword arguments:

  • pll_type -> STR: Parallel Implementation (None, ‘POA’-Parallel Objective Analysis), Default = None

Documentation last updated: Feb. 16, 2010 - Peter W. Jansen

__solve__(opt_problem={}, sens_type='FD', store_sol=True, disp_opts=False, store_hst=False, hot_start=False, sens_mode='', sens_step={}, *args, **kwargs)

Run Optimizer (Optimize Routine)

Keyword arguments:

  • opt_problem -> INST: Optimization instance
  • sens_type -> STR/FUNC: Gradient type, Default = ‘FD’
  • store_sol -> BOOL: Store solution in Optimization class flag, Default = True
  • disp_opts -> BOOL: Flag to display options in solution text, Default = False
  • store_hst -> BOOL/STR: Flag/filename to store optimization history, Default = False
  • hot_start -> BOOL/STR: Flag/filename to read optimization history, Default = False
  • sens_mode -> STR: Flag for parallel gradient calculation, Default = ‘’
  • sens_step -> FLOAT: Sensitivity setp size, Default = {} [corresponds to 1e-6 (FD), 1e-20(CS)]

Additional arguments and keyword arguments are passed to the objective function call.

Documentation last updated: Feb. 2, 2011 - Peter W. Jansen

Optimizer Options

Name Type Default Value Notes
Major print level int 1 Majors Print (1 - line major iteration log)
Minor print level int 1 Minors Print (1 - line minor iteration log)
Print file str ‘SNOPT_print.out’ Print File Name (specified by subroutine snInit)
iPrint int 18 Print File Output Unit
Summary file str ‘SNOPT_summary.out’ Summary File Name (specified by subroutine snInit)
iSumm int 19 Summary File Output Unit
Print frequency int 100 Minors Log Frequency on Print File
Summary frequency int 100 Minors Log Frequency on Summary File
Solution str ‘Yes’ Print Solution on the Print File
Suppress options listing type(None) None options are normally listed
System information str ‘No’ Print System Information on the Print File
Problem Type str ‘Minimize’ Alternatives ‘Maximize’, ‘Feasible point’
Objective row int 1 has precedence over ObjRow (snOptA)
Infinite bound float 1.0e+20 Infinite Bound Value
Major feasibility tolerance float 1.0e-6 Target Nonlinear Constraint Violation
Major optimality tolerance float 1.0e-6 Target Complementarity Gap
Minor feasibility tolerance float 1.0e-6 For Satisfying the QP Bounds
Verify level int 0 Gradients Check Flag
Scale option int 1 Scaling (1 - linear constraints and variables)
Scale tolerance float 0.9 Scaling Tolerance
Scale Print type(None) None Default: scales are not printed
Crash tolerance float 0.1  
Linesearch tolerance float 0.9 smaller for more accurate search
Pivot tolerance float 3.7e-11 epsilon^{2/3}
QPSolver str ‘Cholesky’ Default: Cholesky
Crash option int 3 3 - first basis is essentially triangular
Elastic mode str ‘No’ start with elastic mode until necessary
Elastic weight float 1.0e+4 used only during elastic mode
Iterations limit int 10000 or 20*ncons if that is more
Partial price int 1 10 for large LPs
Start str ‘Cold’ has precedence over argument start
Major iterations limit int 1000 or ncons if that is more
Minor iterations limit int 500 or 3*ncons if that is more
Major step limit float 2.0  
Superbasics limit int None n1 + 1, n1 = number of nonlinear variables
Derivative level int 3 NOT ALLOWED IN snOptA
Derivative option int 1 ONLY FOR snOptA
Derivative linesearch type(None) None  
Nonderivative linesearch type(None) None  
Function precision float 3.0e-13 epsilon^0.8 (almost full accuracy)
Difference interval float 5.5e-7 Function precision^(1/2)
Central difference interval float 6.7e-5 Function precision^(1/3)
New superbasics limit int 99 controls early termination of QPs
Objective row int 1 row number of objective in F(x)
Penalty parameter float 0.0 initial penalty parameter
Proximal point method int 1 1 - satisfies linear constraints near x0
Reduced Hessian dimension int 2000 or Superbasics limit if that is less
Violation limit int 10.0 unscaled constraint violation limit
Unbounded step size float 1.0e+18  
Unbounded objective float 1.0e+15  
Hessian full memory type(None) None default if n1 <= 75
Hessian limited memory type(None) None default if n1 > 75
Hessian frequency int 999999 for full Hessian (never reset)
Hessian updates int 10 for limited memory Hessian
Hessian flush int 999999 no flushing
Check frequency int 60 test row residuals l2norm(Ax - sk)
Expand frequency int 10000 for anti-cycling procedure
Factorization frequency int 50 100 for LPs
Save frequency int 100 save basis map
LU factor tolerance float 3.99 for NP (100.0 for LP)
LU update tolerance float 3.99 for NP ( 10.0 for LP)
LU singularity tolerance float 3.2e-11  
LU partial pivoting type(None) None default threshold pivoting strategy
LU rook pivoting type(None) None threshold rook pivoting
LU complete pivoting type(None) None threshold complete pivoting
Old basis file int 0 input basis map
New basis file int 0 output basis map
Backup basis file int 0 output extra basis map
Insert file int 0 input in industry format
Punch file int 0 output Insert data
Load file int 0 input names and values
Dump file int 0 output Load data
Solution file int 0 different from printed solution
Total character workspace int 500 lencw: 500
Total integer workspace int None leniw: 500 + 100 * (m+n)
Total real workspace int None lenrw: 500 + 200 * (m+n)
User character workspace int 500  
User integer workspace int 500  
User real workspace int 500  
Debug level int 0 0 - Normal, 1 - for developers
Timing level int 3 3 - print cpu times