Repository navigation
feat(python): bind the raw-line calls and the load Jacobians - #95
Conversation
|
@codex review |
Codex Review Summary: ✅ CompletedThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
|
Codex Review: Didn't find any major issues. Keep them coming! Reviewed commit: ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
If Codex has suggestions, it will comment; otherwise it will react with 👍. Codex can also answer questions or update the PR. Try commenting "@codex address that feedback". |
Bind CableDyn_InitLine, CableDyn_InitLines and CableDyn_CalcOutputDerivatives on CableDyn as init_line, init_lines and calc_output_derivatives. The arrays are checked for shape, finiteness and integer indices before the library is called; the library judges the values. Indices stay 1-based as in the C API. A failed call keeps the book-keeping of a model that survives it and drops that of one that does not. The Jacobians are read column-major, so J[i, j] is the derivative of load i with respect to coupled DOF j. The unused eps_fd argument is not exposed. Raw lines match the same lines from a deck over a prescribed motion, also at a shared point, and the Jacobians match finite differences of update_states and calc_output. Signed-off-by: Jae Hoon Seo <jaehoon.seo@inha.ac.kr>
Signed-off-by: Jae Hoon Seo <jaehoon.seo@inha.ac.kr>
f43f2cf to
5078972
Compare
|
@codex review |
|
Codex Review: Didn't find any major issues. Swish! Reviewed commit: ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
If Codex has suggestions, it will comment; otherwise it will react with 👍. Codex can also answer questions or update the PR. Try commenting "@codex address that feedback". |
Summary
The Python package did not bind
CableDyn_InitLine,CableDyn_InitLinesandCableDyn_CalcOutputDerivatives.CableDynnow hasinit_line,init_linesandcalc_output_derivatives. Arguments follow the C API, with shape, finiteness and dtype checked in Python before the call; the library judges value ranges.calc_output_derivativesreturns(loads, dload_dq, dload_dv, dload_da, added_mass).Checks
64 tests in
python/tests/test_raw_lines.py:rho_inf0, 0.4 and 0.8, and 100 steps at a shared point. Loads match to 1e-8 relative.update_statesandcalc_output, on four line states, a shared point, and a floater with hydrodynamics.CTest 359 of 359 on the default kernel and with
OPENBLAS_CORETYPE=Prescott.The CHANGELOG entry lands with the release batch.