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

Keep non-array connector variable collected #296

Merged
merged 4 commits into from
Jun 10, 2024
Merged

Conversation

baggepinnen
Copy link
Contributor

The PR

was breaking, in particular, the removal of

u = collect(u)

from RealInput and RealOutput broke Multibody.jl

Since we have both RealInput and RealInputArray, where the latter is using symbolic arrays, I propose that we keep the old behavior of RealInput intact, i.e., revert the breaking change.

Copy link

codecov bot commented May 16, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 51.57%. Comparing base (200b13a) to head (f4ada5b).
Report is 2 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main     #296      +/-   ##
==========================================
- Coverage   61.56%   51.57%   -9.99%     
==========================================
  Files          46       46              
  Lines        1470     1778     +308     
==========================================
+ Hits          905      917      +12     
- Misses        565      861     +296     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@AayushSabharwal
Copy link
Member

I think tests might fail here. The reason to not scalarize this is so that the non-scalarized form is available through guesses. Once tests pass here, I'll also run MTK tests (using SciML/ModelingToolkit.jl#2676) with this checked out, since it has the potential to break those too

@baggepinnen
Copy link
Contributor Author

The reason to not scalarize this is so that the non-scalarized form is available through guesses.

Why is this needed, wouldn't using RealOutputArray be an option if you need the non-scalarized version?

@baggepinnen
Copy link
Contributor Author

Regarding the test failure here

  LoadError: Initial condition underdefined. Some are missing from the variable map.
  Please provide a default (`u0`), initialization equation, or guess
  for the following variables:
  
  Any[P₊input₊u(t)]

I have tests passing locally on the https://github.com/AayushSabharwal/ModelingToolkit.jl/tree/as/linearization-initialization branch of MTK so this PR will have to wait on

@baggepinnen
Copy link
Contributor Author

tests are passing on MTK master branch

@baggepinnen baggepinnen reopened this Jun 10, 2024
@baggepinnen baggepinnen merged commit 6ed304b into main Jun 10, 2024
7 of 16 checks passed
@baggepinnen baggepinnen deleted the baggepinnen-patch-1 branch June 10, 2024 05:00
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.

2 participants