-
-
Notifications
You must be signed in to change notification settings - Fork 42
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
type instability fix #132
type instability fix #132
Conversation
Nice one!
in #131. Sorry for not telling you, but I thought this comment #131 (comment) would trigger a note in #128. |
max_trust_radius::Real = 0.0,
initial_trust_radius::Real = 0.0,
step_threshold::Real = 0.1,
shrink_threshold::Real = 0.25,
expand_threshold::Real = 0.75,
shrink_factor::Real = 0.25,
expand_factor::Real = 2.0, what we really should be doing is change those values to |
Codecov Report
@@ Coverage Diff @@
## master #132 +/- ##
==========================================
+ Coverage 91.00% 91.28% +0.28%
==========================================
Files 7 7
Lines 500 505 +5
==========================================
+ Hits 455 461 +6
+ Misses 45 44 -1
📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more |
hmm, I made the changes suggested by Chris, but I wasn't allowed to push to @daviehh |
You can PR to his branch. |
Hmm something happened with the merge ambiguity fix. It's probably just a simple thing with the type parameters. |
The problem is that step_threshold::trustType <-----------------
shrink_threshold::trustType
expand_threshold::trustType
shrink_factor::trustType
expand_factor::trustType
loss::floatType
loss_new::floatType
H::jType
g::resType
shrink_counter::Int
step_size::suType <-----------------
u_tmp::tmpType
fu_new::resType
make_new_J::Bool
r::floatType
function TrustRegionCache{iip}(f::fType, alg::algType, u::uType, fu::resType, p::pType,
uf::ufType, linsolve::L, J::jType,
jac_config::JC, iter::Int,
force_stop::Bool, maxiters::Int, internalnorm::INType,
retcode::SciMLBase.ReturnCode.T, abstol::tolType,
prob::probType, trust_r::trustType,
max_trust_r::trustType, step_threshold::suType, <-----------------
shrink_threshold::trustType, expand_threshold::trustType,
shrink_factor::trustType, expand_factor::trustType,
loss::floatType, loss_new::floatType, H::jType,
g::resType, shrink_counter::Int, step_size::uType, <-----------------
u_tmp::tmpType, fu_new::resType, make_new_J::Bool, Unfortunately I got no time to fix it right now, but if its not fixed in ~8h I'll have time to do it |
Tentative PR for the type instability/runtime dispatch and the resulting long loading time, may fix #128
Maybe it may be handled in a more clean/elegant fashion..
Also, since
eltype(<:Number)
just returns the type of the number, the linemaybe just changed to
u_elType = eltype(u)
. Not sure how robust it can be