Skip to content

dev-examodels#51

Merged
jbcaillau merged 60 commits into
mainfrom
47-dev-examodels
May 11, 2025
Merged

dev-examodels#51
jbcaillau merged 60 commits into
mainfrom
47-dev-examodels

Conversation

@jbcaillau

Copy link
Copy Markdown
Member

closes #47

@jbcaillau jbcaillau linked an issue May 4, 2025 that may be closed by this pull request
21 tasks
@github-actions

github-actions Bot commented May 4, 2025

Copy link
Copy Markdown
Contributor

Breakage test results
Date: 2025-05-11 23:29:58

Name Latest Stable
OptimalControl.jl compat: v0.2.5 compat: v0.2.5

@jbcaillau

Copy link
Copy Markdown
Member Author

@ocots two things:

  • there is a version conflict for CTBase (0.15 / 0.16) detected by OptimalControl breakage: update to do?
    IMG_4273
  • it is a bit strange to see the breakage in green in the CI while it fails... but OK
    IMG_4274

@ocots

ocots commented May 4, 2025

Copy link
Copy Markdown
Member

As we said before, it is green in the CI since the action passed. The result of the action is a different thing. It is not because their is a break that you don't want to merge.

@ocots

ocots commented May 4, 2025

Copy link
Copy Markdown
Member

It is normal that there is a conflict since CTParser uses CTBase 0.16 and OptimalControl 0.15.

@jbcaillau

jbcaillau commented May 4, 2025

Copy link
Copy Markdown
Member Author

As we said before, it is green in the CI since the action passed. The result of the action is a different thing. It is not because their is a break that you don't want to merge.

OK

It is normal that there is a conflict since CTParser uses CTBase 0.16 and OptimalControl 0.15.

yes: is it because you wait for CTDirect to update? in this situation, breakages are useless since they will break just because of a compat issue without running any test

@jbcaillau
jbcaillau marked this pull request as ready for review May 9, 2025 15:58
@jbcaillau

Copy link
Copy Markdown
Member Author

@ocots please review

@jbcaillau
jbcaillau requested a review from ocots May 10, 2025 15:38
@ocots

ocots commented May 10, 2025

Copy link
Copy Markdown
Member

@ocots please review

I do it tonight

@ocots

ocots commented May 10, 2025

Copy link
Copy Markdown
Member

Dans l'ensemble ça me semble ok. Dur de voir les petits bugs s'il y en a. Sinon, je comprends mieux l'idée de la séparation entre ce qui est purement syntaxique du reste, lié au backend. C'est super propre.

Comment thread src/onepass.jl
Comment thread src/onepass.jl
Comment thread src/onepass.jl
@jbcaillau

Copy link
Copy Markdown
Member Author

NB. no CUDA backend (GPU) available on github runners, removing associated test (passes on local GPU for use case no. 1)
https://github.com/control-toolbox/CTParser.jl/actions/runs/14954319794/job/42007954407?pr=51

@jbcaillau

jbcaillau commented May 11, 2025

Copy link
Copy Markdown
Member Author

@amontoison

o = @def begin

            tf  R, variable
            t  [0, tf], time
            x = (r, v, m)  R³, state
            u  R, control

            x(0) == [r0, v0, m0]
            m(tf) == mf
            0.0  u(t)  1.0
            r(t)  r0
            0.0  v(t)  vmax

            (r)(t) == v(t)
            (v)(t) == -Cd * v(t)^2 * exp(-β * (r(t) - 1)) / m(t) - 1 / r(t)^2 + u(t) * Tmax / m(t)
            (m)(t) == -b * Tmax * u(t)

            r(tf)  max

end

m = o(; backend = backend, grid_size = N, init = (tfs, xs, us))
s = madnlp(m)

This is MadNLP version v0.8.7, running with cuDSS v0.4.0

Number of nonzeros in constraint Jacobian............:     3804
Number of nonzeros in Lagrangian Hessian.............:    12200

Total number of variables............................:      805
                     variables with only lower bounds:      201
                variables with lower and upper bounds:      402
                     variables with only upper bounds:        0
Total number of equality constraints.................:      604
Total number of inequality constraints...............:        0
        inequality constraints with only lower bounds:        0
   inequality constraints with lower and upper bounds:        0
        inequality constraints with only upper bounds:        0

iter    objective    inf_pr   inf_du lg(mu)  ||d||  lg(rg) alpha_du alpha_pr  ls
   0 -1.2354900e+00 1.84e-01 2.00e+00  -1.0 0.00e+00    -  0.00e+00 0.00e+00   0
  ...
  21 -1.0125790e+00 6.64e-09 1.51e-08  -8.0 1.30e-02    -  1.00e+00 1.00e+00h  1

Number of Iterations....: 21

                                   (scaled)                 (unscaled)
Objective...............:  -1.0125790380561310e+00   -1.0125790380561310e+00
Dual infeasibility......:   1.5104139593169075e-08    1.5104139593169075e-08
Constraint violation....:   6.6388111075860760e-09    6.6388111075860760e-09
Complementarity.........:   9.3565895240163475e-09    9.3565895240163475e-09
Overall NLP error.......:   1.5104139593169075e-08    1.5104139593169075e-08

@jbcaillau
jbcaillau merged commit 5f64b56 into main May 11, 2025
@jbcaillau
jbcaillau deleted the 47-dev-examodels branch May 11, 2025 21:55
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

Successfully merging this pull request may close these issues.

[Dev] examodels

2 participants