Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Invalid dimension when warmstart #752

Open
mickaelbegon opened this issue Aug 24, 2023 · 0 comments
Open

Invalid dimension when warmstart #752

mickaelbegon opened this issue Aug 24, 2023 · 0 comments
Assignees

Comments

@mickaelbegon
Copy link
Contributor

In arm_reaching_torque_driven_collocations.py, I tried to do a warm start after 20 iterations of hessian=limited memory.

    sol_socp = socp.solve(solver)

    socp.set_warm_start(sol_socp)

    # sol_socp.graphs()
    solver.set_maximum_iterations(1000)
    solver.set_hessian_approximation("exact")

    sol_socp = socp.solve(solver)

I got the following error.
Is it related to the change in number of controls (last node)?

v_init = interface.ocp.init_vector

File "/Users/mickaelbegon/Documents/GIT/bioptim/bioptim/optimization/optimal_control_program.py", line 819, in init_vector
return OptimizationVectorHelper.init_vector(self)
File "/Users/mickaelbegon/Documents/GIT/bioptim/bioptim/optimization/optimization_vector.py", line 338, in init_vector
nlp.u_init[key].check_and_adjust_dimensions(nlp.controls[key].cx.shape[0], ns - 1)
File "/Users/mickaelbegon/Documents/GIT/bioptim/bioptim/limits/path_conditions.py", line 734, in check_and_adjust_dimensions
self.init.check_and_adjust_dimensions(n_elements, n_shooting, "InitialGuess")
File "/Users/mickaelbegon/Documents/GIT/bioptim/bioptim/limits/path_conditions.py", line 246, in check_and_adjust_dimensions
raise RuntimeError(
RuntimeError: Invalid number of column for InterpolationType.EACH_FRAME (ncols = 80), the expected number of column is 81

@EveCharbie EveCharbie self-assigned this Oct 9, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants