25.11.2015 Views

The MOSEK Python optimizer API manual Version 7.0 (Revision 141)

Optimizer API for Python - Documentation - Mosek

Optimizer API for Python - Documentation - Mosek

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

370 APPENDIX A. <strong>API</strong> REFERENCE<br />

A.5 Dispose and garbage collection<br />

<strong>The</strong> garbage collecter in <strong>Python</strong> will automatically dispose and reuse both Task and Env objects, but<br />

since these objects may allocate substantial amounts of memory or reserve <strong>MOSEK</strong> licenses outside<br />

<strong>Python</strong>, in some cases it is desireable to explicitly free up this memory when the task or environment<br />

will not be used anymore.<br />

<strong>The</strong> native memory associated with Task and Env can be free’d by calling the del () method:<br />

task. del ()<br />

env. del ()<br />

Notice that even if an Env is disposed before all Tasks that belongs to it were disposed, its memory<br />

will not be free’d before that last task is disposed.<br />

A.6 All functions by name<br />

Task.analyzenames<br />

Analyze the names and issue an error for the first invalid name.<br />

Task.analyzeproblem<br />

Analyze the data of a task.<br />

Task.analyzesolution<br />

Print information related to the quality of the solution.<br />

Task.appendbarvars<br />

Appends a semidefinite variable of dimension dim to the problem.<br />

Task.appendcone<br />

Appends a new cone constraint to the problem.<br />

Task.appendconeseq<br />

Appends a new conic constraint to the problem.<br />

Task.appendconesseq<br />

Appends multiple conic constraints to the problem.<br />

Task.appendcons<br />

Appends a number of constraints to the optimization task.<br />

Task.appendsparsesymmat<br />

Appends a general sparse symmetric matrix to the vector E of symmetric matrixes.<br />

Task.appendstat<br />

Appends a record the statistics file.

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!