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

feat: support initializeprobpmap in relevant SciMLFunctions #760

Merged
merged 6 commits into from
Oct 7, 2024

Conversation

AayushSabharwal
Copy link
Member

Checklist

  • Appropriate tests were added
  • Any code changes were done in a way that does not break public API
  • All documentation related to code changes were updated
  • The new code follows the
    contributor guidelines, in particular the SciML Style Guide and
    COLPRAC.
  • Any new documentation only uses public API

Additional context

Add any other context about the problem here.

@ChrisRackauckas
Copy link
Member

why would optimizations have this?

@AayushSabharwal
Copy link
Member Author

It doesn't. Those changes are from the format commit

@AayushSabharwal AayushSabharwal marked this pull request as ready for review October 7, 2024 11:35
@@ -174,6 +174,17 @@ function Base.setproperty!(prob::ODEProblem, s::Symbol, v, order::Symbol)
Base.setfield!(prob, s, v, order)
end

function ConstructionBase.constructorof(::Type{P}) where {P <: ODEProblem}
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

why is this needed?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

For SciML/DiffEqBase.jl#1070, but it might not be now.

use_defaults = false,
_kwargs...)
if tspan === missing
tspan = prob.tspan
end

newu0, newp = updated_u0_p(prob, u0, p; interpret_symbolicmap, use_defaults)
newu0, newp = updated_u0_p(prob, u0, p, tspan[1]; interpret_symbolicmap, use_defaults)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

is this breaking downstream?

@@ -693,7 +716,8 @@ function _updated_u0_p_symmap(prob, u0, ::Val{true}, p, ::Val{true})
remake_buffer(prob, parameter_values(prob), keys(p), values(p))
end

function updated_u0_p(prob, u0, p; interpret_symbolicmap = true, use_defaults = false)
function updated_u0_p(
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nope it's here

@ChrisRackauckas ChrisRackauckas merged commit 16815db into SciML:master Oct 7, 2024
35 of 43 checks passed
@AayushSabharwal AayushSabharwal deleted the as/param-init branch October 7, 2024 13:01
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