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
Range checking for vector parameters #3989
Conversation
Results of testing ee84d05 using moose_PR_pre_check recipe: Passed on: linux-gnu View the results here: https://www.moosebuild.com/view_job/6201 |
Results of testing ee84d05 using moose_PR_test_dbg recipe: Passed on: linux-gnu View the results here: https://www.moosebuild.com/view_job/6203 |
Results of testing ee84d05 using moose_PR_test recipe: Passed on: linux-gnu View the results here: https://www.moosebuild.com/view_job/6202 |
Nicely done, I wonder if we should pull the range checking stuff from the parser completely. We don't have to do that here, just tossing that out there. With this PR we are doing checks for vector stuff only in InputParameters, but we are doing checks for scalars in both places. It's just inconsistent. |
Yeah, I forgot about the other place. Why is the stuff checked twice?
|
There's actually not a really good reason. I added it to the parser first, because it was natural to do it while you're filling in the the parameters. You've already dynamic casted everything and you're sitting there with the parameters in hand. The problem arises when people skip using the parser and just build an object programmatically. I went back and added code to do it later in the InputParameters class during a manual sanity check. I suppose that's good enough... Just didn't want to delete all my precious code out of the Parser but we probably should. |
Results of testing 135b357 using moose_PR_pre_check recipe: Passed on: linux-gnu View the results here: https://www.moosebuild.com/view_job/6213 |
Results of testing 135b357 using moose_PR_test recipe: Passed on: linux-gnu View the results here: https://www.moosebuild.com/view_job/6214 |
Results of testing 135b357 using moose_PR_test_dbg recipe: Passed on: linux-gnu View the results here: https://www.moosebuild.com/view_job/6215 |
Added the tests for other types (I meant to do that at least for int, but messed up the material params). And voila, the test for the |
Is this a pop quiz? Where is the change set? |
Oops forgot to push. Am in tetonia now.
|
You can't be in Tetonia. In the time it took you to type that message you would have already passed through. :) |
Results of testing cbc3e17 using moose_PR_pre_check recipe: Passed on: linux-gnu View the results here: https://www.moosebuild.com/view_job/6216 |
Results of testing cbc3e17 using moose_PR_test recipe: Failed on: linux-gnu View the results here: https://www.moosebuild.com/view_job/6217 |
Results of testing cbc3e17 using moose_PR_test_dbg recipe: Failed on: linux-gnu View the results here: https://www.moosebuild.com/view_job/6218 |
The problem seems to be that the vector is read in with size 0! (which coincidentally skips range checking entirely... that is another bug) Also, there are no uses of a |
Uhm, yeah, vectors of long are not implemented. I'm adding them in the next commit :-/ |
That means that nobody has ever needed them. Most vector parameters are Real values in MOOSE. |
Sure, but adding them costs a single line (that could have saved me quite some confusion). |
Results of testing 0c66414 using moose_PR_pre_check recipe: Passed on: linux-gnu View the results here: https://www.moosebuild.com/view_job/6225 |
Results of testing 0c66414 using moose_PR_test recipe: Passed on: linux-gnu View the results here: https://www.moosebuild.com/view_job/6226 |
Results of testing 0c66414 using moose_PR_test_dbg recipe: Passed on: linux-gnu View the results here: https://www.moosebuild.com/view_job/6227 |
Please don't merge yet |
Results of testing 041ef39 using moose_PR_pre_check recipe: Passed on: linux-gnu View the results here: https://www.moosebuild.com/view_job/6228 |
Results of testing 041ef39 using moose_PR_test recipe: Passed on: linux-gnu View the results here: https://www.moosebuild.com/view_job/6229 |
Results of testing 041ef39 using moose_PR_test_dbg recipe: Passed on: linux-gnu View the results here: https://www.moosebuild.com/view_job/6230 |
I wonder if I should make the dimensions of the simulation domain available in the check expression. LIBMESH_DIM seems to be a compiled in maximum dimension, is there a standard way to get the problem dimension? ( And is this actually desired? |
If the inventor can't think of a use case for his thingy, maybe we don't need it (even if it is cool)? |
I'm not questioning the usefulness for the range checking at all, I already have use cases. I'm just wondering if I should make the dimension available to allow for vector length checks against problem dimension. I.e. a point needs at least dim entries (or do we have Point type parameters that can already do that?) |
How do you know if it has "dim" number of entries? All Points, On Monday, October 6, 2014, Daniel Schwen notifications@github.com wrote:
|
We have cases, where any number of entries is accepted and all missing entries up to the third (hardcoded of course) are zero padded. I'm not terribly excited by that. |
My point is that this check happens on a Point object, not on the On Tue, Oct 7, 2014 at 7:18 AM, Daniel Schwen notifications@github.com
|
Range checking for vector parameters
Comprehensive range (and length) checking for vector parameters (closes #3988).