-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
Add a function in material base class to check whether a property is active #26696
Conversation
c6878db
to
cc46c1d
Compare
I think this is ready for review. @lindsayad and @NamjaeChoi |
Job Documentation on 4246721 wanted to post the following: View the site here This comment will be updated on new commits. |
Job Coverage on 4246721 wanted to post the following: Framework coverage
Modules coverageRay tracing
Full coverage reportsReports
This comment will be updated on new commits. |
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.
you set the status, but you dont use it. Didnt you mean to try to skip material property evaluations for inactive properties?
Yes. I only tested the function but I did not create a material use the function to skip evaluations. Actually I can make the derived test material I added in this PR do the skip. |
cc46c1d
to
43ca4a9
Compare
c750091
to
cdd6371
Compare
I also added more protection when calling |
@NamjaeChoi can you test this out with your PR in Griffin? |
52d97e7
to
212304d
Compare
Added some documentation. |
212304d
to
87b3f03
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.
@lindsayad should we have a meeting on this?
Seems like we should figure out how to turn this extra work of keeping track which properties are active into some sort of optimization in moose not just in derived apps
87b3f03
to
80a7c1d
Compare
I think this has to be in |
Wait a moment... looks like MOOSE will call |
Looks good! Thanks Alex. |
The last commit will need patches for apps due to the interface change. I think having efficient |
Nothing a little c++ can't handle |
The more I think about this the more I think we should just query the problem for whether a material property ID is active as opposed to doing these |
63f34b2
to
e6c98ae
Compare
There is one thing in |
e6c98ae
to
c19d4e4
Compare
Ok you can see my follow-on commits in this PR that consolidates the active material property storage onto the materials. To keep CI clean this should be a two-stage process. Stage 1 will be to get #26720 merged. I then have a Griffin patch ready to go that will switch to the new |
97bf2ee
to
5ba3795
Compare
@lindsayad your change in Griffin has been merged into Griffin master. |
👍 I'll fixup this PR momentarily |
This allows for O(1) insertion of individual elements as opposed to O(log(N)). Similarly when marking active material properties in a given material this allows us to do a O(N) loop over the likely <= size of the supplied properties and do a O(1) search in the `needed_mat_props`
5ba3795
to
ce764c9
Compare
This should be ready for further review. Forward compatible relap-7 patch is here. Hopefully will get merged early tomorrow and then we can invalidate the failing targets here |
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.
it would be good to have some numbers to justify the optimization at some point @YaqiWang but no rush, this can come just for reporting in the TA report. thanks!
Co-authored-by: Guillaume Giudicelli <guillaume.giudicelli@gmail.com>
thanks for the review! |
Really appreciate the helps! |
Closes #26675.