Skip to content

printing more details about why parameters are at a boundary#197

Closed
andreh7 wants to merge 3 commits into
cms-analysis:slc6-root5.34.17from
andreh7:ah-2015-06-03-more-verbose-parameter-at-boundary-checking
Closed

printing more details about why parameters are at a boundary#197
andreh7 wants to merge 3 commits into
cms-analysis:slc6-root5.34.17from
andreh7:ah-2015-06-03-more-verbose-parameter-at-boundary-checking

Conversation

@andreh7

@andreh7 andreh7 commented Jun 3, 2015

Copy link
Copy Markdown
Contributor
  • split method utils::isParameterAtBoundary(..) into two methods utils::isParameterAtLowerBoundary(..) and utils::isParameterAtUpperBoundary(..)
  • method utils::anyParameterAtBoundaries(..) now prints more details about why a parameter is at a boundary

This has been useful to identify issues where the uncertainty of a parameter became quite big (and thus the parameter was seen to be close to both boundaries).

Example output:

[WARNING] Found [paramXYZ] at both boundaries (value: 3.593620 +8.407840-8.407840 range: -4.472136..4.472136).

…:isParameterAtLowerBoundary(..) and utils::isParameterAtUpperBoundary(..); method utils::anyParameterAtBoundaries(..) now prints more details about why a parameter is at a boundary
@gpetruc

gpetruc commented Jun 30, 2015

Copy link
Copy Markdown
Contributor

@adavidzh since you wrote the original boundary checking, can you check this PR and if it's ok merge it?
Thanks

Comment thread src/utils.cc Outdated

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

This is bugged: should be atUpperBoundary = isParameterAtUpperBoundary.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

On 06/07/15 04:06, André David wrote:

In src/utils.cc
#197 (comment):

@@ -740,14 +757,31 @@ bool utils::anyParameterAtBoundaries( const RooArgSet &params, int verbosity ){

 RooLinkedListIter iter = params.iterator(); int i = 0;
 for (RooRealVar *a = (RooRealVar *) iter.Next(); a != 0; a = (RooRealVar *) iter.Next(), ++i) {

  •    bool isBad = isParameterAtBoundary(*a);
    
  •    bool atLowerBoundary = isParameterAtLowerBoundary(*a);
    
  •    bool atUpperBoundary = isParameterAtLowerBoundary(*a);
    

This is bugged: should be atUpperBoundary = isParameterAtUpperBoundary.

ah.. thanks for spotting this (it didn't reveal itself in my test case
where the parameter
is close to both boundaries). I'll update this.

ah added 2 commits August 27, 2015 17:35
…d isParameterAtLowerBoundary(..) replaced by isParameterAtUpperBoundary(..)
… upper/lower/both boundaries more explicit
@andreypz

andreypz commented Sep 5, 2017

Copy link
Copy Markdown

This would be indeed useful.
Could someone merge it into latest code?

@nucleosynthesis

Copy link
Copy Markdown
Contributor

Although this is quite an old PR, since it merges into 102x, I have pushed it to a PR #550 and will close this one.

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.

5 participants