Skip to content

EXIT: Not enough memory #717

Answered by svigerske
wladimirpetrov asked this question in Q&A
Discussion options

You must be logged in to vote

It's probably nnz_jac_g = -1; that leads to this. Finite difference first-derivative approximation isn't much used, because, well, it usually shouldn't be used. It gives very bad performance. So somewhere it may still try to allocate a vector with length nnz_jac_g and allocating a negative number of bytes produces an error (or it tries to alloc something like INT_MAX-1, for which there is indeed not enough memory).

You can try with nnz_jac_g=0 and nnz_h_lag=0. I don't remember whether the Jacobian approx still needed the sparsity pattern of the Jacobian, though. Do yourself a favor and provide at least first derivatives.

Replies: 2 comments 2 replies

Comment options

You must be logged in to vote
1 reply
@wladimirpetrov
Comment options

Comment options

You must be logged in to vote
1 reply
@wladimirpetrov
Comment options

Answer selected by wladimirpetrov
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants