Bug #14758

Comparison breaks when given 2 data-like and 2-mc like datasets

Added by Erika Catano Mur over 3 years ago. Updated over 3 years ago.

Start date:
Due date:
% Done:


Estimated time:


With a list of 4 data sets ({data,mc}{old,new}, MC split by components) single-dataset plots are ok, but making the comparison plots breaks with error

Traceback (most recent call last):
  File "/nova/app/users/ecatanom/feature_caf_size/feature_branch/Validation/generic/controllers/", line 531, in <module>
  File "/nova/app/users/ecatanom/feature_caf_size/feature_branch/Validation/generic/controllers/", line 322, in MakeCanvases
    if len(set.symmetric_difference(*[category_lists[ds][gp_idx] for ds in category_lists]) ) > 0:
TypeError: symmetric_difference() takes exactly one argument (3 given)

Same folder/name structure used in previous iterations. I moved on to compare only data/data, MC/MC, but other users might find this error.

Associated revisions

Revision 23536 (diff)
Added by Jeremy Wolcott over 3 years ago

Don't assume there will be exactly two sets of plots when making
comparisons. (Fixes Redmine issue #14758.)


#1 Updated by Gavin Davies over 3 years ago

  • Project changed from NOvA-ART to NOvA validation
  • Category deleted (Validation Website)

and this one moves to validation sub-project too

#2 Updated by Jeremy Wolcott over 3 years ago

  • Assignee set to Jeremy Wolcott

Hmm, my fault, didn't read the set.symmetric_difference() method signature carefully enough. Could you try replacing line 322 of controllers/ with:

if len(set.union(*[category_lists[ds][gp_idx] for ds in category_lists])) == len(category_lists[category_lists.keys()[0]][gp_idx]):

and see if it "just works?"

#3 Updated by Jeremy Wolcott over 3 years ago

Test with


#4 Updated by Jeremy Wolcott over 3 years ago

  • Status changed from New to Resolved

Looks like that indeed was the solution. Fixed in novaart:r23536.

#5 Updated by Jeremy Wolcott over 3 years ago

  • Status changed from Resolved to Closed

Also available in: Atom PDF