Skip to content

Commit

Permalink
cleaning as_dict for Ipopt Options
Browse files Browse the repository at this point in the history
  • Loading branch information
Ipuch authored and pariterre committed Nov 11, 2021
1 parent fde5713 commit ef7c099
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion bioptim/interfaces/SolverOptions.py
Original file line number Diff line number Diff line change
Expand Up @@ -368,8 +368,9 @@ def set_initialization_options(self, val: float):
def as_dict(self, solver):
solver_options = self.__dict__
options = {}
non_python_options = ["_c_compile", "type", "show_online_optim", "show_options"]
for key in solver_options:
if key != "_c_compile" and key != "type" and key != "show_online_optim" and key != "show_options":
if key not in non_python_options:
ipopt_key = "ipopt." + key[1:]
options[ipopt_key] = solver_options[key]
return {**options, **solver.options_common}
Expand Down

0 comments on commit ef7c099

Please sign in to comment.