|
[Rivet] Query/fix on behaviour of plotparserJonathan Butterworth J.Butterworth at ucl.ac.ukFri Aug 18 14:48:25 BST 2017
Hi all, A while ago I mentioned that I was having problems with rivet apparently not respecting the users' choice of paths for plotinfo files. Specifically, ATLAS_2012_I1203852.plot is buggy in the rivet release and this causes problems for Contur, in that the plotparser we use doesn't appear to pick up our fixed version of our file. (A fix has also been committed to rivet.) The relevant file in rivet is plotinfo.py The problem is not that the path isn't known to rivet, but that the loop in the getSection method continues and reads all versions of the plotinfo file that it finds. The problem then is; - it reads the user version first, which is then potentially overwritten by the official (buggy) version. I tried reversing the loop direction (there's even a comment already there to this effect) but then there is still the case that - if the problem with the official version is actually an unwanted attribute, this won't get overwritten/removed by the fixed version anyway. ... which is actually the problem here. I have attached a version of plotinfo.py which works for contur now because it reads only the first valid plotinfo file it finds which is the users version. (The user also can still feed extra files to this method, which will be also searched for plot attributes.) However, this isn't a simple bug fix, it is a change in behaviour, which might have implications elsewhere so I thought I should consult here before committing. If no one care enough to comment, I'll commit it anyway, since this seems like the optimal behaviour to me. Cheers, Jon Cheers, Jon -- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Prof. Jonathan Butterworth, http://www.hep.ucl.ac.uk/~jmb/ Head, Physics and Astronomy Department Tel: +44 20 7679 3444 University College London Gower St, London WC1E 6BT, UK ATLAS, CERN Tel: +41 22 76 72340 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -------------- next part -------------- A non-text attachment was scrubbed... Name: plotinfo.py Type: text/x-python-script Size: 7949 bytes Desc: not available URL: <https://www.hepforge.org/lists-archive/rivet/attachments/20170818/32d6ff31/attachment.bin>
More information about the Rivet mailing list |