SQP_WITH_FEASIBLE_QP Error

Hi :wave:
tahnk you very much for creating and mainting acados.
I have used it a lot, but currently i’m running into a problem or possible error.

I’m using the Matlab Interface of Acados.
When i generate my optimization Problem calling AcadosOcpSolver(ocp); with
`ocp.solver_options.nlp_solver_type = ‘SQP_WITH_FEASIBLE_QP’
it doesn’t compile/build and i get the following error message:

Error in AcadosOcp/render_templates (line 1556)
                render_file( in_file, out_file, json_fullfile )
                ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
Error in AcadosOcpSolver/generate (line 538)
            obj.ocp.render_templates()
            ^^^^^^^^^^^^^^^^^^^^^^^^^^
Error in AcadosOcpSolver (line 114)
                obj.generate();
                ^^^^^^^^^^^^^^

I’have tried it both with Acados Versions 0.5.2 and 0.5.3 but the error happens in both versions.
When i use ocp.solver_options.nlp_solver_type = 'SQP' the solver compiles/builds without error.

Here are some of the settings i’m using:

ocp.solver_options.nlp_solver_type = 'SQP_WITH_FEASIBLE_QP';    
ocp.solver_options.qp_solver = 'PARTIAL_CONDENSING_HPIPM';      
ocp.solver_options. qp_solver_cond_N = 10;                        
ocp.solver_options.hessian_approx = 'EXACT';                    
ocp.solver_options.regularize_method = 'MIRROR'; 
ocp.solver_options.globalization = 'MERIT_BACKTRACKING';        
ocp.solver_options.nlp_solver_max_iter = 50;          
ocp.solver_options.qp_solver_iter_max = 200;                    
ocp.solver_options.nlp_solver_warm_start_first_qp = 1;          
ocp.solver_options.qp_solver_warm_start = 1;

Am I missing something? Is SQP_WITH_FEASIBLE_QP not compatible with these settings or is is something else?

Any help will be much appreciated!.

Hi :waving_hand:

this is indeed strange behaviour. Could you checkout the most up to date version of acados from the main branch, recompile acados, run the example again and share the .json file that is generated when trying to create the solver.

Thanks,
Katrin

Hi @MKM ,

I fixed SQP_WITH_FEASIBLE_QP in Matlab in this PR: Matlab: fix and test SQP_WITH_FEASIBLE_QP by FreyJo · Pull Request #1762 · acados/acados · GitHub
Please update your acados version and let us know if it works :slight_smile:

Best,
Jonathan

1 Like

Hi Jonathan,

The PR seems to fix it, thank you :slight_smile: