-
Notifications
You must be signed in to change notification settings - Fork 6
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
Remove solver_.parameters_ #668
Conversation
I do see some calls where solver.solver_.parameters_ is not being modifiedbut rather the value is getting used. Example: EXPECT_EQ(solver.solver_.parameters_.absolute_tolerance_[state.variable_map_["Ar"]], 1.0e-12); I am unsure if we need to change these as well? |
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #668 +/- ##
==========================================
+ Coverage 94.09% 94.38% +0.29%
==========================================
Files 63 63
Lines 4281 4294 +13
==========================================
+ Hits 4028 4053 +25
+ Misses 253 241 -12 ☔ View full report in Codecov by Sentry. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Right direction, but we still have some more work to do. Any mechanism-specific thing (like tolerances) need to be moved somewhere else. We should spend some time figuring out where they need to go. Also, the parameters need to be any set of paramters (rosenbrock, backward euler, etc.)
d059401
to
32a16e2
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks @montythind for working on this PR. I observed the following failures on Derecho:
15 - cuda_rosenbrock (SEGFAULT)
31 - rosenbrock (SEGFAULT)
45 - regression_test_solve (NUMERICAL)
46 - chapman_integration (SEGFAULT)
47 - analytical_rosenbrock_integration (NUMERICAL)
48 - analytical_backward_euler (NUMERICAL)
49 - terminator (NUMERICAL)
50 - integrated_reaction_rates (NUMERICAL)
52 - README_example (NUMERICAL)
53 - solve_results (NUMERICAL)
54 - multiple_grid_cells (NUMERICAL)
55 - rate_constants_no_user_defined_example_by_hand (NUMERICAL)
56 - rate_constants_user_defined_example_by_hand (NUMERICAL)
57 - solver_configuration (NUMERICAL)
59 - rate_constants_no_user_defined_example_with_config (NUMERICAL)
60 - rate_constants_user_defined_example_with_config (NUMERICAL)
61 - carbon_bond_5_example (NUMERICAL)
62 - chapman_example (NUMERICAL)
63 - robertson_example (NUMERICAL)
64 - ts1_example (NUMERICAL)
I am not sure what happened but after my latest pull and merge- lot of tests failed. I am looking what caused the test failures |
… into allowSolversToModify_621
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks @K20shores and @montythind for working on this and addressing all my comments. It looks great to me and I could confirm that all the CPU & GPU tests pass on Derecho.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks great! Just one minor question, but nothing that should hold up merging
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good! I just have a couple questions and suggestions.
This PR includes moving Parameters
absolute tolerance and relative tolearnce to state from solver
Note:
I have left
std::vector absolute_tolerance_;
double relative_tolerance_{ 1e-6 };
in rosenbrock_solver_prarameter.hpp as the CUDA tests are failing because tolerance doesnt get copied over to the device. Issue occurs in CudaRosenbrockSolver constructor when doing this->parameters_.absolute_tolerance_.size(); it comes out as zero
We can potential get rid of this line in solver_builder.inl. This is also a temporary. solution.
options.absolute_tolerance_ = state_parameters.absolute_tolerance_;
Along with that i have commented out unit tests till we don't have a solution how to deal with tolerance.
closes #621