Merge lp:~maddevelopers/mg5amcnlo/improved_scale_pdf_handling into lp:~maddevelopers/mg5amcnlo/2.3.4
- improved_scale_pdf_handling
- Merge into 2.3.4
Status: | Merged |
---|---|
Merged at revision: | 367 |
Proposed branch: | lp:~maddevelopers/mg5amcnlo/improved_scale_pdf_handling |
Merge into: | lp:~maddevelopers/mg5amcnlo/2.3.4 |
Diff against target: |
13202 lines (+4853/-3868) (has conflicts) 107 files modified
Template/NLO/Cards/run_card.dat (+46/-52) Template/NLO/FixedOrderAnalysis/HwU.f (+7/-8) Template/NLO/FixedOrderAnalysis/HwU.inc (+2/-2) Template/NLO/MCatNLO/HWAnalyzer/hw6an_HwU_pp_V.f (+1/-5) Template/NLO/MCatNLO/HWAnalyzer/hw6an_HwU_pp_h.f (+1/-5) Template/NLO/MCatNLO/HWAnalyzer/hw6an_HwU_pp_hjj.f (+1/-5) Template/NLO/MCatNLO/HWAnalyzer/hw6an_HwU_pp_leptons.f (+1/-5) Template/NLO/MCatNLO/HWAnalyzer/hw6an_HwU_pp_lplm.f (+1/-5) Template/NLO/MCatNLO/HWAnalyzer/hw6an_HwU_pp_lvl.f (+1/-5) Template/NLO/MCatNLO/HWAnalyzer/hw6an_HwU_pp_taptam.f (+1/-5) Template/NLO/MCatNLO/HWAnalyzer/hw6an_HwU_pp_tj.f (+1/-5) Template/NLO/MCatNLO/HWAnalyzer/hw6an_HwU_pp_ttx.f (+1/-5) Template/NLO/MCatNLO/HWAnalyzer/hw6an_HwU_pp_ttx_v2.f (+1/-5) Template/NLO/MCatNLO/HWAnalyzer/hw6an_HwU_rates.f (+1/-5) Template/NLO/MCatNLO/HWAnalyzer/mcatnlo_hwan_pp_V.f (+1/-2) Template/NLO/MCatNLO/HWAnalyzer/mcatnlo_hwan_pp_h.f (+1/-2) Template/NLO/MCatNLO/HWAnalyzer/mcatnlo_hwan_pp_hjj.f (+1/-2) Template/NLO/MCatNLO/HWAnalyzer/mcatnlo_hwan_pp_leptons.f (+1/-2) Template/NLO/MCatNLO/HWAnalyzer/mcatnlo_hwan_pp_lplm.f (+1/-2) Template/NLO/MCatNLO/HWAnalyzer/mcatnlo_hwan_pp_lvl.f (+1/-2) Template/NLO/MCatNLO/HWAnalyzer/mcatnlo_hwan_pp_taptam.f (+1/-2) Template/NLO/MCatNLO/HWAnalyzer/mcatnlo_hwan_pp_tj.f (+1/-2) Template/NLO/MCatNLO/HWAnalyzer/mcatnlo_hwan_pp_ttx.f (+1/-2) Template/NLO/MCatNLO/HWAnalyzer/mcatnlo_hwan_pp_ttx_v2.f (+1/-2) Template/NLO/MCatNLO/HWAnalyzer/mcatnlo_hwan_rates.f (+1/-2) Template/NLO/MCatNLO/PY8Analyzer/mcatnlo_pyan_pp_V_hepmc.f (+3/-5) Template/NLO/MCatNLO/PY8Analyzer/mcatnlo_pyan_pp_h_hepmc.f (+4/-5) Template/NLO/MCatNLO/PY8Analyzer/mcatnlo_pyan_pp_hjj_hepmc.f (+3/-5) Template/NLO/MCatNLO/PY8Analyzer/mcatnlo_pyan_pp_leptons_hepmc.f (+3/-5) Template/NLO/MCatNLO/PY8Analyzer/mcatnlo_pyan_pp_lplm_hepmc.f (+3/-5) Template/NLO/MCatNLO/PY8Analyzer/mcatnlo_pyan_pp_lvl_hepmc.f (+3/-5) Template/NLO/MCatNLO/PY8Analyzer/mcatnlo_pyan_pp_taptam_hepmc.f (+3/-5) Template/NLO/MCatNLO/PY8Analyzer/mcatnlo_pyan_pp_tj_hepmc.f (+3/-5) Template/NLO/MCatNLO/PY8Analyzer/mcatnlo_pyan_pp_ttx_hepmc.f (+3/-5) Template/NLO/MCatNLO/PY8Analyzer/mcatnlo_pyan_pp_ttx_v2_hepmc.f (+3/-5) Template/NLO/MCatNLO/PY8Analyzer/mcatnlo_pyan_rates_hepmc.f (+3/-5) Template/NLO/MCatNLO/PY8Analyzer/py8an_HwU_pp_V.f (+6/-13) Template/NLO/MCatNLO/PY8Analyzer/py8an_HwU_pp_h.f (+7/-14) Template/NLO/MCatNLO/PY8Analyzer/py8an_HwU_pp_hjj.f (+7/-14) Template/NLO/MCatNLO/PY8Analyzer/py8an_HwU_pp_leptons.f (+7/-14) Template/NLO/MCatNLO/PY8Analyzer/py8an_HwU_pp_lplm.f (+7/-14) Template/NLO/MCatNLO/PY8Analyzer/py8an_HwU_pp_lvl.f (+7/-14) Template/NLO/MCatNLO/PY8Analyzer/py8an_HwU_pp_taptam.f (+7/-14) Template/NLO/MCatNLO/PY8Analyzer/py8an_HwU_pp_tj.f (+7/-14) Template/NLO/MCatNLO/PY8Analyzer/py8an_HwU_pp_ttx.f (+7/-14) Template/NLO/MCatNLO/PY8Analyzer/py8an_HwU_pp_ttx_v2.f (+7/-14) Template/NLO/MCatNLO/PY8Analyzer/py8an_HwU_rates.f (+7/-14) Template/NLO/MCatNLO/PYAnalyzer/mcatnlo_pyan_pp_V.f (+1/-2) Template/NLO/MCatNLO/PYAnalyzer/mcatnlo_pyan_pp_h.f (+1/-2) Template/NLO/MCatNLO/PYAnalyzer/mcatnlo_pyan_pp_hjj.f (+1/-2) Template/NLO/MCatNLO/PYAnalyzer/mcatnlo_pyan_pp_leptons.f (+1/-2) Template/NLO/MCatNLO/PYAnalyzer/mcatnlo_pyan_pp_lplm.f (+1/-2) Template/NLO/MCatNLO/PYAnalyzer/mcatnlo_pyan_pp_lvl.f (+1/-2) Template/NLO/MCatNLO/PYAnalyzer/mcatnlo_pyan_pp_taptam.f (+1/-2) Template/NLO/MCatNLO/PYAnalyzer/mcatnlo_pyan_pp_tj.f (+1/-2) Template/NLO/MCatNLO/PYAnalyzer/mcatnlo_pyan_pp_ttx.f (+1/-2) Template/NLO/MCatNLO/PYAnalyzer/mcatnlo_pyan_pp_ttx_v2.f (+1/-2) Template/NLO/MCatNLO/PYAnalyzer/mcatnlo_pyan_rates.f (+1/-2) Template/NLO/MCatNLO/PYAnalyzer/py6an_HwU_pp_V.f (+1/-5) Template/NLO/MCatNLO/PYAnalyzer/py6an_HwU_pp_h.f (+1/-5) Template/NLO/MCatNLO/PYAnalyzer/py6an_HwU_pp_hjj.f (+1/-5) Template/NLO/MCatNLO/PYAnalyzer/py6an_HwU_pp_leptons.f (+1/-5) Template/NLO/MCatNLO/PYAnalyzer/py6an_HwU_pp_lplm.f (+1/-5) Template/NLO/MCatNLO/PYAnalyzer/py6an_HwU_pp_lvl.f (+1/-5) Template/NLO/MCatNLO/PYAnalyzer/py6an_HwU_pp_taptam.f (+1/-5) Template/NLO/MCatNLO/PYAnalyzer/py6an_HwU_pp_tj.f (+1/-5) Template/NLO/MCatNLO/PYAnalyzer/py6an_HwU_pp_ttx.f (+1/-5) Template/NLO/MCatNLO/PYAnalyzer/py6an_HwU_pp_ttx_v2.f (+1/-5) Template/NLO/MCatNLO/PYAnalyzer/py6an_HwU_rates.f (+1/-5) Template/NLO/MCatNLO/include/LHEFRead.h (+16/-51) Template/NLO/MCatNLO/srcHerwig/madfks_hwlhin.f (+54/-204) Template/NLO/MCatNLO/srcPythia/madfks_pylhin.f (+54/-201) Template/NLO/MCatNLO/srcPythia8/Pythia8.cc (+4/-3) Template/NLO/MCatNLO/srcPythia8/Pythia82.cc (+4/-3) Template/NLO/Source/PDF/pdfwrap.f (+27/-0) Template/NLO/Source/PDF/pdg2pdf_lhapdf.f (+7/-13) Template/NLO/Source/PDF/pdg2pdf_lhapdf6.f (+8/-15) Template/NLO/Source/run.inc (+4/-4) Template/NLO/Source/setrun.f (+29/-0) Template/NLO/SubProcesses/c_weight.inc (+1/-1) Template/NLO/SubProcesses/collect_events.f (+29/-10) Template/NLO/SubProcesses/fks_singular.f (+118/-69) Template/NLO/SubProcesses/handling_lhe_events.f (+343/-539) Template/NLO/SubProcesses/madfks_plot.f (+150/-95) Template/NLO/SubProcesses/makefile (+5/-0) Template/NLO/SubProcesses/reweight0.inc (+22/-5) Template/NLO/SubProcesses/reweightNLO.inc (+0/-5) Template/NLO/SubProcesses/reweight_xsec_events.f (+345/-472) Template/NLO/SubProcesses/setscales.f (+6/-2) UpdateNotes.txt (+5/-0) madgraph/interface/amcatnlo_run_interface.py (+251/-192) madgraph/interface/common_run_interface.py (+56/-51) madgraph/interface/madevent_interface.py (+2/-2) madgraph/interface/madgraph_interface.py (+2/-2) madgraph/interface/madweight_interface.py (+2/-2) madgraph/interface/reweight_interface.py (+2/-2) madgraph/madevent/gen_crossxhtml.py (+6/-1) madgraph/various/banner.py (+199/-54) madgraph/various/histograms.py (+1627/-233) madgraph/various/misc.py (+2/-2) tests/input_files/IOTestsComparison/IOTest_Histogram/gnuplot_histo_output/HistoOut.HwU (+741/-741) tests/input_files/IOTestsComparison/IOTest_Histogram/gnuplot_histo_output/HistoOut.gnuplot (+152/-280) tests/input_files/madspin_event.lhe (+1/-1) tests/time_db (+301/-182) tests/unit_tests/interface/test_edit_card.py (+8/-0) tests/unit_tests/various/test_banner.py (+56/-2) tests/unit_tests/various/test_histograms.py (+5/-5) Text conflict in Template/NLO/SubProcesses/makefile Text conflict in UpdateNotes.txt Text conflict in tests/time_db |
To merge this branch: | bzr merge lp:~maddevelopers/mg5amcnlo/improved_scale_pdf_handling |
Related bugs: |
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
Olivier Mattelaer | Approve | ||
Valentin Hirschi | Approve | ||
Stefano Frixione | Pending | ||
Review via email: mp+286608@code.launchpad.net |
Commit message
Description of the change
Allow for multiple scale and PDF reweighting via the run_card.dat for NLO runs. Both for fixed order and matching to parton shower. Input is by putting lists for the following parameters in the run_card.
lhaid
dynamical_
reweight_PDF
reweight_scale
Also, instead of just a single factor up and down, also there can be given a list of values using
rw_rscale
rw_fscale
I've linked the python interface of lhapdf6 to the MG5_aMC code and forced this when trying to compute PDF uncertainties from the reweighted event weights. This means that for lhapdf5 (or when 'import lhapdf' did not work for whatever reason) you'll not get automatically the PDF uncertainties printed to the screen. Of course you do still get all the weights in the events or plots. I think this is okay; the automatic computation we had before became unmaintainable, because every time a new PDF set came out, the way of computing the uncertainties needed updating. Better to give no number than a wrong number.
@ Olivier. There is a bit of a dirty trick in common_
@ Valentin. Please have a look particularly at the changes in the histograms.py file. Getting the correct colours for each of the curves has become a bit of a mess. In any case, the plots quickly become unreadable when including multiple scales and PDFs. Not sure if there is a better way of plotting things. Maybe a separate inset for each of the scales and PDFs? ---Although, maybe this can wait.
- 334. By Rikkert Frederix
-
following Stefano's comments, improved the description in the run_card.dat
Valentin Hirschi (valentin-hirschi) wrote : | # |
- 335. By Rikkert Frederix
-
fixed a couple of things following Valentin's suggestions
Rikkert Frederix (frederix) wrote : | # |
Hi Valentin,
Thanks for the review!
> a) It would be nice to be able to define the list with a python syntax like
> range(10)
> [1,2,3]
> [a for a in range(100) if a%2!=0]
> This can simply be done with an 'eval' statement, and Olivier agreed to do
> it.
> So I just wrote that here for reference.
>
I would be kind of against this. This might be *very* unsafe when allowing users to upload a run_card for on-line running. Also, it's not at all obvious to the user why (s)he is allowed to use python syntax in a run_card. And, in general, these will not be very long lists that something like range(..) will be necessary.
> b) The default entry and text for the parameter 'reweight_PDF' and
> 'reweight_scale' is not very clear, especially because in fact they should now
> read ('consider_
> afford to change the name.
> Also the stressing the fact that it should be a list *of booleans* should
> help.
> So all in all, I simply suggest to change it by stressing 'booleans' and using
> the keyword 'variations' instead of 'dependence' which I think is clearer for
> most people (but I might be wrong).
>
> True = reweight_scale ! Reweight to get scale variations using the
> ! rw_rscale and rw_fscale factors. Should be a list of booleans
> ! of length equal to that of the parameter
> 'dynamical_
> ! specifying which scales to include in the variation.
>
> and similarly for 'reweigh_PDF'.
Done.
>
> Also, how can one pick several fixed scales? Is there no other way than
> modifying the code so as to add additional 'fake dynamical' scales which
> always return a constant one?
That's the only way. I don't think there is a clear way to do this via a run_card.
> c) When using built-in pdfs, if I have a list defined for lhaid and
> reweight_PDF (with all reweight_PDF set to False) then the code crashes, which
> is bit annoying.
Fixed.
>
> d) When doing a fixed order analysis, with two PDF sets and only the second of
> which has the PDF variations computed, then the plotting fails with:
>
> RuntimeError : Error in LHAPDF:
> values for all PDF members.
> Please report this bug on https:/
> More information is found in '/Users/
> e_pdf_handling/
> Please attach this file to your report.
Fixed.
>
> d) Otherwise the various runs I did went through fine and I really love the
> summary printout.
> It is very clean. So now that you seem to have streamlined the mapping of the
> lhaid to the pdfset name, would it be considerable to be able to input the
> pdfset name instead of its lhaid in the run_card? (just an idea, of course not
> worth it if not trivial to do).
Well, according to Olivier, it's rather tricky to have a list of strings correctly interpreted in the run_card.dat. Therefore, maybe for a future version...
>
> e) In the context of the PY8 merging systematics branch we talked with Stefan
> and thought it would be nice to add the 'name' attribute to the XML ta...
- 336. By Rikkert Frederix
-
changed madgraph5 to mg5amcnlo in the launchpad paths when an error occurs
- 337. By Rikkert Frederix
-
Improved the warning message if the python interface of lhapdf6 could
not be found/imported.
Valentin Hirschi (valentin-hirschi) wrote : | # |
Hi Rik,
On Sun, Feb 21, 2016 at 2:36 AM, Rikkert Frederix <email address hidden>
wrote:
> Hi Valentin,
>
> Thanks for the review!
>
> > a) It would be nice to be able to define the list with a python syntax
> like
> > range(10)
> > [1,2,3]
> > [a for a in range(100) if a%2!=0]
> > This can simply be done with an 'eval' statement, and Olivier agreed
> to do
> > it.
> > So I just wrote that here for reference.
> >
>
> I would be kind of against this. This might be *very* unsafe when allowing
> users to upload a run_card for on-line running. Also, it's not at all
> obvious to the user why (s)he is allowed to use python syntax in a
> run_card. And, in general, these will not be very long lists that something
> like range(..) will be necessary.
This is very true! A really dangerous potential code-injection security
liability there!
This could be handled correctly by the WebInterface mother so that the
python syntax would be forbidden only for the web runs, but I agree that it
is probably not worth the trouble.
We already have the possibility of using the python syntax for defining the
model scans in the param card (where it is much more useful there than in
this case, I agree), so Olivier, did you make sure that this is forbidden
when running on the Web ?
>
>
> > b) The default entry and text for the parameter 'reweight_PDF' and
> > 'reweight_scale' is not very clear, especially because in fact they
> should now
> > read ('consider_
> cannot
> > afford to change the name.
> > Also the stressing the fact that it should be a list *of booleans* should
> > help.
> > So all in all, I simply suggest to change it by stressing 'booleans' and
> using
> > the keyword 'variations' instead of 'dependence' which I think is
> clearer for
> > most people (but I might be wrong).
> >
> > True = reweight_scale ! Reweight to get scale variations using the
> > ! rw_rscale and rw_fscale factors. Should be a list of
> booleans
> > ! of length equal to that of the parameter
> > 'dynamical_
> > ! specifying which scales to include in the variation.
> >
> > and similarly for 'reweigh_PDF'.
>
> Done.
>
> >
> > Also, how can one pick several fixed scales? Is there no other way than
> > modifying the code so as to add additional 'fake dynamical' scales which
> > always return a constant one?
>
> That's the only way. I don't think there is a clear way to do this via a
> run_card.
I thought so but it is a bit annoying I think because it is quite a common
thing to do.
I can see a couple ways of doing it elegantly but they all break backward
compatibility.
The only acceptable (from a user poitn of view) backward compatible way of
doing it that I can see is to promote the following run_card parameters:
muR_ref_fixed
muF_ref_fixed
muR_over_ref
muF_over_ref
to be lists of equal lengths as well.
Then 'fixed_ren_scale' and 'fixed_fac_scale' would apply only if the
corresponding entry is of length one. (i.e. lists would always be
considered no matter what).
Unfortunately, it might be too complicated to implement for what it is
worth; you are the bette...
Rikkert Frederix (frederix) wrote : | # |
Hi Valentin,
>
> I thought so but it is a bit annoying I think because it is quite a common
> thing to do.
> I can see a couple ways of doing it elegantly but they all break backward
> compatibility.
> The only acceptable (from a user poitn of view) backward compatible way of
> doing it that I can see is to promote the following run_card parameters:
>
> muR_ref_fixed
> muF_ref_fixed
> muR_over_ref
> muF_over_ref
>
> to be lists of equal lengths as well.
> Then 'fixed_ren_scale' and 'fixed_fac_scale' would apply only if the
> corresponding entry is of length one. (i.e. lists would always be
> considered no matter what).
>
> Unfortunately, it might be too complicated to implement for what it is
> worth; you are the better judge there.
I think it's too much hassle.
>
> Speaking of the above, did you check everything works fine if you set
> 'fixed_ren_scale' to 'True' but 'fixed_fac_scale' to 'False' with a list of
> dynamical scales?
>
>
I'll double check what the code does in this case. I don't think this is covered correctly.
> What I meant is that, right now the weightid declaration reads:
>
> <weight id='1001'> muR=0.10000E+01 muF=0.10000E+01 </weight>
>
> and it could read
>
> <weight id='1001' name='NAME_
> muR=0.10000E+01 muF=0.10000E+01 </weight>
>
> where 'NAME_OF_
> ongoing convention we have with the various analysis tools out there.
> Using the content of this XML tag instead a 'name' attribute like above is
> not ideal because one should be able to put whatever he/she wants there
> (i.e. Olivier puts [or at least planned to] a diff of two param_cards in
> there in his reweighting for example).
This is not following the LHEF v3 standards. The name of the id is the actual "muR=0.10000E+01 muF=0.10000E+01" string. I don't think there is a need to define another one. Of course, we can enlarge it and give it a nice name, but I would suggest to put this string directly in the HepMC file, possibly concatenated with the 'name=' string of the weightgroup to which the weight belongs. But let's discuss this also over Skype. See also here:
https:/
> Yes, like I said in my other email, if you can make it on wednesday
> morning, 7:45 Munich time, it would work better for me. Let me know.
>
Wednesday morning is okay for me.
Cheers,
Rik
Valentin Hirschi (valentin-hirschi) wrote : | # |
Hi Rik,
> Hi Valentin,
>
> >
> > I thought so but it is a bit annoying I think because it is quite a common
> > thing to do.
> > I can see a couple ways of doing it elegantly but they all break backward
> > compatibility.
> > The only acceptable (from a user poitn of view) backward compatible way of
> > doing it that I can see is to promote the following run_card parameters:
> >
> > muR_ref_fixed
> > muF_ref_fixed
> > muR_over_ref
> > muF_over_ref
> >
> > to be lists of equal lengths as well.
> > Then 'fixed_ren_scale' and 'fixed_fac_scale' would apply only if the
> > corresponding entry is of length one. (i.e. lists would always be
> > considered no matter what).
> >
> > Unfortunately, it might be too complicated to implement for what it is
> > worth; you are the better judge there.
>
> I think it's too much hassle.
I understand. Then maybe just update set_scales.f to add an example of dynamic scale which is a 'fake fixed one' with a short comment on the run_card regarding its existence for simultaneously considering several fixed scales. I would find it nice, but up to you.
> >
> > Speaking of the above, did you check everything works fine if you set
> > 'fixed_ren_scale' to 'True' but 'fixed_fac_scale' to 'False' with a list of
> > dynamical scales?
> >
> >
>
> I'll double check what the code does in this case. I don't think this is
> covered correctly.
Yes, one of these marginal things that almost nobody uses but that we should still aim at handling correctly...
>
>
> > What I meant is that, right now the weightid declaration reads:
> >
> > <weight id='1001'> muR=0.10000E+01 muF=0.10000E+01 </weight>
> >
> > and it could read
> >
> > <weight id='1001' name='NAME_
> > muR=0.10000E+01 muF=0.10000E+01 </weight>
> >
> > where 'NAME_OF_
> > ongoing convention we have with the various analysis tools out there.
> > Using the content of this XML tag instead a 'name' attribute like above is
> > not ideal because one should be able to put whatever he/she wants there
> > (i.e. Olivier puts [or at least planned to] a diff of two param_cards in
> > there in his reweighting for example).
>
> This is not following the LHEF v3 standards. The name of the id is the actual
> "muR=0.10000E+01 muF=0.10000E+01" string. I don't think there is a need to
> define another one. Of course, we can enlarge it and give it a nice name, but
> I would suggest to put this string directly in the HepMC file, possibly
> concatenated with the 'name=' string of the weightgroup to which the weight
> belongs. But let's discuss this also over Skype. See also here:
> https:/
>
> > Yes, like I said in my other email, if you can make it on wednesday
> > morning, 7:45 Munich time, it would work better for me. Let me know.
> >
>
> Wednesday morning is okay for me.
Ok, talk to you then.
Cheers
>
> Cheers,
> Rik
Olivier Mattelaer (olivier-mattelaer) wrote : | # |
Hi Rik, Valentin,
>This is very true! A really dangerous potential code-injection security liability there!
> so Olivier, did you make sure that this is forbidden when running on the Web ?
This is not the most dangerous code injection that we can face, since we should also prevent the direct shell injection via the download of the banner. (be sure that the following command in the banner:
! rm /*
is not executed)
So yes, MadGraph/Madevent has a normal and a secure mode.
In the secure mode, the possibility to enter shell command is deactivate.
I'm using this flag to check if the param_card is allowed to have the scan parameter.
actually even in that case, we could still in principle use:
ast.literal_eval
but it is very limited.
So long story short, I'm not particularly worried by code-injection for this feature.
Since we can easily put the same security as for the scan.
Cheers,
Olivier
- 338. By Rikkert Frederix
-
updated the shower interfaces and analyses to be able to deal with the extended weights.
Also, search also in lib64 for the analyses. - 339. By Rikkert Frederix
-
some fixes in the previous push
- 340. By Rikkert Frederix
-
improve the treatment of fixed scales
Rikkert Frederix (frederix) wrote : | # |
Hi Valentin,
I've fixed some problems when using fixed scales. Also, I've updated all the shower analysis and interfaces to deal with the extended extra weights.
Cheers,
Rik
- 341. By Rikkert Frederix
-
fixed a couple of things following Valentin's suggestions on Skype
Olivier Mattelaer (olivier-mattelaer) wrote : | # |
Hi Rik,
1) I tried the following:
pdlabel -> lhapdf
lhaid -> 244600 244601 244602
dynamical_
and the code crashes with
lhaid 244601 not valid input number for the current lhapdf
Not sure if we can fix that or not (and how)...
I actually note later that it is explicitly written than only central value are allowed
But if this is not that much work, it can be nice to support also those ones. Otherwise it is fine.
(Maybe have a nicer error message)
2) If I continue the run and did (with the set command)
set lhaid 244600
the code crash due to the reweight PDF written as [False]
This is a formatting problem that I will have to fix.
3) After having fix the above it crashes since:
InvalidRunCard : 'reweight_scale' and 'lhaid' lists should have the same length
This is confusing since
- I have both of the same lenght (1)
- the comment in the run_card refer that this parameter should have the same length as dynamical_
I would advise that if reweight_
If I define reweight_scale and reweight_pdf to a list of 4 entry (to match dynamical_
4) I would either not advertise at all this list option, or include in the header an example of syntax for list entry. Since it is everything but clear how to enter a list in the card.
5) When I succeed to make a run (with forcing lhaid to be size 4... with the same lhaid) then I have the message:
run_card missed argument lhapdfsetname. Takes default: ['NNPDF23_
This is obviously everything but nice.... This parameter should stay fully hidden.
6) The print_results is very nice (really nice)... but no way to write this in a file:
print_results --path=out.txt
Command "print_results --path=out.txt" interrupted with error:
AttributeError : 'aMCatNLOCmdShell' object has no attribute 'print_
Please report this bug on https:/
More information is found in '/Users/
Please attach this file to your report.
For the problem that you ask me to look at:
- I guess taht the best is that I allow to have list of strings. I wanted to avoid it but it seems that you really need it. So let me fight with the parsing.
- lhapdfsetname should be define in the runcardNLO. No way to not have it define in the class if it is used by us. (you can put it as hidden)
I will stop here so far, since some of those problem forbids to fully test this module.
I will move forward on the list of strings and on the formatting problem.
(and will allow the syntax [ , , ] in any case)
Cheers,
Olivier
Rikkert Frederix (frederix) wrote : | # |
> Hi Rik,
>
> 1) I tried the following:
> pdlabel -> lhapdf
> lhaid -> 244600 244601 244602
> dynamical_
> and the code crashes with
> lhaid 244601 not valid input number for the current lhapdf
> Not sure if we can fix that or not (and how)...
>
> I actually note later that it is explicitly written than only central value
> are allowed
> But if this is not that much work, it can be nice to support also those ones.
> Otherwise it is fine.
> (Maybe have a nicer error message)
>
> 2) If I continue the run and did (with the set command)
> set lhaid 244600
> the code crash due to the reweight PDF written as [False]
> This is a formatting problem that I will have to fix.
>
> 3) After having fix the above it crashes since:
> InvalidRunCard : 'reweight_scale' and 'lhaid' lists should have the same
> length
>
> This is confusing since
> - I have both of the same lenght (1)
> - the comment in the run_card refer that this parameter should have the same
> length as dynamical_
> I would advise that if reweight_
> goes trough (by automatically switching this to a list of the correct length)
>
> If I define reweight_scale and reweight_pdf to a list of 4 entry (to match
> dynamical_
>
> 4) I would either not advertise at all this list option, or include in the
> header an example of syntax for list entry. Since it is everything but clear
> how to enter a list in the card.
>
> 5) When I succeed to make a run (with forcing lhaid to be size 4... with the
> same lhaid) then I have the message:
> run_card missed argument lhapdfsetname. Takes default:
> ['NNPDF23_
> 'NNPDF23_
> This is obviously everything but nice.... This parameter should stay fully
> hidden.
>
> 6) The print_results is very nice (really nice)... but no way to write this in
> a file:
> print_results --path=out.txt
>
> Command "print_results --path=out.txt" interrupted with error:
> AttributeError : 'aMCatNLOCmdShell' object has no attribute
> 'print_
> Please report this bug on https:/
> More information is found in '/Users/
> f_handling/
> Please attach this file to your report.
>
>
> For the problem that you ask me to look at:
> - I guess taht the best is that I allow to have list of strings. I wanted to
> avoid it but it seems that you really need it. So let me fight with the
> parsing.
> - lhapdfsetname should be define in the runcardNLO. No way to not have it
> define in the class if it is used by us. (you can put it as hidden)
>
>
> I will stop here so far, since some of those problem forbids to fully test
> this module.
> I will move forward on the list of strings and on the formatting problem.
> (and will allow the syntax [ , , ] in any case)
>
> Cheers,
>
> Olivier
- 342. By Rikkert Frederix
-
fixed some of the issues raised by Olivier
Rikkert Frederix (frederix) wrote : | # |
Hi Olivier,
> Hi Rik,
>
> 1) I tried the following:
> pdlabel -> lhapdf
> lhaid -> 244600 244601 244602
> dynamical_
> and the code crashes with
> lhaid 244601 not valid input number for the current lhapdf
> Not sure if we can fix that or not (and how)...
>
> I actually note later that it is explicitly written than only central value
> are allowed
> But if this is not that much work, it can be nice to support also those ones.
> Otherwise it is fine.
> (Maybe have a nicer error message)
Maybe. But I'm not sure how to do this... I don't think there is a way to get the name of the PDF or something if only the error set is known. Do you know any?
>
> 2) If I continue the run and did (with the set command)
> set lhaid 244600
> the code crash due to the reweight PDF written as [False]
> This is a formatting problem that I will have to fix.
Thanks.
>
> 3) After having fix the above it crashes since:
> InvalidRunCard : 'reweight_scale' and 'lhaid' lists should have the same
> length
>
> This is confusing since
> - I have both of the same lenght (1)
> - the comment in the run_card refer that this parameter should have the same
> length as dynamical_
> I would advise that if reweight_
> goes trough (by automatically switching this to a list of the correct length)
>
> If I define reweight_scale and reweight_pdf to a list of 4 entry (to match
> dynamical_
This is my mistake. The printing of the error message is wrong: the code checks that 'reweight_scale' and 'dynamical_
It's indeed a good idea that if the reweight_scale or reweight_PDF is of length 1 to automatically switch to the correct length, so I've implemented this.
> 4) I would either not advertise at all this list option, or include in the
> header an example of syntax for list entry. Since it is everything but clear
> how to enter a list in the card.
There are examples (rw_rscale and rw_fscale) as well as a comment all the way at the beginning of the run_card.dat (where the complete syntax is "explained"). Do you really think that stating that it should be "comma-separated list" is not enough?
>
> 5) When I succeed to make a run (with forcing lhaid to be size 4... with the
> same lhaid) then I have the message:
> run_card missed argument lhapdfsetname. Takes default:
> ['NNPDF23_
> 'NNPDF23_
> This is obviously everything but nice.... This parameter should stay fully
> hidden.
Yeah, this is needed. However, with the fact that we cannot use a list of string, there is no way of doing this...
>
> 6) The print_results is very nice (really nice)... but no way to write this in
> a file:
> print_results --path=out.txt
>
> Command "print_results --path=out.txt" interrupted with error:
> AttributeError : 'aMCatNLOCmdShell' object has no attribute
> 'print_
> Please report this bug on https:/
> More information is found in '/Users/
Olivier Mattelaer (olivier-mattelaer) wrote : | # |
Hi Rik,
> Maybe. But I'm not sure how to do this... I don't think there is a way to get
> the name of the PDF or something if only the error set is known. Do you know
> any?
What about something like that?
=== modified file 'madgraph/
--- madgraph/
+++ madgraph/
@@ -639,7 +639,12 @@
- raise MadGraph5Error(
+ keys = pdfsets.keys()
+ n_lhaid = max([k for k in keys if k < lhaid])
+ misc.sprint(lhaid, n_lhaid)
+ lhapdfsetname.
+ if abs(n_lhaid) - abs(lhaid) > 100 and '_1000' not in pdfsets[
+ raise MadGraph5Error(
> > 2) If I continue the run and did (with the set command)
> > set lhaid 244600
> > the code crash due to the reweight PDF written as [False]
> > This is a formatting problem that I will have to fix.
Done this was linked to a lower/upper case issue.
> There are examples (rw_rscale and rw_fscale) as well as a comment all the way
> at the beginning of the run_card.dat (where the complete syntax is
> "explained"). Do you really think that stating that it should be "comma-
> separated list" is not enough?
You right, I miss that line. That's enough
> Yeah, this is needed. However, with the fact that we cannot use a list of
> string, there is no way of doing this...
- I have added the possibility. It is not 100% complete and can in extreme case leads to weird results but I think that this is save enough as long as we do not handle path (with space or comma).
- I have added the lhapdfsetname argument and now that message do not exists anymore.
>
> >
> > 6) The print_results is very nice (really nice)... but no way to write this
> in
> > a file:
> > print_results --path=out.txt
> >
> > Command "print_results --path=out.txt" interrupted with error:
> > AttributeError : 'aMCatNLOCmdShell' object has no attribute
> > 'print_
> > Please report this bug on https:/
> > More information is found in
> '/Users/
> > f_handling/
> > Please attach this file to your report.
> >
>
> Sorry, but what is this option/command? Is this supposed to work at NLO? I
> didn't change anything in structure of the code for printing the results, so I
> don't understand what this is.
This command is suppose to print the summary of the run to a file. we have typically two output:
the normal one (the same as printed on the screen)
and a multicolumn one (with...
- 343. By Olivier Mattelaer
-
allow for list of strings
Rikkert Frederix (frederix) wrote : | # |
Hi Olivier,
Thanks for updating the code to allow for a list of strings. I'll have a look tomorrow, and if there is something that I don't understand/agree with, I'll let you know.
>
> === modified file 'madgraph/
> --- madgraph/
> +++ madgraph/
> @@ -639,7 +639,12 @@
> if lhaid in pdfsets:
> lhapdfsetname.
> else:
> - raise MadGraph5Error(
> for the current lhapdf' % lhaid )
> + keys = pdfsets.keys()
> + n_lhaid = max([k for k in keys if k < lhaid])
> + misc.sprint(lhaid, n_lhaid)
> + lhapdfsetname.
> + if abs(n_lhaid) - abs(lhaid) > 100 and '_1000' not in
> pdfsets[
> + raise MadGraph5Error(
> number for the current lhapdf' % lhaid )
> run_card[
> run_card.
>
>
>
I'm not very happy with this for 2 reasons. It's not obvious if you get a n_lhaid close enough lhaid that it's the correct one. If you look through the list of lhaid for central sets, https:/
I've updated the error message to
"lhaid %s is not a valid PDF identification number. This can be due to the use of an outdated version of LHAPDF, or %s is not a LHAGlue number corresponding to a central PDF set (but rather one of the error sets)." % (lhaid,lhaid)
>
> This command is suppose to print the summary of the run to a file. we have
> typically two output:
> the normal one (the same as printed on the screen)
> and a multicolumn one (with option --format=short) which allow easy parsing of
> argument.
> Don't know if that was ever implemented @NLO but it is a must have (when I see
> the error maybe not).
> Especially with the growing number of uncertainties. Having those only in the
> log screen is not a good options.
For NLO running, you already get a 'summary.txt' in the Events/*/ folder by default. Is there something else needed? --I don't think this was ever implemented at NLO.
>
> Will restart this review later ;-)
>
Thanks!
Cheers,
Rikkert
- 344. By Rikkert Frederix
-
updated the error message when having a wrong lhaid number in the run_card.
Valentin Hirschi (valentin-hirschi) wrote : | # |
Hi Rik,
Now my shower-reweighting run did proceed past the python-lhapdf band
computation. but it still crashed after:
return self.pdf_
File
"/Users/
line 3682, in pdf_scale_
pdfsetname=
AttributeError: 'list' object has no attribute 'split'
This seems like a simple typo to fix, so hopefully nothing bad.
Cheers
On Wed, Feb 24, 2016 at 9:37 AM, Rikkert Frederix <email address hidden>
wrote:
> Hi Olivier,
>
> Thanks for updating the code to allow for a list of strings. I'll have a
> look tomorrow, and if there is something that I don't understand/agree
> with, I'll let you know.
>
> >
> > === modified file 'madgraph/
> > --- madgraph/
> > +++ madgraph/
> > @@ -639,7 +639,12 @@
> > if lhaid in pdfsets:
> > lhapdfsetname.
> > else:
> > - raise MadGraph5Error(
> number
> > for the current lhapdf' % lhaid )
> > + keys = pdfsets.keys()
> > + n_lhaid = max([k for k in keys if k < lhaid])
> > + misc.sprint(lhaid, n_lhaid)
> > +
> lhapdfsetname.
> > + if abs(n_lhaid) - abs(lhaid) > 100 and '_1000'
> not in
> > pdfsets[
> > + raise MadGraph5Error(
> input
> > number for the current lhapdf' % lhaid )
> > run_card[
> > run_card.
> >
> >
> >
>
> I'm not very happy with this for 2 reasons. It's not obvious if you get a
> n_lhaid close enough lhaid that it's the correct one. If you look through
> the list of lhaid for central sets,
> https:/
> numbers not spaced very far apart. The second reason is the fortran code:
> you cannot initialise more than one PDF set from the lhaid number. You'll
> have to use the name and from there you can specify the pdf error set
> number, which would be the difference of the lhaid of the run_card and the
> lhaid of the central set. This quickly become a bit of a mess to get right.
> Therefore, I decided to only allow for the central set lhaid number and
> then you can either turn all error pdfs on or off with the reweight_pdf
> flag.
>
> I've updated the error message to
> "lhaid %s is not a valid PDF identification number. This can be due to the
> use of an outdated version of LHAPDF, or %s is not a LHAGlue number
> corresponding to a central PDF set (but rather one of the error sets)." %
> (lhaid,lhaid)
>
>
> >
> > This command is suppose to print the summary of the run to a file. we
> have
> > typically two output:
> > the normal one (the same as pri...
- 345. By Rikkert Frederix
-
fixed a couple of things related to the fact that we can now have a
list of strings.
Rikkert Frederix (frederix) wrote : | # |
Thank you Olivier, for the implementation of the list of strings. I've had to change the code in a couple of places to get this working correctly (which also solved Valentin's problem). It should all be okay now.
Cheers,
Rik
- 346. By Rikkert Frederix
-
removed the intrusive message
"Thanks for using LHAPDF 6.1.6. Please make sure to cite the paper: ..."
when closing the main MG5_aMC python prompt. It's still there at the end
of the individual log files of the jobs.
Valentin Hirschi (valentin-hirschi) wrote : | # |
> Thank you Olivier, for the implementation of the list of strings. I've had to
> change the code in a couple of places to get this working correctly (which
> also solved Valentin's problem). It should all be okay now.
In my multi-weight shower run, I can indeed now go past the issue I reported before, but I know bump into another crash that occurs once the shower is finished:
INFO: Preparing MCatNLO run
INFO: Compiling MCatNLO for PYTHIA8...
WARNING: 'dl' was added to extralibs from the shower_card.dat.
It is needed for the correct running of PY8.2xx.
If this library cannot be found on your system, a crash will occur.
INFO: ... done
INFO: Showering events...
INFO: (Running in /Users/
INFO: Idle: 1, Running: 0, Completed: 0 [ current time: 19h31 ]
INFO: Idle: 0, Running: 0, Completed: 1 [ 1m 2s ]
INFO: Idle: 0, Running: 0, Completed: 0 [ current time: 19h32 ]
Command "launch auto " interrupted with error:
UnboundLocalError : local variable 'use_lhapdf' referenced before assignment
with the following backtrace:
[...]
File "/Users/
format = 'gnuplot'
File "/Users/
lhapdfconfig = lhapdfconfig)
File "/Users/
(mu_var_pos,mu) = self[0]
File "/Users/
if use_lhapdf: lhapdf.
UnboundLocalError: local variable 'use_lhapdf' referenced before assignment
Again, it does not look like a major thing, but it prevents me from carrying the review further.
Just to make sure it is clear, I am trying to generate and shower events for p p > e+ ve [QCD] with two different dynamical scales and central PDF (with their variations turned on) and using the 'lvl'HwU shower analysis.
And fyi, the corresponding fixed order run which was working before is now also failing for the same problem as above apparently.
Cheers
> Cheers,
> Rik
Valentin Hirschi (valentin-hirschi) wrote : | # |
Hi Rik,
I think it was really just a simple indentation typo. I replaced the
problematic line with
and it went through fine. So I pushed this modification and will carry on
with the attempt at merging our two histograms.py. I will let you know.
On Thu, Feb 25, 2016 at 7:35 PM, Valentin Hirschi <
<email address hidden>> wrote:
> > Thank you Olivier, for the implementation of the list of strings. I've
> had to
> > change the code in a couple of places to get this working correctly
> (which
> > also solved Valentin's problem). It should all be okay now.
>
> In my multi-weight shower run, I can indeed now go past the issue I
> reported before, but I know bump into another crash that occurs once the
> shower is finished:
>
> INFO: Preparing MCatNLO run
> INFO: Compiling MCatNLO for PYTHIA8...
> WARNING: 'dl' was added to extralibs from the shower_card.dat.
> It is needed for the correct running of PY8.2xx.
> If this library cannot be found on your system, a crash will occur.
> INFO: ... done
> INFO: Showering events...
> INFO: (Running in
> /Users/
> INFO: Idle: 1, Running: 0, Completed: 0 [ current time: 19h31 ]
> INFO: Idle: 0, Running: 0, Completed: 1 [ 1m 2s ]
> INFO: Idle: 0, Running: 0, Completed: 0 [ current time: 19h32 ]
> Command "launch auto " interrupted with error:
> UnboundLocalError : local variable 'use_lhapdf' referenced before
> assignment
>
> with the following backtrace:
>
> [...]
> File
> "/Users/
> line 3100, in run_mcatnlo
> format = 'gnuplot'
> File
> "/Users/
> line 1611, in output
> lhapdfconfig = lhapdfconfig)
> File
> "/Users/
> line 1687, in output_group
> (mu_var_pos,mu) = self[0]
> File
> "/Users/
> line 1079, in set_uncertainty
> if use_lhapdf: lhapdf.
> UnboundLocalError: local variable 'use_lhapdf' referenced before assignment
>
> Again, it does not look like a major thing, but it prevents me from
> carrying the review further.
> Just to make sure it is clear, I am trying to generate and shower events
> for p p > e+ ve [QCD] with two different dynamical scales and central PDF
> (with their variations turned on) and using the 'lvl'HwU shower analysis.
>
> And fyi, the corresponding fixed order run which was working before is now
> also failing for the same problem as above apparently.
>
> Cheers
>
> > Cheers,
> > Rik
> --
>
> https:/
> You are requested to review the proposed merge of
> lp:~maddevelopers/mg5amcnlo/improved_scale_pdf_handling into
> lp:~maddevelopers/mg5a...
- 347. By Valentin Hirschi
-
1. Fixed a simple indentation typo for if use_lhapdf
- 348. By Rikkert Frederix
-
small fix in the setverbosity for lhapdf
Rikkert Frederix (frederix) wrote : | # |
Hi Valentin,
Sorry about the lhapdf.setVerbosity stuff. It was a last-minute addition yesterday to remove the printing of the very intrusive message at the end of runs coming from LHAPDF. I've just fixed it by making sure it's only tried if PDF uncertainties are computed and use_lhapdf is true.
Cheers,
Rik
Olivier Mattelaer (olivier-mattelaer) wrote : | # |
Hi Rik,
I have made a couple of run and they mainly went trough in a nice way.
I have two comments:
1) We will need to have at least a link on your summary in the webpage.
All results should be linked from that page. So far no information on the scale/PDF uncertainty is available on that page which is quite bad.
2) I face some parser error with the PDF reweighting associated to the HwU:
DEBUG: Combining HwU plots.
Command "launch auto " interrupted with error:
ParseError : There are only 79 weights specified and 161 were expected.
The run was done with:
set lhaid 24000 24000
3) I do not understand the utility of the "lhapdfsetname" parameter.
Looks like this parameter should not be allowed to be modified by the user (at least for the moment) and therefore should not be part of the RunCard (at least not as editable parameter).
I tried to play with this parameter but get only very weird result:
A) If I do the following:
add the line
['CT10nlo', 'CT10nnlo', 'MMHT2014lo68cl'] = lhapdfsetname
in the run_card, remove the lhaid entry
and set
True True True = reweight_pdf
then it crash saying that lhaid and reweight_pdf should have the same length...
B) if I do:
set lhaid 24000 24000 24000
set lhapdfsetname ['CT10nlo', 'CT10nnlo', 'MMHT2014lo68cl']
Then looks like it runs three times for 24000 (and therefore crash as above)
But the code seems to have kept "my" value of lhapdfsetname which is everything but save.
4) Looks like you continue the LHEF miss-convention in this branch, even if you modify some of the incriminated branch. I would suggest that this branch being merged with the LHEF_convention branch
such that we can check that all the type= have been correctly removed in this branch.
Cheers,
Olivier
- 349. By Rikkert Frederix
-
added the changes of the LHEF_convention branch
- 350. By Rikkert Frederix
-
added a check that all 'lhaid' and 'dynamical_
scale_choices' are different - 351. By Olivier Mattelaer
-
set lhapdfsetname to private attribute that can not be modified by the user
- 352. By Rikkert Frederix
-
added the summary.txt to the HTML pages
- 353. By Rikkert Frederix
-
make 'system' parameters in the run_card also 'hidden'.
Rikkert Frederix (frederix) wrote : | # |
Hi Olivier,
Thanks for the suggestions. I've implemented all of them. Note that I made the 'system' parameters automatically 'hidden' as well. I guess this is what we want, right?
Cheers,
Rik
- 354. By Olivier Mattelaer
-
correct the fix of Rikkert
- 355. By Rikkert Frederix
-
added Valentin's improved histrograms.py
- 356. By Valentin Hirschi
-
1. Fixed a typo in the 3 statements
uncertainty_plot_lines[ -1]['merging' ] = ...
which should have read:
uncertainty_plot_lines[ -1]['merging_ scale'] = ... 2. Forced to always have the legend for the variations in the main plot,
and not with a text in the first subplot.
However, now only one band can appear in the main plot. The variations
which are not to be displayed as a band will only show in the first
subplot. - 357. By Valentin Hirschi
-
1. Fixed an obvious little issue in histograms.py when not running with uncertainties.
Valentin Hirschi (valentin-hirschi) wrote : | # |
Hi Rik,
I tested again the module in various conditions and it worked fine (besides an obvious simple problem in histograms.py that I fixed right away). However, I was too lazy to perform any validation, but I assume you have done so already.
Is there any test related to this advanced reweighting functionality?
My last comment is that I think it would be nice that you change the options for the HwU output in aMC@NLO_
Cheers
- 358. By Rikkert Frederix
-
slightly improved the importing of the LHAPDF python interface and
improved the warning message in case it cannot do it.
Olivier Mattelaer (olivier-mattelaer) wrote : | # |
Hi Rik,
I have two small question
1) I see a couple of parameter which have pass in hidden mode:
"hidden" mode is for parameter that the user can modify but which are not present in the default run_card (mainly because they are too technical)
I guess some should be put in "legacy" mode instead. (parameter which generates a warning if present in the card since it has no effect on the code anymore).
I guess that it should be the case for muf1_over_ref, rw_fscale_down, pdf_set_max,...
If those are suppose to be legacy parameter. Is the behavior the same as before?
I guess that (some)of those can not be combine with the new syntax. Did you check that in the check_validity routine?
For reference, here is the list of all the hidden parameter.
I see a lot of parameter not present anymore by default in the run_card:
run_card missed argument muf1_over_ref. Takes default: 0.5
run_card missed argument muf2_over_ref. Takes default: 0.5
run_card missed argument fixed_qes_scale. Takes default: False
run_card missed argument rw_fscale_down. Takes default: -1.0
run_card missed argument rw_rscale_down. Takes default: -1.0
run_card missed argument muf1_ref_fixed. Takes default: 91.118
run_card missed argument qes_over_ref. Takes default: 2.0
run_card missed argument pdf_set_min. Takes default: 244601
run_card missed argument maxjetflavor. Takes default: 4
run_card missed argument rw_fscale_up. Takes default: -1.0
run_card missed argument muf2_ref_fixed. Takes default: 91.118
run_card missed argument pdf_set_max. Takes default: 244700
run_card missed argument rw_rscale_up. Takes default: -1.0
run_card missed argument qes_ref_fixed. Takes default: 91.118
2) Can you comment on the status of maxjetflavor?
I see that the parameter pass in hidden (see above) but we still set it automatically in the routine
create_
I'm not sure if that make sense.
Since this is minor anyway, I already approve this.
Thanks a lot,
Olivier
Rikkert Frederix (frederix) wrote : | # |
Hi Olivier,
Thanks for the review.
1.) I think basically all those parameters are still working; the code is backward compatible. It's just that their use should be discouraged, which is the reason I made them hidden. Maybe in some future version we can put them to 'legacy' status.
2.) I've never noticed that this is set automatically. And it is certainly not working as intended: doing e+ e- > j j [QCD], makes that the default of maxjetflavour remains always equal to 4, no matter how many light partons I have in my model and are part of 'j'. In my opinion, maxjetflavour should be set to the number of massless quarks in the model.
However, maxjetflavour is not a parameter that makes real sense at NLO. I mean, the only case where it might be considered is a process where you ask for explicit (massive) b quarks in the process, but want to put cuts on the b-*jets*. But there is a problem with that. Suppose you do p p > w+ b b~ [QCD] and set maxjetflavour=5 and put pT(j)>50GeV or so, it's not that you get two *b*-jets. Rather, also the real-emission parton can form one of the jets, which means you could also get one b-jet and one light jet, which is something that's easily overlooked when not too familiar with NLO computations. And this is, in general, not what you want when you asked for the process p p > w+ b b~. Hence, I thought it would be safer to move this parameter to hidden.
Cheers,
Rik
Preview Diff
1 | === modified file 'Template/NLO/Cards/run_card.dat' |
2 | --- Template/NLO/Cards/run_card.dat 2015-11-02 16:43:45 +0000 |
3 | +++ Template/NLO/Cards/run_card.dat 2016-03-04 16:01:53 +0000 |
4 | @@ -10,6 +10,9 @@ |
5 | # Lines starting with a hash (#) are info or comments * |
6 | # * |
7 | # mind the format: value = variable ! comment * |
8 | +# * |
9 | +# Some of the values of variables can be list. These can either be * |
10 | +# comma or space separated. * |
11 | #*********************************************************************** |
12 | # |
13 | #******************* |
14 | @@ -58,8 +61,10 @@ |
15 | #*********************************************************************** |
16 | # PDF choice: this automatically fixes also alpha_s(MZ) and its evol. * |
17 | #*********************************************************************** |
18 | - %(pdlabel)s = pdlabel ! PDF set |
19 | - %(lhaid)s = lhaid ! if pdlabel=lhapdf, this is the lhapdf number |
20 | + %(pdlabel)s = pdlabel ! PDF set |
21 | + %(lhaid)s = lhaid ! If pdlabel=lhapdf, this is the lhapdf number. Only |
22 | + ! numbers for central PDF sets are allowed. Can be a list; |
23 | + ! PDF sets beyond the first are included via reweighting. |
24 | #*********************************************************************** |
25 | # Include the NLO Monte Carlo subtr. terms for the following parton * |
26 | # shower (HERWIG6 | HERWIGPP | PYTHIA6Q | PYTHIA6PT | PYTHIA8) * |
27 | @@ -73,36 +78,29 @@ |
28 | # (Default functional form for the non-fixed scales is the sum of * |
29 | # the transverse masses divided by two of all final state particles * |
30 | # and partons. This can be changed in SubProcesses/set_scales.f or via * |
31 | -# dynamical_scale_choice options) * |
32 | +# dynamical_scale_choice option) * |
33 | #*********************************************************************** |
34 | - %(fixed_ren_scale)s = fixed_ren_scale ! if .true. use fixed ren scale |
35 | - %(fixed_fac_scale)s = fixed_fac_scale ! if .true. use fixed fac scale |
36 | + %(fixed_ren_scale)s = fixed_ren_scale ! if .true. use fixed ren scale |
37 | + %(fixed_fac_scale)s = fixed_fac_scale ! if .true. use fixed fac scale |
38 | %(mur_ref_fixed)s = muR_ref_fixed ! fixed ren reference scale |
39 | - %(muf1_ref_fixed)s = muF1_ref_fixed ! fixed fact reference scale for pdf1 |
40 | - %(muf2_ref_fixed)s = muF2_ref_fixed ! fixed fact reference scale for pdf2 |
41 | - %(dynamical_scale_choice)s = dynamical_scale_choice ! Choose one of the preselected dynamical choices |
42 | -#*********************************************************************** |
43 | -# Renormalization and factorization scales (advanced and NLO options) * |
44 | -#*********************************************************************** |
45 | - %(fixed_qes_scale)s = fixed_QES_scale ! if .true. use fixed Ellis-Sexton scale |
46 | - %(qes_ref_fixed)s = QES_ref_fixed ! fixed Ellis-Sexton reference scale |
47 | - %(mur_over_ref)s = muR_over_ref ! ratio of current muR over reference muR |
48 | - %(muf1_over_ref)s = muF1_over_ref ! ratio of current muF1 over reference muF1 |
49 | - %(muf2_over_ref)s = muF2_over_ref ! ratio of current muF2 over reference muF2 |
50 | - %(qes_over_ref)s = QES_over_ref ! ratio of current QES over reference QES |
51 | + %(muf_ref_fixed)s = muF_ref_fixed ! fixed fact reference scale |
52 | + %(dynamical_scale_choice)s = dynamical_scale_choice ! Choose one (or more) of the predefined |
53 | + ! dynamical choices. Can be a list; scale choices beyond the |
54 | + ! first are included via reweighting |
55 | + %(mur_over_ref)s = muR_over_ref ! ratio of current muR over reference muR |
56 | + %(muf_over_ref)s = muF_over_ref ! ratio of current muF over reference muF |
57 | #*********************************************************************** |
58 | -# Reweight flags to get scale dependence and PDF uncertainty * |
59 | -# For scale dependence: factor rw_scale_up/down around central scale * |
60 | -# For PDF uncertainty: use LHAPDF with supported set * |
61 | +# Reweight variables for scale dependence and PDF uncertainty * |
62 | #*********************************************************************** |
63 | - %(reweight_scale)s = reweight_scale ! reweight to get scale dependence |
64 | - %(rw_rscale_down)s = rw_Rscale_down ! lower bound for ren scale variations |
65 | - %(rw_rscale_up)s = rw_Rscale_up ! upper bound for ren scale variations |
66 | - %(rw_fscale_down)s = rw_Fscale_down ! lower bound for fact scale variations |
67 | - %(rw_fscale_up)s = rw_Fscale_up ! upper bound for fact scale variations |
68 | - %(reweight_pdf)s = reweight_PDF ! reweight to get PDF uncertainty |
69 | - %(pdf_set_min)s = PDF_set_min ! First of the error PDF sets |
70 | - %(pdf_set_max)s = PDF_set_max ! Last of the error PDF sets |
71 | + %(rw_rscale)s = rw_rscale ! muR factors to be included by reweighting |
72 | + %(rw_fscale)s = rw_fscale ! muF factors to be included by reweighting |
73 | + %(reweight_scale)s = reweight_scale ! Reweight to get scale variation using the |
74 | + ! rw_rscale and rw_fscale factors. Should be a list of |
75 | + ! booleans of equal length to dynamical_scale_choice to |
76 | + ! specify for which choice to include scale dependence. |
77 | + %(reweight_pdf)s = reweight_PDF ! Reweight to get PDF uncertainty. Should be a |
78 | + ! list booleans of equal length to lhaid to specify for |
79 | + ! which PDF set to include the uncertainties. |
80 | #*********************************************************************** |
81 | # ickkw parameter: * |
82 | # 0: No merging * |
83 | @@ -117,47 +115,43 @@ |
84 | #*********************************************************************** |
85 | # |
86 | #*********************************************************************** |
87 | -# BW cutoff (M+/-bwcutoff*Gamma) * |
88 | +# BW cutoff (M+/-bwcutoff*Gamma). Determines which resonances are * |
89 | +# written in the LHE event file * |
90 | #*********************************************************************** |
91 | %(bwcutoff)s = bwcutoff |
92 | #*********************************************************************** |
93 | -# Cuts on the jets * |
94 | -# Jet clustering is performed by FastJet. |
95 | -# When matching to a parton shower, these generation cuts should be * |
96 | -# considerably softer than the analysis cuts. * |
97 | -# (more specific cuts can be specified in SubProcesses/cuts.f) * |
98 | +# Cuts on the jets. Jet clustering is performed by FastJet. * |
99 | +# - When matching to a parton shower, these generation cuts should be * |
100 | +# considerably softer than the analysis cuts. * |
101 | +# - More specific cuts can be specified in SubProcesses/cuts.f * |
102 | #*********************************************************************** |
103 | - %(jetalgo)s = jetalgo ! FastJet jet algorithm (1=kT, 0=C/A, -1=anti-kT) |
104 | - %(jetradius)s = jetradius ! The radius parameter for the jet algorithm |
105 | + %(jetalgo)s = jetalgo ! FastJet jet algorithm (1=kT, 0=C/A, -1=anti-kT) |
106 | + %(jetradius)s = jetradius ! The radius parameter for the jet algorithm |
107 | %(ptj)s = ptj ! Min jet transverse momentum |
108 | %(etaj)s = etaj ! Max jet abs(pseudo-rap) (a value .lt.0 means no cut) |
109 | #*********************************************************************** |
110 | # Cuts on the charged leptons (e+, e-, mu+, mu-, tau+ and tau-) * |
111 | -# (more specific gen cuts can be specified in SubProcesses/cuts.f) * |
112 | +# More specific cuts can be specified in SubProcesses/cuts.f * |
113 | #*********************************************************************** |
114 | %(ptl)s = ptl ! Min lepton transverse momentum |
115 | - %(etal)s = etal ! Max lepton abs(pseudo-rap) (a value .lt.0 means no cut) |
116 | + %(etal)s = etal ! Max lepton abs(pseudo-rap) (a value .lt.0 means no cut) |
117 | %(drll)s = drll ! Min distance between opposite sign lepton pairs |
118 | %(drll_sf)s = drll_sf ! Min distance between opp. sign same-flavor lepton pairs |
119 | %(mll)s = mll ! Min inv. mass of all opposite sign lepton pairs |
120 | - %(mll_sf)s = mll_sf ! Min inv. mass of all opp. sign same-flavor lepton pairs |
121 | -#*********************************************************************** |
122 | -# Photon-isolation cuts, according to hep-ph/9801442 * |
123 | -# When ptgmin=0, all the other parameters are ignored * |
124 | -#*********************************************************************** |
125 | - %(ptgmin)s = ptgmin ! Min photon transverse momentum |
126 | - %(etagamma)s = etagamma ! Max photon abs(pseudo-rap) |
127 | + %(mll_sf)s = mll_sf ! Min inv. mass of all opp. sign same-flavor lepton pairs |
128 | +#*********************************************************************** |
129 | +# Photon-isolation cuts, according to hep-ph/9801442. When ptgmin=0, * |
130 | +# all the other parameters are ignored. * |
131 | +# More specific cuts can be specified in SubProcesses/cuts.f * |
132 | +#*********************************************************************** |
133 | + %(ptgmin)s = ptgmin ! Min photon transverse momentum |
134 | + %(etagamma)s = etagamma ! Max photon abs(pseudo-rap) |
135 | %(r0gamma)s = R0gamma ! Radius of isolation code |
136 | %(xn)s = xn ! n parameter of eq.(3.4) in hep-ph/9801442 |
137 | %(epsgamma)s = epsgamma ! epsilon_gamma parameter of eq.(3.4) in hep-ph/9801442 |
138 | - %(isoem)s = isoEM ! isolate photons from EM energy (photons and leptons) |
139 | -#*********************************************************************** |
140 | -# Maximal PDG code for quark to be considered a jet when applying cuts.* |
141 | -# At least all massless quarks of the model should be included here. * |
142 | -#*********************************************************************** |
143 | - %(maxjetflavor)s = maxjetflavor |
144 | + %(isoem)s = isoEM ! isolate photons from EM energy (photons and leptons) |
145 | #*********************************************************************** |
146 | # For aMCfast+APPLGRID use in PDF fitting (http://amcfast.hepforge.org)* |
147 | #*********************************************************************** |
148 | - %(iappl)s = iappl ! aMCfast switch (0=OFF, 1=prepare APPLgrids, 2=fill grids) |
149 | + %(iappl)s = iappl ! aMCfast switch (0=OFF, 1=prepare grids, 2=fill grids) |
150 | #*********************************************************************** |
151 | |
152 | === modified file 'Template/NLO/FixedOrderAnalysis/HwU.f' |
153 | --- Template/NLO/FixedOrderAnalysis/HwU.f 2015-03-05 19:51:04 +0000 |
154 | +++ Template/NLO/FixedOrderAnalysis/HwU.f 2016-03-04 16:01:53 +0000 |
155 | @@ -360,16 +360,15 @@ |
156 | character*4 str_nbin |
157 | double precision xnorm |
158 | c column info: x_min, x_max, y (central value), dy, {extra |
159 | -c weights}. Use columns with a width of 17 characters. |
160 | - write (buffer( 1:17),'(a)')'##& xmin &' |
161 | - write (buffer(18:34),'(a)')' xmax ' |
162 | - write (buffer(35:51),'(a2,a15)') ' &',wgts_info(1)(1:15) |
163 | - write (buffer(52:68),'(a)')' & dy ' |
164 | +c weights}. |
165 | + write (unit,'(a$)') '##& xmin' |
166 | + write (unit,'(a$)') ' & xmax' |
167 | + write (unit,'(a$)') ' & '//trim(adjustl(wgts_info(1))) |
168 | + write (unit,'(a$)') ' & dy' |
169 | do j=2,nwgts |
170 | - write (buffer((j+2)*17+1:(j+3)*17),'(a2,a15)') |
171 | - $ ' &',wgts_info(j)(1:15) |
172 | + write (unit,'(a$)') ' & '//trim(adjustl(wgts_info(j))) |
173 | enddo |
174 | - write (unit,'(a)') buffer(1:(nwgts+3)*17) |
175 | + write (unit,'(a)') '' |
176 | write (unit,'(a)') '' |
177 | do label=1,max_plots |
178 | if (.not. booked(label)) cycle |
179 | |
180 | === modified file 'Template/NLO/FixedOrderAnalysis/HwU.inc' |
181 | --- Template/NLO/FixedOrderAnalysis/HwU.inc 2015-03-05 19:51:04 +0000 |
182 | +++ Template/NLO/FixedOrderAnalysis/HwU.inc 2016-03-04 16:01:53 +0000 |
183 | @@ -3,14 +3,14 @@ |
184 | integer max_plots,max_bins,max_wgts,max_points |
185 | parameter (max_plots=200) |
186 | parameter (max_bins=100) |
187 | - parameter (max_wgts=300) |
188 | + parameter (max_wgts=1024) |
189 | parameter (max_points=max_plots*40) |
190 | |
191 | logical booked(max_plots) |
192 | integer nbin(max_plots),nwgts,np,p_bin(max_points) |
193 | & ,p_label(max_points),histi(max_plots,max_bins) |
194 | character*50 title(max_plots) |
195 | - character*15 wgts_info(max_wgts) |
196 | + character*50 wgts_info(max_wgts) |
197 | double precision histy(max_wgts,max_plots,max_bins) |
198 | $ ,histy_acc(max_wgts,max_plots,max_bins),histy2(max_plots |
199 | $ ,max_bins),histy_err(max_plots,max_bins),histxl(max_plots |
200 | |
201 | === modified file 'Template/NLO/MCatNLO/HWAnalyzer/hw6an_HwU_pp_V.f' |
202 | --- Template/NLO/MCatNLO/HWAnalyzer/hw6an_HwU_pp_V.f 2015-12-04 15:47:32 +0000 |
203 | +++ Template/NLO/MCatNLO/HWAnalyzer/hw6an_HwU_pp_V.f 2016-03-04 16:01:53 +0000 |
204 | @@ -49,11 +49,7 @@ |
205 | integer nwgt,max_weight,nwgt_analysis |
206 | common/cnwgt/nwgt |
207 | common/c_analysis/nwgt_analysis |
208 | - integer maxRWGT |
209 | - parameter (maxRWGT=100) |
210 | - double precision wgtxsecRWGT(maxRWGT) |
211 | - parameter (max_weight=maxscales*maxscales+maxpdfs+maxRWGT+1) |
212 | - character*15 weights_info(max_weight) |
213 | + character*50 weights_info(max_weight_shower) |
214 | common/cwgtsinfo/weights_info |
215 | c Initialize histograms |
216 | call HwU_inithist(nwgt,weights_info) |
217 | |
218 | === modified file 'Template/NLO/MCatNLO/HWAnalyzer/hw6an_HwU_pp_h.f' |
219 | --- Template/NLO/MCatNLO/HWAnalyzer/hw6an_HwU_pp_h.f 2015-12-04 15:47:32 +0000 |
220 | +++ Template/NLO/MCatNLO/HWAnalyzer/hw6an_HwU_pp_h.f 2016-03-04 16:01:53 +0000 |
221 | @@ -46,11 +46,7 @@ |
222 | integer nwgt,max_weight,nwgt_analysis,kk,l |
223 | common/cnwgt/nwgt |
224 | common/c_analysis/nwgt_analysis |
225 | - integer maxRWGT |
226 | - parameter (maxRWGT=100) |
227 | - double precision wgtxsecRWGT(maxRWGT) |
228 | - parameter (max_weight=maxscales*maxscales+maxpdfs+maxRWGT+1) |
229 | - character*15 weights_info(max_weight) |
230 | + character*50 weights_info(max_weight_shower) |
231 | common/cwgtsinfo/weights_info |
232 | c Initialize histograms |
233 | call HwU_inithist(nwgt,weights_info) |
234 | |
235 | === modified file 'Template/NLO/MCatNLO/HWAnalyzer/hw6an_HwU_pp_hjj.f' |
236 | --- Template/NLO/MCatNLO/HWAnalyzer/hw6an_HwU_pp_hjj.f 2015-12-04 15:47:32 +0000 |
237 | +++ Template/NLO/MCatNLO/HWAnalyzer/hw6an_HwU_pp_hjj.f 2016-03-04 16:01:53 +0000 |
238 | @@ -51,11 +51,7 @@ |
239 | common /to_veto_hist/vetomin,vetomax,nbinveto |
240 | common/cnwgt/nwgt |
241 | common/c_analysis/nwgt_analysis |
242 | - integer maxRWGT |
243 | - parameter (maxRWGT=100) |
244 | - double precision wgtxsecRWGT(maxRWGT) |
245 | - parameter (max_weight=maxscales*maxscales+maxpdfs+maxRWGT+1) |
246 | - character*15 weights_info(max_weight) |
247 | + character*50 weights_info(max_weight_shower) |
248 | common/cwgtsinfo/weights_info |
249 | c Initialize histograms |
250 | call HwU_inithist(nwgt,weights_info) |
251 | |
252 | === modified file 'Template/NLO/MCatNLO/HWAnalyzer/hw6an_HwU_pp_leptons.f' |
253 | --- Template/NLO/MCatNLO/HWAnalyzer/hw6an_HwU_pp_leptons.f 2015-12-04 15:47:32 +0000 |
254 | +++ Template/NLO/MCatNLO/HWAnalyzer/hw6an_HwU_pp_leptons.f 2016-03-04 16:01:53 +0000 |
255 | @@ -60,11 +60,7 @@ |
256 | integer nwgt,max_weight,nwgt_analysis |
257 | common/cnwgt/nwgt |
258 | common/c_analysis/nwgt_analysis |
259 | - integer maxRWGT |
260 | - parameter (maxRWGT=100) |
261 | - double precision wgtxsecRWGT(maxRWGT) |
262 | - parameter (max_weight=maxscales*maxscales+maxpdfs+maxRWGT+1) |
263 | - character*15 weights_info(max_weight) |
264 | + character*50 weights_info(max_weight_shower) |
265 | common/cwgtsinfo/weights_info |
266 | c Initialize histograms |
267 | call HwU_inithist(nwgt,weights_info) |
268 | |
269 | === modified file 'Template/NLO/MCatNLO/HWAnalyzer/hw6an_HwU_pp_lplm.f' |
270 | --- Template/NLO/MCatNLO/HWAnalyzer/hw6an_HwU_pp_lplm.f 2016-02-17 14:32:27 +0000 |
271 | +++ Template/NLO/MCatNLO/HWAnalyzer/hw6an_HwU_pp_lplm.f 2016-03-04 16:01:53 +0000 |
272 | @@ -48,11 +48,7 @@ |
273 | integer nwgt,max_weight,nwgt_analysis |
274 | common/cnwgt/nwgt |
275 | common/c_analysis/nwgt_analysis |
276 | - integer maxRWGT |
277 | - parameter (maxRWGT=100) |
278 | - double precision wgtxsecRWGT(maxRWGT) |
279 | - parameter (max_weight=maxscales*maxscales+maxpdfs+maxRWGT+1) |
280 | - character*15 weights_info(max_weight) |
281 | + character*50 weights_info(max_weight_shower) |
282 | common/cwgtsinfo/weights_info |
283 | c Initialize histograms |
284 | call HwU_inithist(nwgt,weights_info) |
285 | |
286 | === modified file 'Template/NLO/MCatNLO/HWAnalyzer/hw6an_HwU_pp_lvl.f' |
287 | --- Template/NLO/MCatNLO/HWAnalyzer/hw6an_HwU_pp_lvl.f 2015-12-04 15:47:32 +0000 |
288 | +++ Template/NLO/MCatNLO/HWAnalyzer/hw6an_HwU_pp_lvl.f 2016-03-04 16:01:53 +0000 |
289 | @@ -48,11 +48,7 @@ |
290 | integer nwgt,max_weight,nwgt_analysis |
291 | common/cnwgt/nwgt |
292 | common/c_analysis/nwgt_analysis |
293 | - integer maxRWGT |
294 | - parameter (maxRWGT=100) |
295 | - double precision wgtxsecRWGT(maxRWGT) |
296 | - parameter (max_weight=maxscales*maxscales+maxpdfs+maxRWGT+1) |
297 | - character*15 weights_info(max_weight) |
298 | + character*50 weights_info(max_weight_shower) |
299 | common/cwgtsinfo/weights_info |
300 | c Initialize histograms |
301 | call HwU_inithist(nwgt,weights_info) |
302 | |
303 | === modified file 'Template/NLO/MCatNLO/HWAnalyzer/hw6an_HwU_pp_taptam.f' |
304 | --- Template/NLO/MCatNLO/HWAnalyzer/hw6an_HwU_pp_taptam.f 2015-12-04 15:47:32 +0000 |
305 | +++ Template/NLO/MCatNLO/HWAnalyzer/hw6an_HwU_pp_taptam.f 2016-03-04 16:01:53 +0000 |
306 | @@ -46,11 +46,7 @@ |
307 | integer nwgt,max_weight,nwgt_analysis,kk,l |
308 | common/cnwgt/nwgt |
309 | common/c_analysis/nwgt_analysis |
310 | - integer maxRWGT |
311 | - parameter (maxRWGT=100) |
312 | - double precision wgtxsecRWGT(maxRWGT) |
313 | - parameter (max_weight=maxscales*maxscales+maxpdfs+maxRWGT+1) |
314 | - character*15 weights_info(max_weight) |
315 | + character*50 weights_info(max_weight_shower) |
316 | common/cwgtsinfo/weights_info |
317 | c Initialize histograms |
318 | call HwU_inithist(nwgt,weights_info) |
319 | |
320 | === modified file 'Template/NLO/MCatNLO/HWAnalyzer/hw6an_HwU_pp_tj.f' |
321 | --- Template/NLO/MCatNLO/HWAnalyzer/hw6an_HwU_pp_tj.f 2015-12-04 15:47:32 +0000 |
322 | +++ Template/NLO/MCatNLO/HWAnalyzer/hw6an_HwU_pp_tj.f 2016-03-04 16:01:53 +0000 |
323 | @@ -46,11 +46,7 @@ |
324 | integer nwgt,max_weight,nwgt_analysis |
325 | common/cnwgt/nwgt |
326 | common/c_analysis/nwgt_analysis |
327 | - integer maxRWGT |
328 | - parameter (maxRWGT=100) |
329 | - double precision wgtxsecRWGT(maxRWGT) |
330 | - parameter (max_weight=maxscales*maxscales+maxpdfs+maxRWGT+1) |
331 | - character*15 weights_info(max_weight) |
332 | + character*50 weights_info(max_weight_shower) |
333 | common/cwgtsinfo/weights_info |
334 | c Initialize histograms |
335 | call HwU_inithist(nwgt,weights_info) |
336 | |
337 | === modified file 'Template/NLO/MCatNLO/HWAnalyzer/hw6an_HwU_pp_ttx.f' |
338 | --- Template/NLO/MCatNLO/HWAnalyzer/hw6an_HwU_pp_ttx.f 2015-12-04 15:47:32 +0000 |
339 | +++ Template/NLO/MCatNLO/HWAnalyzer/hw6an_HwU_pp_ttx.f 2016-03-04 16:01:53 +0000 |
340 | @@ -46,11 +46,7 @@ |
341 | integer nwgt,max_weight,nwgt_analysis |
342 | common/cnwgt/nwgt |
343 | common/c_analysis/nwgt_analysis |
344 | - integer maxRWGT |
345 | - parameter (maxRWGT=100) |
346 | - double precision wgtxsecRWGT(maxRWGT) |
347 | - parameter (max_weight=maxscales*maxscales+maxpdfs+maxRWGT+1) |
348 | - character*15 weights_info(max_weight) |
349 | + character*50 weights_info(max_weight_shower) |
350 | common/cwgtsinfo/weights_info |
351 | c Initialize histograms |
352 | call HwU_inithist(nwgt,weights_info) |
353 | |
354 | === modified file 'Template/NLO/MCatNLO/HWAnalyzer/hw6an_HwU_pp_ttx_v2.f' |
355 | --- Template/NLO/MCatNLO/HWAnalyzer/hw6an_HwU_pp_ttx_v2.f 2015-12-04 15:47:32 +0000 |
356 | +++ Template/NLO/MCatNLO/HWAnalyzer/hw6an_HwU_pp_ttx_v2.f 2016-03-04 16:01:53 +0000 |
357 | @@ -46,11 +46,7 @@ |
358 | integer nwgt,max_weight,nwgt_analysis |
359 | common/cnwgt/nwgt |
360 | common/c_analysis/nwgt_analysis |
361 | - integer maxRWGT |
362 | - parameter (maxRWGT=100) |
363 | - double precision wgtxsecRWGT(maxRWGT) |
364 | - parameter (max_weight=maxscales*maxscales+maxpdfs+maxRWGT+1) |
365 | - character*15 weights_info(max_weight) |
366 | + character*50 weights_info(max_weight_shower) |
367 | common/cwgtsinfo/weights_info |
368 | c Initialize histograms |
369 | call HwU_inithist(nwgt,weights_info) |
370 | |
371 | === modified file 'Template/NLO/MCatNLO/HWAnalyzer/hw6an_HwU_rates.f' |
372 | --- Template/NLO/MCatNLO/HWAnalyzer/hw6an_HwU_rates.f 2015-12-04 15:47:32 +0000 |
373 | +++ Template/NLO/MCatNLO/HWAnalyzer/hw6an_HwU_rates.f 2016-03-04 16:01:53 +0000 |
374 | @@ -42,11 +42,7 @@ |
375 | integer nwgt,max_weight,nwgt_analysis |
376 | common/cnwgt/nwgt |
377 | common/c_analysis/nwgt_analysis |
378 | - integer maxRWGT |
379 | - parameter (maxRWGT=100) |
380 | - double precision wgtxsecRWGT(maxRWGT) |
381 | - parameter (max_weight=maxscales*maxscales+maxpdfs+maxRWGT+1) |
382 | - character*15 weights_info(max_weight) |
383 | + character*50 weights_info(max_weight_shower) |
384 | common/cwgtsinfo/weights_info |
385 | c Initialize histograms |
386 | call HwU_inithist(nwgt,weights_info) |
387 | |
388 | === modified file 'Template/NLO/MCatNLO/HWAnalyzer/mcatnlo_hwan_pp_V.f' |
389 | --- Template/NLO/MCatNLO/HWAnalyzer/mcatnlo_hwan_pp_V.f 2014-03-07 07:46:55 +0000 |
390 | +++ Template/NLO/MCatNLO/HWAnalyzer/mcatnlo_hwan_pp_V.f 2016-03-04 16:01:53 +0000 |
391 | @@ -25,8 +25,7 @@ |
392 | integer nwgt,max_weight,nwgt_analysis |
393 | common/cnwgt/nwgt |
394 | common/c_analysis/nwgt_analysis |
395 | - parameter (max_weight=maxscales*maxscales+maxpdfs+1) |
396 | - character*15 weights_info(max_weight) |
397 | + character*50 weights_info(max_weight_shower) |
398 | common/cwgtsinfo/weights_info |
399 | c |
400 | call inihist |
401 | |
402 | === modified file 'Template/NLO/MCatNLO/HWAnalyzer/mcatnlo_hwan_pp_h.f' |
403 | --- Template/NLO/MCatNLO/HWAnalyzer/mcatnlo_hwan_pp_h.f 2014-03-07 07:46:55 +0000 |
404 | +++ Template/NLO/MCatNLO/HWAnalyzer/mcatnlo_hwan_pp_h.f 2016-03-04 16:01:53 +0000 |
405 | @@ -17,8 +17,7 @@ |
406 | integer nwgt,max_weight,nwgt_analysis,kk,l |
407 | common/cnwgt/nwgt |
408 | common/c_analysis/nwgt_analysis |
409 | - parameter (max_weight=maxscales*maxscales+maxpdfs+1) |
410 | - character*15 weights_info(max_weight) |
411 | + character*50 weights_info(max_weight_shower) |
412 | common/cwgtsinfo/weights_info |
413 | call inihist |
414 | nwgt_analysis=nwgt |
415 | |
416 | === modified file 'Template/NLO/MCatNLO/HWAnalyzer/mcatnlo_hwan_pp_hjj.f' |
417 | --- Template/NLO/MCatNLO/HWAnalyzer/mcatnlo_hwan_pp_hjj.f 2014-03-07 07:46:55 +0000 |
418 | +++ Template/NLO/MCatNLO/HWAnalyzer/mcatnlo_hwan_pp_hjj.f 2016-03-04 16:01:53 +0000 |
419 | @@ -17,8 +17,7 @@ |
420 | integer nwgt,max_weight,nwgt_analysis |
421 | common/cnwgt/nwgt |
422 | common/c_analysis/nwgt_analysis |
423 | - parameter (max_weight=maxscales*maxscales+maxpdfs+1) |
424 | - character*15 weights_info(max_weight) |
425 | + character*50 weights_info(max_weight_shower) |
426 | common/cwgtsinfo/weights_info |
427 | character*8 cc(2) |
428 | data cc/' ','vbfcuts '/ |
429 | |
430 | === modified file 'Template/NLO/MCatNLO/HWAnalyzer/mcatnlo_hwan_pp_leptons.f' |
431 | --- Template/NLO/MCatNLO/HWAnalyzer/mcatnlo_hwan_pp_leptons.f 2014-02-12 10:28:36 +0000 |
432 | +++ Template/NLO/MCatNLO/HWAnalyzer/mcatnlo_hwan_pp_leptons.f 2016-03-04 16:01:53 +0000 |
433 | @@ -17,8 +17,7 @@ |
434 | integer nwgt,max_weight,nwgt_analysis |
435 | common/cnwgt/nwgt |
436 | common/c_analysis/nwgt_analysis |
437 | - parameter (max_weight=maxscales*maxscales+maxpdfs+1) |
438 | - character*15 weights_info(max_weight) |
439 | + character*50 weights_info(max_weight_shower) |
440 | common/cwgtsinfo/weights_info |
441 | integer nsingle,ncorr,nlepton,nplots,ncuts |
442 | common/cplots/nsingle,ncorr,nlepton,nplots,ncuts |
443 | |
444 | === modified file 'Template/NLO/MCatNLO/HWAnalyzer/mcatnlo_hwan_pp_lplm.f' |
445 | --- Template/NLO/MCatNLO/HWAnalyzer/mcatnlo_hwan_pp_lplm.f 2016-02-17 14:32:27 +0000 |
446 | +++ Template/NLO/MCatNLO/HWAnalyzer/mcatnlo_hwan_pp_lplm.f 2016-03-04 16:01:53 +0000 |
447 | @@ -22,8 +22,7 @@ |
448 | integer nwgt,max_weight,nwgt_analysis |
449 | common/cnwgt/nwgt |
450 | common/c_analysis/nwgt_analysis |
451 | - parameter (max_weight=maxscales*maxscales+maxpdfs+1) |
452 | - character*15 weights_info(max_weight) |
453 | + character*50 weights_info(max_weight_shower) |
454 | common/cwgtsinfo/weights_info |
455 | call inihist |
456 | nwgt_analysis=nwgt |
457 | |
458 | === modified file 'Template/NLO/MCatNLO/HWAnalyzer/mcatnlo_hwan_pp_lvl.f' |
459 | --- Template/NLO/MCatNLO/HWAnalyzer/mcatnlo_hwan_pp_lvl.f 2014-03-07 07:46:55 +0000 |
460 | +++ Template/NLO/MCatNLO/HWAnalyzer/mcatnlo_hwan_pp_lvl.f 2016-03-04 16:01:53 +0000 |
461 | @@ -25,8 +25,7 @@ |
462 | integer nwgt,max_weight,nwgt_analysis |
463 | common/cnwgt/nwgt |
464 | common/c_analysis/nwgt_analysis |
465 | - parameter (max_weight=maxscales*maxscales+maxpdfs+1) |
466 | - character*15 weights_info(max_weight) |
467 | + character*50 weights_info(max_weight_shower) |
468 | common/cwgtsinfo/weights_info |
469 | c |
470 | call inihist |
471 | |
472 | === modified file 'Template/NLO/MCatNLO/HWAnalyzer/mcatnlo_hwan_pp_taptam.f' |
473 | --- Template/NLO/MCatNLO/HWAnalyzer/mcatnlo_hwan_pp_taptam.f 2014-03-07 07:46:55 +0000 |
474 | +++ Template/NLO/MCatNLO/HWAnalyzer/mcatnlo_hwan_pp_taptam.f 2016-03-04 16:01:53 +0000 |
475 | @@ -20,8 +20,7 @@ |
476 | integer nwgt,max_weight,nwgt_analysis |
477 | common/cnwgt/nwgt |
478 | common/c_analysis/nwgt_analysis |
479 | - parameter (max_weight=maxscales*maxscales+maxpdfs+1) |
480 | - character*15 weights_info(max_weight) |
481 | + character*50 weights_info(max_weight_shower) |
482 | common/cwgtsinfo/weights_info |
483 | call inihist |
484 | nwgt_analysis=nwgt |
485 | |
486 | === modified file 'Template/NLO/MCatNLO/HWAnalyzer/mcatnlo_hwan_pp_tj.f' |
487 | --- Template/NLO/MCatNLO/HWAnalyzer/mcatnlo_hwan_pp_tj.f 2014-03-07 07:46:55 +0000 |
488 | +++ Template/NLO/MCatNLO/HWAnalyzer/mcatnlo_hwan_pp_tj.f 2016-03-04 16:01:53 +0000 |
489 | @@ -22,8 +22,7 @@ |
490 | integer nwgt,max_weight,nwgt_analysis |
491 | common/cnwgt/nwgt |
492 | common/c_analysis/nwgt_analysis |
493 | - parameter (max_weight=maxscales*maxscales+maxpdfs+1) |
494 | - character*15 weights_info(max_weight) |
495 | + character*50 weights_info(max_weight_shower) |
496 | common/cwgtsinfo/weights_info |
497 | call inihist |
498 | nwgt_analysis=nwgt |
499 | |
500 | === modified file 'Template/NLO/MCatNLO/HWAnalyzer/mcatnlo_hwan_pp_ttx.f' |
501 | --- Template/NLO/MCatNLO/HWAnalyzer/mcatnlo_hwan_pp_ttx.f 2014-03-07 07:46:55 +0000 |
502 | +++ Template/NLO/MCatNLO/HWAnalyzer/mcatnlo_hwan_pp_ttx.f 2016-03-04 16:01:53 +0000 |
503 | @@ -22,8 +22,7 @@ |
504 | integer nwgt,max_weight,nwgt_analysis |
505 | common/cnwgt/nwgt |
506 | common/c_analysis/nwgt_analysis |
507 | - parameter (max_weight=maxscales*maxscales+maxpdfs+1) |
508 | - character*15 weights_info(max_weight) |
509 | + character*50 weights_info(max_weight_shower) |
510 | common/cwgtsinfo/weights_info |
511 | c |
512 | call inihist |
513 | |
514 | === modified file 'Template/NLO/MCatNLO/HWAnalyzer/mcatnlo_hwan_pp_ttx_v2.f' |
515 | --- Template/NLO/MCatNLO/HWAnalyzer/mcatnlo_hwan_pp_ttx_v2.f 2014-03-07 07:46:55 +0000 |
516 | +++ Template/NLO/MCatNLO/HWAnalyzer/mcatnlo_hwan_pp_ttx_v2.f 2016-03-04 16:01:53 +0000 |
517 | @@ -22,8 +22,7 @@ |
518 | integer nwgt,max_weight,nwgt_analysis |
519 | common/cnwgt/nwgt |
520 | common/c_analysis/nwgt_analysis |
521 | - parameter (max_weight=maxscales*maxscales+maxpdfs+1) |
522 | - character*15 weights_info(max_weight) |
523 | + character*50 weights_info(max_weight_shower) |
524 | common/cwgtsinfo/weights_info |
525 | c |
526 | call inihist |
527 | |
528 | === modified file 'Template/NLO/MCatNLO/HWAnalyzer/mcatnlo_hwan_rates.f' |
529 | --- Template/NLO/MCatNLO/HWAnalyzer/mcatnlo_hwan_rates.f 2014-03-07 07:46:55 +0000 |
530 | +++ Template/NLO/MCatNLO/HWAnalyzer/mcatnlo_hwan_rates.f 2016-03-04 16:01:53 +0000 |
531 | @@ -16,8 +16,7 @@ |
532 | integer nwgt,max_weight,nwgt_analysis |
533 | common/cnwgt/nwgt |
534 | common/c_analysis/nwgt_analysis |
535 | - parameter (max_weight=maxscales*maxscales+maxpdfs+1) |
536 | - character*15 weights_info(max_weight) |
537 | + character*50 weights_info(max_weight_shower) |
538 | common/cwgtsinfo/weights_info |
539 | c |
540 | call inihist |
541 | |
542 | === modified file 'Template/NLO/MCatNLO/PY8Analyzer/mcatnlo_pyan_pp_V_hepmc.f' |
543 | --- Template/NLO/MCatNLO/PY8Analyzer/mcatnlo_pyan_pp_V_hepmc.f 2014-05-16 13:57:11 +0000 |
544 | +++ Template/NLO/MCatNLO/PY8Analyzer/mcatnlo_pyan_pp_V_hepmc.f 2016-03-04 16:01:53 +0000 |
545 | @@ -22,12 +22,10 @@ |
546 | integer j,kk,l,jpr,i,nnn |
547 | character*5 cc(2) |
548 | data cc/' ','Born '/ |
549 | - integer nwgt,max_weight,nwgt_analysis |
550 | - common/cnwgt/nwgt |
551 | + integer nwgt_analysis |
552 | common/c_analysis/nwgt_analysis |
553 | - parameter (max_weight=maxscales*maxscales+maxpdfs+1) |
554 | - character*15 weights_info(max_weight),wwwi(max_weight) |
555 | - common/cwgtsinfo/weights_info |
556 | + character*50 weights_info(max_weight_shower) |
557 | + $ ,wwwi(max_weight_shower) |
558 | c |
559 | call inihist |
560 | weights_info(1)="central value " |
561 | |
562 | === modified file 'Template/NLO/MCatNLO/PY8Analyzer/mcatnlo_pyan_pp_h_hepmc.f' |
563 | --- Template/NLO/MCatNLO/PY8Analyzer/mcatnlo_pyan_pp_h_hepmc.f 2014-05-16 13:57:11 +0000 |
564 | +++ Template/NLO/MCatNLO/PY8Analyzer/mcatnlo_pyan_pp_h_hepmc.f 2016-03-04 16:01:53 +0000 |
565 | @@ -14,12 +14,11 @@ |
566 | C---------------------------------------------------------------------- |
567 | INCLUDE 'HEPMC.INC' |
568 | include 'reweight0.inc' |
569 | - integer nwgt,max_weight,nwgt_analysis,kk,l,nnn |
570 | - common/cnwgt/nwgt |
571 | + integer nwgt,nwgt_analysis,kk,l,nnn |
572 | + integer nwgt_analysis |
573 | common/c_analysis/nwgt_analysis |
574 | - parameter (max_weight=maxscales*maxscales+maxpdfs+1) |
575 | - character*15 weights_info(max_weight),wwwi(max_weight) |
576 | - common/cwgtsinfo/weights_info |
577 | + character*50 weights_info(max_weight_shower) |
578 | + $ ,wwwi(max_weight_shower) |
579 | c |
580 | call inihist |
581 | weights_info(1)="central value " |
582 | |
583 | === modified file 'Template/NLO/MCatNLO/PY8Analyzer/mcatnlo_pyan_pp_hjj_hepmc.f' |
584 | --- Template/NLO/MCatNLO/PY8Analyzer/mcatnlo_pyan_pp_hjj_hepmc.f 2014-05-16 13:57:11 +0000 |
585 | +++ Template/NLO/MCatNLO/PY8Analyzer/mcatnlo_pyan_pp_hjj_hepmc.f 2016-03-04 16:01:53 +0000 |
586 | @@ -17,12 +17,10 @@ |
587 | REAL*8 pi |
588 | PARAMETER (PI=3.14159265358979312D0) |
589 | integer j,kk,l,i,nnn |
590 | - integer nwgt,max_weight,nwgt_analysis |
591 | - common/cnwgt/nwgt |
592 | + integer nwgt_analysis |
593 | common/c_analysis/nwgt_analysis |
594 | - parameter (max_weight=maxscales*maxscales+maxpdfs+1) |
595 | - character*15 weights_info(max_weight),wwwi(max_weight) |
596 | - common/cwgtsinfo/weights_info |
597 | + character*50 weights_info(max_weight_shower) |
598 | + $ ,wwwi(max_weight_shower) |
599 | character*8 cc(2) |
600 | data cc/' ','vbfcuts '/ |
601 | real*8 vetomin, vetomax |
602 | |
603 | === modified file 'Template/NLO/MCatNLO/PY8Analyzer/mcatnlo_pyan_pp_leptons_hepmc.f' |
604 | --- Template/NLO/MCatNLO/PY8Analyzer/mcatnlo_pyan_pp_leptons_hepmc.f 2014-05-16 13:57:11 +0000 |
605 | +++ Template/NLO/MCatNLO/PY8Analyzer/mcatnlo_pyan_pp_leptons_hepmc.f 2016-03-04 16:01:53 +0000 |
606 | @@ -14,12 +14,10 @@ |
607 | C---------------------------------------------------------------------- |
608 | INCLUDE 'HEPMC.INC' |
609 | include 'reweight0.inc' |
610 | - integer nwgt,max_weight,nwgt_analysis |
611 | - common/cnwgt/nwgt |
612 | + integer nwgt_analysis |
613 | common/c_analysis/nwgt_analysis |
614 | - parameter (max_weight=maxscales*maxscales+maxpdfs+1) |
615 | - character*15 weights_info(max_weight),wwwi(max_weight) |
616 | - common/cwgtsinfo/weights_info |
617 | + character*50 weights_info(max_weight_shower) |
618 | + $ ,wwwi(max_weight_shower) |
619 | integer nsingle,ncorr,nlepton,nplots,ncuts |
620 | common/cplots/nsingle,ncorr,nlepton,nplots,ncuts |
621 | integer MAXELM,MAXELP,MAXMUM,MAXMUP |
622 | |
623 | === modified file 'Template/NLO/MCatNLO/PY8Analyzer/mcatnlo_pyan_pp_lplm_hepmc.f' |
624 | --- Template/NLO/MCatNLO/PY8Analyzer/mcatnlo_pyan_pp_lplm_hepmc.f 2016-02-17 14:32:27 +0000 |
625 | +++ Template/NLO/MCatNLO/PY8Analyzer/mcatnlo_pyan_pp_lplm_hepmc.f 2016-03-04 16:01:53 +0000 |
626 | @@ -19,12 +19,10 @@ |
627 | integer j,kk,l,jpr,i,nnn |
628 | character*5 cc(2) |
629 | data cc/' ','cuts '/ |
630 | - integer nwgt,max_weight,nwgt_analysis |
631 | - common/cnwgt/nwgt |
632 | + integer nwgt_analysis |
633 | common/c_analysis/nwgt_analysis |
634 | - parameter (max_weight=maxscales*maxscales+maxpdfs+1) |
635 | - character*15 weights_info(max_weight),wwwi(max_weight) |
636 | - common/cwgtsinfo/weights_info |
637 | + character*50 weights_info(max_weight_shower) |
638 | + $ ,wwwi(max_weight_shower) |
639 | c |
640 | call inihist |
641 | weights_info(1)="central value " |
642 | |
643 | === modified file 'Template/NLO/MCatNLO/PY8Analyzer/mcatnlo_pyan_pp_lvl_hepmc.f' |
644 | --- Template/NLO/MCatNLO/PY8Analyzer/mcatnlo_pyan_pp_lvl_hepmc.f 2014-05-16 13:57:11 +0000 |
645 | +++ Template/NLO/MCatNLO/PY8Analyzer/mcatnlo_pyan_pp_lvl_hepmc.f 2016-03-04 16:01:53 +0000 |
646 | @@ -22,12 +22,10 @@ |
647 | integer j,kk,l,i,nnn |
648 | character*5 cc(2) |
649 | data cc/' ','Born '/ |
650 | - integer nwgt,max_weight,nwgt_analysis |
651 | - common/cnwgt/nwgt |
652 | + integer nwgt_analysis |
653 | common/c_analysis/nwgt_analysis |
654 | - parameter (max_weight=maxscales*maxscales+maxpdfs+1) |
655 | - character*15 weights_info(max_weight),wwwi(max_weight) |
656 | - common/cwgtsinfo/weights_info |
657 | + character*50 weights_info(max_weight_shower) |
658 | + $ ,wwwi(max_weight_shower) |
659 | c |
660 | call inihist |
661 | weights_info(1)="central value " |
662 | |
663 | === modified file 'Template/NLO/MCatNLO/PY8Analyzer/mcatnlo_pyan_pp_taptam_hepmc.f' |
664 | --- Template/NLO/MCatNLO/PY8Analyzer/mcatnlo_pyan_pp_taptam_hepmc.f 2014-05-16 13:57:11 +0000 |
665 | +++ Template/NLO/MCatNLO/PY8Analyzer/mcatnlo_pyan_pp_taptam_hepmc.f 2016-03-04 16:01:53 +0000 |
666 | @@ -17,12 +17,10 @@ |
667 | integer j,kk,l,i,nnn |
668 | character*5 cc(2) |
669 | data cc/' ','Born '/ |
670 | - integer nwgt,max_weight,nwgt_analysis |
671 | - common/cnwgt/nwgt |
672 | + integer nwgt_analysis |
673 | common/c_analysis/nwgt_analysis |
674 | - parameter (max_weight=maxscales*maxscales+maxpdfs+1) |
675 | - character*15 weights_info(max_weight),wwwi(max_weight) |
676 | - common/cwgtsinfo/weights_info |
677 | + character*50 weights_info(max_weight_shower) |
678 | + $ ,wwwi(max_weight_shower) |
679 | c |
680 | call inihist |
681 | weights_info(1)="central value " |
682 | |
683 | === modified file 'Template/NLO/MCatNLO/PY8Analyzer/mcatnlo_pyan_pp_tj_hepmc.f' |
684 | --- Template/NLO/MCatNLO/PY8Analyzer/mcatnlo_pyan_pp_tj_hepmc.f 2014-05-16 13:57:11 +0000 |
685 | +++ Template/NLO/MCatNLO/PY8Analyzer/mcatnlo_pyan_pp_tj_hepmc.f 2016-03-04 16:01:53 +0000 |
686 | @@ -21,12 +21,10 @@ |
687 | integer j,kk,l,i,nnn |
688 | character*5 cc(2) |
689 | data cc/' ','Born '/ |
690 | - integer nwgt,max_weight,nwgt_analysis |
691 | - common/cnwgt/nwgt |
692 | + integer nwgt_analysis |
693 | common/c_analysis/nwgt_analysis |
694 | - parameter (max_weight=maxscales*maxscales+maxpdfs+1) |
695 | - character*15 weights_info(max_weight),wwwi(max_weight) |
696 | - common/cwgtsinfo/weights_info |
697 | + character*50 weights_info(max_weight_shower) |
698 | + $ ,wwwi(max_weight_shower) |
699 | c |
700 | call inihist |
701 | weights_info(1)="central value " |
702 | |
703 | === modified file 'Template/NLO/MCatNLO/PY8Analyzer/mcatnlo_pyan_pp_ttx_hepmc.f' |
704 | --- Template/NLO/MCatNLO/PY8Analyzer/mcatnlo_pyan_pp_ttx_hepmc.f 2014-05-16 13:57:11 +0000 |
705 | +++ Template/NLO/MCatNLO/PY8Analyzer/mcatnlo_pyan_pp_ttx_hepmc.f 2016-03-04 16:01:53 +0000 |
706 | @@ -19,12 +19,10 @@ |
707 | integer j,kk,l,i,nnn |
708 | character*5 cc(2) |
709 | data cc/' ','cuts '/ |
710 | - integer nwgt,max_weight,nwgt_analysis |
711 | - common/cnwgt/nwgt |
712 | + integer nwgt_analysis |
713 | common/c_analysis/nwgt_analysis |
714 | - parameter (max_weight=maxscales*maxscales+maxpdfs+1) |
715 | - character*15 weights_info(max_weight),wwwi(max_weight) |
716 | - common/cwgtsinfo/weights_info |
717 | + character*50 weights_info(max_weight_shower) |
718 | + $ ,wwwi(max_weight_shower) |
719 | c |
720 | call inihist |
721 | weights_info(1)="central value " |
722 | |
723 | === modified file 'Template/NLO/MCatNLO/PY8Analyzer/mcatnlo_pyan_pp_ttx_v2_hepmc.f' |
724 | --- Template/NLO/MCatNLO/PY8Analyzer/mcatnlo_pyan_pp_ttx_v2_hepmc.f 2014-05-16 13:57:11 +0000 |
725 | +++ Template/NLO/MCatNLO/PY8Analyzer/mcatnlo_pyan_pp_ttx_v2_hepmc.f 2016-03-04 16:01:53 +0000 |
726 | @@ -19,12 +19,10 @@ |
727 | integer j,kk,l,i,nnn |
728 | character*5 cc(2) |
729 | data cc/' ','Born '/ |
730 | - integer nwgt,max_weight,nwgt_analysis |
731 | - common/cnwgt/nwgt |
732 | + integer nwgt_analysis |
733 | common/c_analysis/nwgt_analysis |
734 | - parameter (max_weight=maxscales*maxscales+maxpdfs+1) |
735 | - character*15 weights_info(max_weight),wwwi(max_weight) |
736 | - common/cwgtsinfo/weights_info |
737 | + character*50 weights_info(max_weight_shower) |
738 | + $ ,wwwi(max_weight_shower) |
739 | c |
740 | call inihist |
741 | weights_info(1)="central value " |
742 | |
743 | === modified file 'Template/NLO/MCatNLO/PY8Analyzer/mcatnlo_pyan_rates_hepmc.f' |
744 | --- Template/NLO/MCatNLO/PY8Analyzer/mcatnlo_pyan_rates_hepmc.f 2014-05-16 13:57:11 +0000 |
745 | +++ Template/NLO/MCatNLO/PY8Analyzer/mcatnlo_pyan_rates_hepmc.f 2016-03-04 16:01:53 +0000 |
746 | @@ -14,12 +14,10 @@ |
747 | integer j,kk,l,i,nnn |
748 | character*5 cc(2) |
749 | data cc/' ','Born '/ |
750 | - integer nwgt,max_weight,nwgt_analysis |
751 | - common/cnwgt/nwgt |
752 | + integer nwgt_analysis |
753 | common/c_analysis/nwgt_analysis |
754 | - parameter (max_weight=maxscales*maxscales+maxpdfs+1) |
755 | - character*15 weights_info(max_weight),wwwi(max_weight) |
756 | - common/cwgtsinfo/weights_info |
757 | + character*50 weights_info(max_weight_shower) |
758 | + $ ,wwwi(max_weight_shower) |
759 | c |
760 | call inihist |
761 | weights_info(1)="central value " |
762 | |
763 | === modified file 'Template/NLO/MCatNLO/PY8Analyzer/py8an_HwU_pp_V.f' |
764 | --- Template/NLO/MCatNLO/PY8Analyzer/py8an_HwU_pp_V.f 2015-12-04 15:47:32 +0000 |
765 | +++ Template/NLO/MCatNLO/PY8Analyzer/py8an_HwU_pp_V.f 2016-03-04 16:01:53 +0000 |
766 | @@ -46,21 +46,15 @@ |
767 | integer j,kk,l,jpr,i,nnn |
768 | character*5 cc(2) |
769 | data cc/' ','Born '/ |
770 | - integer nwgt,max_weight,nwgt_analysis |
771 | - common/cnwgt/nwgt |
772 | + integer nwgt_analysis |
773 | common/c_analysis/nwgt_analysis |
774 | - integer maxRWGT |
775 | - parameter (maxRWGT=100) |
776 | - double precision wgtxsecRWGT(maxRWGT) |
777 | - parameter (max_weight=maxscales*maxscales+maxpdfs+maxRWGT+1) |
778 | - character*15 weights_info(max_weight),wwwi(max_weight) |
779 | - common/cwgtsinfo/weights_info |
780 | + character*50 weights_info(max_weight_shower) |
781 | + $ ,wwwi(max_weight_shower) |
782 | c |
783 | - weights_info(1)="central value " |
784 | - do i=1,nnn+1 |
785 | + do i=1,nnn |
786 | weights_info(i+1)=wwwi(i) |
787 | enddo |
788 | - nwgt=nnn+1 |
789 | + nwgt=nnn |
790 | c Initialize histograms |
791 | call HwU_inithist(nwgt,weights_info) |
792 | c Set method for error estimation to '0', i.e., use Poisson statistics |
793 | @@ -126,9 +120,8 @@ |
794 | double precision ww(max_weight),www(max_weight),xww(max_weight) |
795 | common/cww/ww |
796 | c |
797 | - ww(1)=xww(2) |
798 | if(nnn.eq.0)ww(1)=1d0 |
799 | - do i=2,nnn+1 |
800 | + do i=1,nnn |
801 | ww(i)=xww(i) |
802 | enddo |
803 | c |
804 | |
805 | === modified file 'Template/NLO/MCatNLO/PY8Analyzer/py8an_HwU_pp_h.f' |
806 | --- Template/NLO/MCatNLO/PY8Analyzer/py8an_HwU_pp_h.f 2015-12-04 15:47:32 +0000 |
807 | +++ Template/NLO/MCatNLO/PY8Analyzer/py8an_HwU_pp_h.f 2016-03-04 16:01:53 +0000 |
808 | @@ -43,21 +43,15 @@ |
809 | c |
810 | character*8 HwUtype(2) |
811 | data HwUtype/'|T@NOCUT','|T@CUT '/ |
812 | - integer nwgt,max_weight,nwgt_analysis |
813 | - common/cnwgt/nwgt |
814 | + integer nwgt_analysis |
815 | common/c_analysis/nwgt_analysis |
816 | - integer maxRWGT |
817 | - parameter (maxRWGT=100) |
818 | - double precision wgtxsecRWGT(maxRWGT) |
819 | - parameter (max_weight=maxscales*maxscales+maxpdfs+maxRWGT+1) |
820 | - character*15 weights_info(max_weight),wwwi(max_weight) |
821 | - common/cwgtsinfo/weights_info |
822 | + character*50 weights_info(max_weight_shower) |
823 | + $ ,wwwi(max_weight_shower) |
824 | c |
825 | - weights_info(1)="central value " |
826 | - do i=1,nnn+1 |
827 | - weights_info(i+1)=wwwi(i) |
828 | + do i=1,nnn |
829 | + weights_info(i)=wwwi(i) |
830 | enddo |
831 | - nwgt=nnn+1 |
832 | + nwgt=nnn |
833 | c Initialize histograms |
834 | call HwU_inithist(nwgt,weights_info) |
835 | c Set method for error estimation to '0', i.e., use Poisson statistics |
836 | @@ -164,9 +158,8 @@ |
837 | double precision ww(max_weight),www(max_weight),xww(max_weight) |
838 | common/cww/ww |
839 | c |
840 | - ww(1)=xww(2) |
841 | if(nnn.eq.0)ww(1)=1d0 |
842 | - do i=2,nnn+1 |
843 | + do i=,nnn |
844 | ww(i)=xww(i) |
845 | enddo |
846 | c |
847 | |
848 | === modified file 'Template/NLO/MCatNLO/PY8Analyzer/py8an_HwU_pp_hjj.f' |
849 | --- Template/NLO/MCatNLO/PY8Analyzer/py8an_HwU_pp_hjj.f 2015-12-04 15:47:32 +0000 |
850 | +++ Template/NLO/MCatNLO/PY8Analyzer/py8an_HwU_pp_hjj.f 2016-03-04 16:01:53 +0000 |
851 | @@ -43,26 +43,20 @@ |
852 | c |
853 | character*8 HwUtype(2) |
854 | data HwUtype/'|T@NOCUT','|T@CUT '/ |
855 | - integer nwgt,max_weight,nwgt_analysis |
856 | - common/cnwgt/nwgt |
857 | + integer nwgt_analysis |
858 | common/c_analysis/nwgt_analysis |
859 | - integer maxRWGT |
860 | - parameter (maxRWGT=100) |
861 | - double precision wgtxsecRWGT(maxRWGT) |
862 | - parameter (max_weight=maxscales*maxscales+maxpdfs+maxRWGT+1) |
863 | - character*15 weights_info(max_weight),wwwi(max_weight) |
864 | - common/cwgtsinfo/weights_info |
865 | + character*50 weights_info(max_weight_shower) |
866 | + $ ,wwwi(max_weight_shower) |
867 | character*8 cc(2) |
868 | data cc/' ','vbfcuts '/ |
869 | real*8 vetomin, vetomax |
870 | integer nbinveto |
871 | common /to_veto_hist/vetomin,vetomax,nbinveto |
872 | c |
873 | - weights_info(1)="central value " |
874 | - do i=1,nnn+1 |
875 | - weights_info(i+1)=wwwi(i) |
876 | + do i=1,nnn |
877 | + weights_info(i)=wwwi(i) |
878 | enddo |
879 | - nwgt=nnn+1 |
880 | + nwgt=nnn |
881 | c Initialize histograms |
882 | call HwU_inithist(nwgt,weights_info) |
883 | c Set method for error estimation to '0', i.e., use Poisson statistics |
884 | @@ -216,9 +210,8 @@ |
885 | double precision ww(max_weight),www(max_weight),xww(max_weight) |
886 | common/cww/ww |
887 | c |
888 | - ww(1)=xww(2) |
889 | if(nnn.eq.0)ww(1)=1d0 |
890 | - do i=2,nnn+1 |
891 | + do i=1,nnn |
892 | ww(i)=xww(i) |
893 | enddo |
894 | c |
895 | |
896 | === modified file 'Template/NLO/MCatNLO/PY8Analyzer/py8an_HwU_pp_leptons.f' |
897 | --- Template/NLO/MCatNLO/PY8Analyzer/py8an_HwU_pp_leptons.f 2015-12-04 15:47:32 +0000 |
898 | +++ Template/NLO/MCatNLO/PY8Analyzer/py8an_HwU_pp_leptons.f 2016-03-04 16:01:53 +0000 |
899 | @@ -41,15 +41,10 @@ |
900 | character*8 HwUtype(2) |
901 | data HwUtype/'|T@NOCUT','|T@CUT '/ |
902 | integer j,jpr |
903 | - integer nwgt,max_weight,nwgt_analysis |
904 | - common/cnwgt/nwgt |
905 | + integer nwgt_analysis |
906 | common/c_analysis/nwgt_analysis |
907 | - integer maxRWGT |
908 | - parameter (maxRWGT=100) |
909 | - double precision wgtxsecRWGT(maxRWGT) |
910 | - parameter (max_weight=maxscales*maxscales+maxpdfs+maxRWGT+1) |
911 | - character*15 weights_info(max_weight),wwwi(max_weight) |
912 | - common/cwgtsinfo/weights_info |
913 | + character*50 weights_info(max_weight_shower) |
914 | + $ ,wwwi(max_weight_shower) |
915 | integer nsingle,ncorr,nlepton,nplots,ncuts |
916 | common/cplots/nsingle,ncorr,nlepton,nplots,ncuts |
917 | integer MAXELM,MAXELP,MAXMUM,MAXMUP |
918 | @@ -67,11 +62,10 @@ |
919 | integer i,kk,l,icuts,nnn |
920 | integer l0,ilep1,ilep2,io,ipair |
921 | c |
922 | - weights_info(1)="central value " |
923 | - do i=1,nnn+1 |
924 | - weights_info(i+1)=wwwi(i) |
925 | + do i=1,nnn |
926 | + weights_info(i)=wwwi(i) |
927 | enddo |
928 | - nwgt=nnn+1 |
929 | + nwgt=nnn |
930 | c Initialize histograms |
931 | call HwU_inithist(nwgt,weights_info) |
932 | c Set method for error estimation to '0', i.e., use Poisson statistics |
933 | @@ -219,9 +213,8 @@ |
934 | # PELM(4,25),PELP(4,25),PMUM(4,25),PMUP(4,25),PLEP(4,25), |
935 | # obs(100) |
936 | c |
937 | - ww(1)=xww(2) |
938 | if(nnn.eq.0)ww(1)=1d0 |
939 | - do i=2,nnn+1 |
940 | + do i=1,nnn |
941 | ww(i)=xww(i) |
942 | enddo |
943 | c |
944 | |
945 | === modified file 'Template/NLO/MCatNLO/PY8Analyzer/py8an_HwU_pp_lplm.f' |
946 | --- Template/NLO/MCatNLO/PY8Analyzer/py8an_HwU_pp_lplm.f 2016-02-17 14:32:27 +0000 |
947 | +++ Template/NLO/MCatNLO/PY8Analyzer/py8an_HwU_pp_lplm.f 2016-03-04 16:01:53 +0000 |
948 | @@ -45,21 +45,15 @@ |
949 | integer j,kk,l,jpr,i,nnn |
950 | character*5 cc(2) |
951 | data cc/' ','Born '/ |
952 | - integer nwgt,max_weight,nwgt_analysis |
953 | - common/cnwgt/nwgt |
954 | + integer nwgt_analysis |
955 | common/c_analysis/nwgt_analysis |
956 | - integer maxRWGT |
957 | - parameter (maxRWGT=100) |
958 | - double precision wgtxsecRWGT(maxRWGT) |
959 | - parameter (max_weight=maxscales*maxscales+maxpdfs+maxRWGT+1) |
960 | - character*15 weights_info(max_weight),wwwi(max_weight) |
961 | - common/cwgtsinfo/weights_info |
962 | + character*50 weights_info(max_weight_shower) |
963 | + $ ,wwwi(max_weight_shower) |
964 | c |
965 | - weights_info(1)="central value " |
966 | - do i=1,nnn+1 |
967 | - weights_info(i+1)=wwwi(i) |
968 | + do i=1,nnn |
969 | + weights_info(i)=wwwi(i) |
970 | enddo |
971 | - nwgt=nnn+1 |
972 | + nwgt=nnn |
973 | c Initialize histograms |
974 | call HwU_inithist(nwgt,weights_info) |
975 | c Set method for error estimation to '0', i.e., use Poisson statistics |
976 | @@ -140,9 +134,8 @@ |
977 | double precision ww(max_weight),www(max_weight),xww(max_weight) |
978 | common/cww/ww |
979 | c |
980 | - ww(1)=xww(2) |
981 | if(nnn.eq.0)ww(1)=1d0 |
982 | - do i=2,nnn+1 |
983 | + do i=1,nnn |
984 | ww(i)=xww(i) |
985 | enddo |
986 | c |
987 | |
988 | === modified file 'Template/NLO/MCatNLO/PY8Analyzer/py8an_HwU_pp_lvl.f' |
989 | --- Template/NLO/MCatNLO/PY8Analyzer/py8an_HwU_pp_lvl.f 2015-12-04 15:47:32 +0000 |
990 | +++ Template/NLO/MCatNLO/PY8Analyzer/py8an_HwU_pp_lvl.f 2016-03-04 16:01:53 +0000 |
991 | @@ -45,21 +45,15 @@ |
992 | integer j,kk,l,jpr,i,nnn |
993 | character*5 cc(2) |
994 | data cc/' ','Born '/ |
995 | - integer nwgt,max_weight,nwgt_analysis |
996 | - common/cnwgt/nwgt |
997 | + integer nwgt_analysis |
998 | common/c_analysis/nwgt_analysis |
999 | - integer maxRWGT |
1000 | - parameter (maxRWGT=100) |
1001 | - double precision wgtxsecRWGT(maxRWGT) |
1002 | - parameter (max_weight=maxscales*maxscales+maxpdfs+maxRWGT+1) |
1003 | - character*15 weights_info(max_weight),wwwi(max_weight) |
1004 | - common/cwgtsinfo/weights_info |
1005 | + character*50 weights_info(max_weight_shower) |
1006 | + $ ,wwwi(max_weight_shower) |
1007 | c |
1008 | - weights_info(1)="central value " |
1009 | - do i=1,nnn+1 |
1010 | - weights_info(i+1)=wwwi(i) |
1011 | + do i=1,nnn |
1012 | + weights_info(i)=wwwi(i) |
1013 | enddo |
1014 | - nwgt=nnn+1 |
1015 | + nwgt=nnn |
1016 | c Initialize histograms |
1017 | call HwU_inithist(nwgt,weights_info) |
1018 | c Set method for error estimation to '0', i.e., use Poisson statistics |
1019 | @@ -124,9 +118,8 @@ |
1020 | double precision ww(max_weight),www(max_weight),xww(max_weight) |
1021 | common/cww/ww |
1022 | c |
1023 | - ww(1)=xww(2) |
1024 | if(nnn.eq.0)ww(1)=1d0 |
1025 | - do i=2,nnn+1 |
1026 | + do i=1,nnn |
1027 | ww(i)=xww(i) |
1028 | enddo |
1029 | c |
1030 | |
1031 | === modified file 'Template/NLO/MCatNLO/PY8Analyzer/py8an_HwU_pp_taptam.f' |
1032 | --- Template/NLO/MCatNLO/PY8Analyzer/py8an_HwU_pp_taptam.f 2015-12-04 15:47:32 +0000 |
1033 | +++ Template/NLO/MCatNLO/PY8Analyzer/py8an_HwU_pp_taptam.f 2016-03-04 16:01:53 +0000 |
1034 | @@ -41,21 +41,15 @@ |
1035 | c |
1036 | character*8 HwUtype(2) |
1037 | data HwUtype/'|T@NOCUT','|T@CUT '/ |
1038 | - integer nwgt,max_weight,nwgt_analysis |
1039 | - common/cnwgt/nwgt |
1040 | + integer nwgt_analysis |
1041 | common/c_analysis/nwgt_analysis |
1042 | - integer maxRWGT |
1043 | - parameter (maxRWGT=100) |
1044 | - double precision wgtxsecRWGT(maxRWGT) |
1045 | - parameter (max_weight=maxscales*maxscales+maxpdfs+maxRWGT+1) |
1046 | - character*15 weights_info(max_weight),wwwi(max_weight) |
1047 | - common/cwgtsinfo/weights_info |
1048 | + character*50 weights_info(max_weight_shower) |
1049 | + $ ,wwwi(max_weight_shower) |
1050 | c |
1051 | - weights_info(1)="central value " |
1052 | - do i=1,nnn+1 |
1053 | - weights_info(i+1)=wwwi(i) |
1054 | + do i=1,nnn |
1055 | + weights_info(i)=wwwi(i) |
1056 | enddo |
1057 | - nwgt=nnn+1 |
1058 | + nwgt=nnn |
1059 | c Initialize histograms |
1060 | call HwU_inithist(nwgt,weights_info) |
1061 | c Set method for error estimation to '0', i.e., use Poisson statistics |
1062 | @@ -120,9 +114,8 @@ |
1063 | double precision ww(max_weight),www(max_weight),xww(max_weight) |
1064 | common/cww/ww |
1065 | c |
1066 | - ww(1)=xww(2) |
1067 | if(nnn.eq.0)ww(1)=1d0 |
1068 | - do i=2,nnn+1 |
1069 | + do i=1,nnn |
1070 | ww(i)=xww(i) |
1071 | enddo |
1072 | c |
1073 | |
1074 | === modified file 'Template/NLO/MCatNLO/PY8Analyzer/py8an_HwU_pp_tj.f' |
1075 | --- Template/NLO/MCatNLO/PY8Analyzer/py8an_HwU_pp_tj.f 2015-12-04 15:47:32 +0000 |
1076 | +++ Template/NLO/MCatNLO/PY8Analyzer/py8an_HwU_pp_tj.f 2016-03-04 16:01:53 +0000 |
1077 | @@ -43,21 +43,15 @@ |
1078 | c |
1079 | character*8 HwUtype(2) |
1080 | data HwUtype/'|T@NOCUT','|T@CUT '/ |
1081 | - integer nwgt,max_weight,nwgt_analysis |
1082 | - common/cnwgt/nwgt |
1083 | + integer nwgt_analysis |
1084 | common/c_analysis/nwgt_analysis |
1085 | - integer maxRWGT |
1086 | - parameter (maxRWGT=100) |
1087 | - double precision wgtxsecRWGT(maxRWGT) |
1088 | - parameter (max_weight=maxscales*maxscales+maxpdfs+maxRWGT+1) |
1089 | - character*15 weights_info(max_weight),wwwi(max_weight) |
1090 | - common/cwgtsinfo/weights_info |
1091 | + character*50 weights_info(max_weight_shower) |
1092 | + $ ,wwwi(max_weight_shower) |
1093 | c |
1094 | - weights_info(1)="central value " |
1095 | - do i=1,nnn+1 |
1096 | - weights_info(i+1)=wwwi(i) |
1097 | + do i=1,nnn |
1098 | + weights_info(i)=wwwi(i) |
1099 | enddo |
1100 | - nwgt=nnn+1 |
1101 | + nwgt=nnn |
1102 | c Initialize histograms |
1103 | call HwU_inithist(nwgt,weights_info) |
1104 | c Set method for error estimation to '0', i.e., use Poisson statistics |
1105 | @@ -151,9 +145,8 @@ |
1106 | double precision ww(max_weight),www(max_weight),xww(max_weight) |
1107 | common/cww/ww |
1108 | c |
1109 | - ww(1)=xww(2) |
1110 | if(nnn.eq.0)ww(1)=1d0 |
1111 | - do i=2,nnn+1 |
1112 | + do i=1,nnn |
1113 | ww(i)=xww(i) |
1114 | enddo |
1115 | c |
1116 | |
1117 | === modified file 'Template/NLO/MCatNLO/PY8Analyzer/py8an_HwU_pp_ttx.f' |
1118 | --- Template/NLO/MCatNLO/PY8Analyzer/py8an_HwU_pp_ttx.f 2015-12-04 15:47:32 +0000 |
1119 | +++ Template/NLO/MCatNLO/PY8Analyzer/py8an_HwU_pp_ttx.f 2016-03-04 16:01:53 +0000 |
1120 | @@ -43,21 +43,15 @@ |
1121 | c |
1122 | character*8 HwUtype(2) |
1123 | data HwUtype/'|T@NOCUT','|T@CUT '/ |
1124 | - integer nwgt,max_weight,nwgt_analysis |
1125 | - common/cnwgt/nwgt |
1126 | + integer nwgt_analysis |
1127 | common/c_analysis/nwgt_analysis |
1128 | - integer maxRWGT |
1129 | - parameter (maxRWGT=100) |
1130 | - double precision wgtxsecRWGT(maxRWGT) |
1131 | - parameter (max_weight=maxscales*maxscales+maxpdfs+maxRWGT+1) |
1132 | - character*15 weights_info(max_weight),wwwi(max_weight) |
1133 | - common/cwgtsinfo/weights_info |
1134 | + character*50 weights_info(max_weight_shower) |
1135 | + $ ,wwwi(max_weight_shower) |
1136 | c |
1137 | - weights_info(1)="central value " |
1138 | - do i=1,nnn+1 |
1139 | - weights_info(i+1)=wwwi(i) |
1140 | + do i=1,nnn |
1141 | + weights_info(i)=wwwi(i) |
1142 | enddo |
1143 | - nwgt=nnn+1 |
1144 | + nwgt=nnn |
1145 | c Initialize histograms |
1146 | call HwU_inithist(nwgt,weights_info) |
1147 | c Set method for error estimation to '0', i.e., use Poisson statistics |
1148 | @@ -148,9 +142,8 @@ |
1149 | double precision ww(max_weight),www(max_weight),xww(max_weight) |
1150 | common/cww/ww |
1151 | c |
1152 | - ww(1)=xww(2) |
1153 | if(nnn.eq.0)ww(1)=1d0 |
1154 | - do i=2,nnn+1 |
1155 | + do i=1,nnn |
1156 | ww(i)=xww(i) |
1157 | enddo |
1158 | c |
1159 | |
1160 | === modified file 'Template/NLO/MCatNLO/PY8Analyzer/py8an_HwU_pp_ttx_v2.f' |
1161 | --- Template/NLO/MCatNLO/PY8Analyzer/py8an_HwU_pp_ttx_v2.f 2015-12-04 15:47:32 +0000 |
1162 | +++ Template/NLO/MCatNLO/PY8Analyzer/py8an_HwU_pp_ttx_v2.f 2016-03-04 16:01:53 +0000 |
1163 | @@ -43,21 +43,15 @@ |
1164 | c |
1165 | character*8 HwUtype(2) |
1166 | data HwUtype/'|T@NOCUT','|T@CUT '/ |
1167 | - integer nwgt,max_weight,nwgt_analysis |
1168 | - common/cnwgt/nwgt |
1169 | + integer nwgt_analysis |
1170 | common/c_analysis/nwgt_analysis |
1171 | - integer maxRWGT |
1172 | - parameter (maxRWGT=100) |
1173 | - double precision wgtxsecRWGT(maxRWGT) |
1174 | - parameter (max_weight=maxscales*maxscales+maxpdfs+maxRWGT+1) |
1175 | - character*15 weights_info(max_weight),wwwi(max_weight) |
1176 | - common/cwgtsinfo/weights_info |
1177 | + character*50 weights_info(max_weight_shower) |
1178 | + $ ,wwwi(max_weight_shower) |
1179 | c |
1180 | - weights_info(1)="central value " |
1181 | - do i=1,nnn+1 |
1182 | - weights_info(i+1)=wwwi(i) |
1183 | + do i=1,nnn |
1184 | + weights_info(i)=wwwi(i) |
1185 | enddo |
1186 | - nwgt=nnn+1 |
1187 | + nwgt=nnn |
1188 | c Initialize histograms |
1189 | call HwU_inithist(nwgt,weights_info) |
1190 | c Set method for error estimation to '0', i.e., use Poisson statistics |
1191 | @@ -132,9 +126,8 @@ |
1192 | double precision ww(max_weight),www(max_weight),xww(max_weight) |
1193 | common/cww/ww |
1194 | c |
1195 | - ww(1)=xww(2) |
1196 | if(nnn.eq.0)ww(1)=1d0 |
1197 | - do i=2,nnn+1 |
1198 | + do i=1,nnn |
1199 | ww(i)=xww(i) |
1200 | enddo |
1201 | c |
1202 | |
1203 | === modified file 'Template/NLO/MCatNLO/PY8Analyzer/py8an_HwU_rates.f' |
1204 | --- Template/NLO/MCatNLO/PY8Analyzer/py8an_HwU_rates.f 2015-12-04 15:47:32 +0000 |
1205 | +++ Template/NLO/MCatNLO/PY8Analyzer/py8an_HwU_rates.f 2016-03-04 16:01:53 +0000 |
1206 | @@ -39,21 +39,15 @@ |
1207 | integer i,kk,l,nnn |
1208 | character*5 cc(2) |
1209 | data cc/' ','Born '/ |
1210 | - integer nwgt,max_weight,nwgt_analysis |
1211 | - common/cnwgt/nwgt |
1212 | + integer nwgt_analysis |
1213 | common/c_analysis/nwgt_analysis |
1214 | - integer maxRWGT |
1215 | - parameter (maxRWGT=100) |
1216 | - double precision wgtxsecRWGT(maxRWGT) |
1217 | - parameter (max_weight=maxscales*maxscales+maxpdfs+maxRWGT+1) |
1218 | - character*15 weights_info(max_weight),wwwi(max_weight) |
1219 | - common/cwgtsinfo/weights_info |
1220 | + character*50 weights_info(max_weight_shower) |
1221 | + $ ,wwwi(max_weight_shower) |
1222 | c |
1223 | - weights_info(1)="central value " |
1224 | - do i=1,nnn+1 |
1225 | - weights_info(i+1)=wwwi(i) |
1226 | + do i=1,nnn |
1227 | + weights_info(i)=wwwi(i) |
1228 | enddo |
1229 | - nwgt=nnn+1 |
1230 | + nwgt=nnn |
1231 | c Initialize histograms |
1232 | call HwU_inithist(nwgt,weights_info) |
1233 | c Set method for error estimation to '0', i.e., use Poisson statistics |
1234 | @@ -105,9 +99,8 @@ |
1235 | double precision ww(max_weight),www(max_weight),xww(max_weight) |
1236 | common/cww/ww |
1237 | c |
1238 | - ww(1)=xww(2) |
1239 | if(nnn.eq.0)ww(1)=1d0 |
1240 | - do i=2,nnn+1 |
1241 | + do i=1,nnn |
1242 | ww(i)=xww(i) |
1243 | enddo |
1244 | c |
1245 | |
1246 | === modified file 'Template/NLO/MCatNLO/PYAnalyzer/mcatnlo_pyan_pp_V.f' |
1247 | --- Template/NLO/MCatNLO/PYAnalyzer/mcatnlo_pyan_pp_V.f 2014-03-07 07:46:55 +0000 |
1248 | +++ Template/NLO/MCatNLO/PYAnalyzer/mcatnlo_pyan_pp_V.f 2016-03-04 16:01:53 +0000 |
1249 | @@ -27,8 +27,7 @@ |
1250 | integer nwgt,max_weight,nwgt_analysis |
1251 | common/cnwgt/nwgt |
1252 | common/c_analysis/nwgt_analysis |
1253 | - parameter (max_weight=maxscales*maxscales+maxpdfs+1) |
1254 | - character*15 weights_info(max_weight) |
1255 | + character*50 weights_info(max_weight_shower) |
1256 | common/cwgtsinfo/weights_info |
1257 | c |
1258 | call inihist |
1259 | |
1260 | === modified file 'Template/NLO/MCatNLO/PYAnalyzer/mcatnlo_pyan_pp_h.f' |
1261 | --- Template/NLO/MCatNLO/PYAnalyzer/mcatnlo_pyan_pp_h.f 2014-03-07 07:46:55 +0000 |
1262 | +++ Template/NLO/MCatNLO/PYAnalyzer/mcatnlo_pyan_pp_h.f 2016-03-04 16:01:53 +0000 |
1263 | @@ -17,8 +17,7 @@ |
1264 | integer nwgt,max_weight,nwgt_analysis,kk,l |
1265 | common/cnwgt/nwgt |
1266 | common/c_analysis/nwgt_analysis |
1267 | - parameter (max_weight=maxscales*maxscales+maxpdfs+1) |
1268 | - character*15 weights_info(max_weight) |
1269 | + character*50 weights_info(max_weight_shower) |
1270 | common/cwgtsinfo/weights_info |
1271 | call inihist |
1272 | nwgt_analysis=nwgt |
1273 | |
1274 | === modified file 'Template/NLO/MCatNLO/PYAnalyzer/mcatnlo_pyan_pp_hjj.f' |
1275 | --- Template/NLO/MCatNLO/PYAnalyzer/mcatnlo_pyan_pp_hjj.f 2014-03-07 07:46:55 +0000 |
1276 | +++ Template/NLO/MCatNLO/PYAnalyzer/mcatnlo_pyan_pp_hjj.f 2016-03-04 16:01:53 +0000 |
1277 | @@ -16,8 +16,7 @@ |
1278 | integer nwgt,max_weight,nwgt_analysis |
1279 | common/cnwgt/nwgt |
1280 | common/c_analysis/nwgt_analysis |
1281 | - parameter (max_weight=maxscales*maxscales+maxpdfs+1) |
1282 | - character*15 weights_info(max_weight) |
1283 | + character*50 weights_info(max_weight_shower) |
1284 | common/cwgtsinfo/weights_info |
1285 | character*8 cc(2) |
1286 | data cc/' ','vbfcuts '/ |
1287 | |
1288 | === modified file 'Template/NLO/MCatNLO/PYAnalyzer/mcatnlo_pyan_pp_leptons.f' |
1289 | --- Template/NLO/MCatNLO/PYAnalyzer/mcatnlo_pyan_pp_leptons.f 2014-02-12 10:28:36 +0000 |
1290 | +++ Template/NLO/MCatNLO/PYAnalyzer/mcatnlo_pyan_pp_leptons.f 2016-03-04 16:01:53 +0000 |
1291 | @@ -17,8 +17,7 @@ |
1292 | integer nwgt,max_weight,nwgt_analysis |
1293 | common/cnwgt/nwgt |
1294 | common/c_analysis/nwgt_analysis |
1295 | - parameter (max_weight=maxscales*maxscales+maxpdfs+1) |
1296 | - character*15 weights_info(max_weight) |
1297 | + character*50 weights_info(max_weight_shower) |
1298 | common/cwgtsinfo/weights_info |
1299 | integer nsingle,ncorr,nlepton,nplots,ncuts |
1300 | common/cplots/nsingle,ncorr,nlepton,nplots,ncuts |
1301 | |
1302 | === modified file 'Template/NLO/MCatNLO/PYAnalyzer/mcatnlo_pyan_pp_lplm.f' |
1303 | --- Template/NLO/MCatNLO/PYAnalyzer/mcatnlo_pyan_pp_lplm.f 2016-02-17 14:32:27 +0000 |
1304 | +++ Template/NLO/MCatNLO/PYAnalyzer/mcatnlo_pyan_pp_lplm.f 2016-03-04 16:01:53 +0000 |
1305 | @@ -22,8 +22,7 @@ |
1306 | integer nwgt,max_weight,nwgt_analysis |
1307 | common/cnwgt/nwgt |
1308 | common/c_analysis/nwgt_analysis |
1309 | - parameter (max_weight=maxscales*maxscales+maxpdfs+1) |
1310 | - character*15 weights_info(max_weight) |
1311 | + character*50 weights_info(max_weight_shower) |
1312 | common/cwgtsinfo/weights_info |
1313 | call inihist |
1314 | nwgt_analysis=nwgt |
1315 | |
1316 | === modified file 'Template/NLO/MCatNLO/PYAnalyzer/mcatnlo_pyan_pp_lvl.f' |
1317 | --- Template/NLO/MCatNLO/PYAnalyzer/mcatnlo_pyan_pp_lvl.f 2014-03-07 07:46:55 +0000 |
1318 | +++ Template/NLO/MCatNLO/PYAnalyzer/mcatnlo_pyan_pp_lvl.f 2016-03-04 16:01:53 +0000 |
1319 | @@ -25,8 +25,7 @@ |
1320 | integer nwgt,max_weight,nwgt_analysis |
1321 | common/cnwgt/nwgt |
1322 | common/c_analysis/nwgt_analysis |
1323 | - parameter (max_weight=maxscales*maxscales+maxpdfs+1) |
1324 | - character*15 weights_info(max_weight) |
1325 | + character*50 weights_info(max_weight_shower) |
1326 | common/cwgtsinfo/weights_info |
1327 | c |
1328 | call inihist |
1329 | |
1330 | === modified file 'Template/NLO/MCatNLO/PYAnalyzer/mcatnlo_pyan_pp_taptam.f' |
1331 | --- Template/NLO/MCatNLO/PYAnalyzer/mcatnlo_pyan_pp_taptam.f 2014-03-07 07:46:55 +0000 |
1332 | +++ Template/NLO/MCatNLO/PYAnalyzer/mcatnlo_pyan_pp_taptam.f 2016-03-04 16:01:53 +0000 |
1333 | @@ -20,8 +20,7 @@ |
1334 | integer nwgt,max_weight,nwgt_analysis |
1335 | common/cnwgt/nwgt |
1336 | common/c_analysis/nwgt_analysis |
1337 | - parameter (max_weight=maxscales*maxscales+maxpdfs+1) |
1338 | - character*15 weights_info(max_weight) |
1339 | + character*50 weights_info(max_weight_shower) |
1340 | common/cwgtsinfo/weights_info |
1341 | call inihist |
1342 | nwgt_analysis=nwgt |
1343 | |
1344 | === modified file 'Template/NLO/MCatNLO/PYAnalyzer/mcatnlo_pyan_pp_tj.f' |
1345 | --- Template/NLO/MCatNLO/PYAnalyzer/mcatnlo_pyan_pp_tj.f 2014-03-07 07:46:55 +0000 |
1346 | +++ Template/NLO/MCatNLO/PYAnalyzer/mcatnlo_pyan_pp_tj.f 2016-03-04 16:01:53 +0000 |
1347 | @@ -21,8 +21,7 @@ |
1348 | integer nwgt,max_weight,nwgt_analysis |
1349 | common/cnwgt/nwgt |
1350 | common/c_analysis/nwgt_analysis |
1351 | - parameter (max_weight=maxscales*maxscales+maxpdfs+1) |
1352 | - character*15 weights_info(max_weight) |
1353 | + character*50 weights_info(max_weight_shower) |
1354 | common/cwgtsinfo/weights_info |
1355 | call inihist |
1356 | nwgt_analysis=nwgt |
1357 | |
1358 | === modified file 'Template/NLO/MCatNLO/PYAnalyzer/mcatnlo_pyan_pp_ttx.f' |
1359 | --- Template/NLO/MCatNLO/PYAnalyzer/mcatnlo_pyan_pp_ttx.f 2014-03-07 07:46:55 +0000 |
1360 | +++ Template/NLO/MCatNLO/PYAnalyzer/mcatnlo_pyan_pp_ttx.f 2016-03-04 16:01:53 +0000 |
1361 | @@ -22,8 +22,7 @@ |
1362 | integer nwgt,max_weight,nwgt_analysis |
1363 | common/cnwgt/nwgt |
1364 | common/c_analysis/nwgt_analysis |
1365 | - parameter (max_weight=maxscales*maxscales+maxpdfs+1) |
1366 | - character*15 weights_info(max_weight) |
1367 | + character*50 weights_info(max_weight_shower) |
1368 | common/cwgtsinfo/weights_info |
1369 | c |
1370 | call inihist |
1371 | |
1372 | === modified file 'Template/NLO/MCatNLO/PYAnalyzer/mcatnlo_pyan_pp_ttx_v2.f' |
1373 | --- Template/NLO/MCatNLO/PYAnalyzer/mcatnlo_pyan_pp_ttx_v2.f 2014-03-07 07:46:55 +0000 |
1374 | +++ Template/NLO/MCatNLO/PYAnalyzer/mcatnlo_pyan_pp_ttx_v2.f 2016-03-04 16:01:53 +0000 |
1375 | @@ -22,8 +22,7 @@ |
1376 | integer nwgt,max_weight,nwgt_analysis |
1377 | common/cnwgt/nwgt |
1378 | common/c_analysis/nwgt_analysis |
1379 | - parameter (max_weight=maxscales*maxscales+maxpdfs+1) |
1380 | - character*15 weights_info(max_weight) |
1381 | + character*50 weights_info(max_weight_shower) |
1382 | common/cwgtsinfo/weights_info |
1383 | c |
1384 | call inihist |
1385 | |
1386 | === modified file 'Template/NLO/MCatNLO/PYAnalyzer/mcatnlo_pyan_rates.f' |
1387 | --- Template/NLO/MCatNLO/PYAnalyzer/mcatnlo_pyan_rates.f 2014-03-07 07:46:55 +0000 |
1388 | +++ Template/NLO/MCatNLO/PYAnalyzer/mcatnlo_pyan_rates.f 2016-03-04 16:01:53 +0000 |
1389 | @@ -19,8 +19,7 @@ |
1390 | integer nwgt,max_weight,nwgt_analysis |
1391 | common/cnwgt/nwgt |
1392 | common/c_analysis/nwgt_analysis |
1393 | - parameter (max_weight=maxscales*maxscales+maxpdfs+1) |
1394 | - character*15 weights_info(max_weight) |
1395 | + character*50 weights_info(max_weight_shower) |
1396 | common/cwgtsinfo/weights_info |
1397 | c |
1398 | call inihist |
1399 | |
1400 | === modified file 'Template/NLO/MCatNLO/PYAnalyzer/py6an_HwU_pp_V.f' |
1401 | --- Template/NLO/MCatNLO/PYAnalyzer/py6an_HwU_pp_V.f 2015-12-04 15:47:32 +0000 |
1402 | +++ Template/NLO/MCatNLO/PYAnalyzer/py6an_HwU_pp_V.f 2016-03-04 16:01:53 +0000 |
1403 | @@ -51,11 +51,7 @@ |
1404 | integer nwgt,max_weight,nwgt_analysis |
1405 | common/cnwgt/nwgt |
1406 | common/c_analysis/nwgt_analysis |
1407 | - integer maxRWGT |
1408 | - parameter (maxRWGT=100) |
1409 | - double precision wgtxsecRWGT(maxRWGT) |
1410 | - parameter (max_weight=maxscales*maxscales+maxpdfs+maxRWGT+1) |
1411 | - character*15 weights_info(max_weight) |
1412 | + character*50 weights_info(max_weight_shower) |
1413 | common/cwgtsinfo/weights_info |
1414 | c Initialize histograms |
1415 | call HwU_inithist(nwgt,weights_info) |
1416 | |
1417 | === modified file 'Template/NLO/MCatNLO/PYAnalyzer/py6an_HwU_pp_h.f' |
1418 | --- Template/NLO/MCatNLO/PYAnalyzer/py6an_HwU_pp_h.f 2015-12-04 15:47:32 +0000 |
1419 | +++ Template/NLO/MCatNLO/PYAnalyzer/py6an_HwU_pp_h.f 2016-03-04 16:01:53 +0000 |
1420 | @@ -48,11 +48,7 @@ |
1421 | integer nwgt,max_weight,nwgt_analysis |
1422 | common/cnwgt/nwgt |
1423 | common/c_analysis/nwgt_analysis |
1424 | - integer maxRWGT |
1425 | - parameter (maxRWGT=100) |
1426 | - double precision wgtxsecRWGT(maxRWGT) |
1427 | - parameter (max_weight=maxscales*maxscales+maxpdfs+maxRWGT+1) |
1428 | - character*15 weights_info(max_weight) |
1429 | + character*50 weights_info(max_weight_shower) |
1430 | common/cwgtsinfo/weights_info |
1431 | c |
1432 | c Initialize histograms |
1433 | |
1434 | === modified file 'Template/NLO/MCatNLO/PYAnalyzer/py6an_HwU_pp_hjj.f' |
1435 | --- Template/NLO/MCatNLO/PYAnalyzer/py6an_HwU_pp_hjj.f 2015-12-04 15:47:32 +0000 |
1436 | +++ Template/NLO/MCatNLO/PYAnalyzer/py6an_HwU_pp_hjj.f 2016-03-04 16:01:53 +0000 |
1437 | @@ -52,11 +52,7 @@ |
1438 | common /to_veto_hist/vetomin,vetomax,nbinveto |
1439 | common/cnwgt/nwgt |
1440 | common/c_analysis/nwgt_analysis |
1441 | - integer maxRWGT |
1442 | - parameter (maxRWGT=100) |
1443 | - double precision wgtxsecRWGT(maxRWGT) |
1444 | - parameter (max_weight=maxscales*maxscales+maxpdfs+maxRWGT+1) |
1445 | - character*15 weights_info(max_weight) |
1446 | + character*50 weights_info(max_weight_shower) |
1447 | common/cwgtsinfo/weights_info |
1448 | c |
1449 | c Initialize histograms |
1450 | |
1451 | === modified file 'Template/NLO/MCatNLO/PYAnalyzer/py6an_HwU_pp_leptons.f' |
1452 | --- Template/NLO/MCatNLO/PYAnalyzer/py6an_HwU_pp_leptons.f 2015-12-04 15:47:32 +0000 |
1453 | +++ Template/NLO/MCatNLO/PYAnalyzer/py6an_HwU_pp_leptons.f 2016-03-04 16:01:53 +0000 |
1454 | @@ -59,11 +59,7 @@ |
1455 | integer nwgt,max_weight,nwgt_analysis |
1456 | common/cnwgt/nwgt |
1457 | common/c_analysis/nwgt_analysis |
1458 | - integer maxRWGT |
1459 | - parameter (maxRWGT=100) |
1460 | - double precision wgtxsecRWGT(maxRWGT) |
1461 | - parameter (max_weight=maxscales*maxscales+maxpdfs+maxRWGT+1) |
1462 | - character*15 weights_info(max_weight) |
1463 | + character*50 weights_info(max_weight_shower) |
1464 | common/cwgtsinfo/weights_info |
1465 | c Initialize histograms |
1466 | call HwU_inithist(nwgt,weights_info) |
1467 | |
1468 | === modified file 'Template/NLO/MCatNLO/PYAnalyzer/py6an_HwU_pp_lplm.f' |
1469 | --- Template/NLO/MCatNLO/PYAnalyzer/py6an_HwU_pp_lplm.f 2016-02-17 14:32:27 +0000 |
1470 | +++ Template/NLO/MCatNLO/PYAnalyzer/py6an_HwU_pp_lplm.f 2016-03-04 16:01:53 +0000 |
1471 | @@ -48,11 +48,7 @@ |
1472 | integer nwgt,max_weight,nwgt_analysis |
1473 | common/cnwgt/nwgt |
1474 | common/c_analysis/nwgt_analysis |
1475 | - integer maxRWGT |
1476 | - parameter (maxRWGT=100) |
1477 | - double precision wgtxsecRWGT(maxRWGT) |
1478 | - parameter (max_weight=maxscales*maxscales+maxpdfs+maxRWGT+1) |
1479 | - character*15 weights_info(max_weight) |
1480 | + character*50 weights_info(max_weight_shower) |
1481 | common/cwgtsinfo/weights_info |
1482 | c Initialize histograms |
1483 | call HwU_inithist(nwgt,weights_info) |
1484 | |
1485 | === modified file 'Template/NLO/MCatNLO/PYAnalyzer/py6an_HwU_pp_lvl.f' |
1486 | --- Template/NLO/MCatNLO/PYAnalyzer/py6an_HwU_pp_lvl.f 2015-12-04 15:47:32 +0000 |
1487 | +++ Template/NLO/MCatNLO/PYAnalyzer/py6an_HwU_pp_lvl.f 2016-03-04 16:01:53 +0000 |
1488 | @@ -50,11 +50,7 @@ |
1489 | integer nwgt,max_weight,nwgt_analysis |
1490 | common/cnwgt/nwgt |
1491 | common/c_analysis/nwgt_analysis |
1492 | - integer maxRWGT |
1493 | - parameter (maxRWGT=100) |
1494 | - double precision wgtxsecRWGT(maxRWGT) |
1495 | - parameter (max_weight=maxscales*maxscales+maxpdfs+maxRWGT+1) |
1496 | - character*15 weights_info(max_weight) |
1497 | + character*50 weights_info(max_weight_shower) |
1498 | common/cwgtsinfo/weights_info |
1499 | c Initialize histograms |
1500 | call HwU_inithist(nwgt,weights_info) |
1501 | |
1502 | === modified file 'Template/NLO/MCatNLO/PYAnalyzer/py6an_HwU_pp_taptam.f' |
1503 | --- Template/NLO/MCatNLO/PYAnalyzer/py6an_HwU_pp_taptam.f 2015-12-04 15:47:32 +0000 |
1504 | +++ Template/NLO/MCatNLO/PYAnalyzer/py6an_HwU_pp_taptam.f 2016-03-04 16:01:53 +0000 |
1505 | @@ -46,11 +46,7 @@ |
1506 | integer nwgt,max_weight,nwgt_analysis |
1507 | common/cnwgt/nwgt |
1508 | common/c_analysis/nwgt_analysis |
1509 | - integer maxRWGT |
1510 | - parameter (maxRWGT=100) |
1511 | - double precision wgtxsecRWGT(maxRWGT) |
1512 | - parameter (max_weight=maxscales*maxscales+maxpdfs+maxRWGT+1) |
1513 | - character*15 weights_info(max_weight) |
1514 | + character*50 weights_info(max_weight_shower) |
1515 | common/cwgtsinfo/weights_info |
1516 | c |
1517 | c Initialize histograms |
1518 | |
1519 | === modified file 'Template/NLO/MCatNLO/PYAnalyzer/py6an_HwU_pp_tj.f' |
1520 | --- Template/NLO/MCatNLO/PYAnalyzer/py6an_HwU_pp_tj.f 2015-12-04 15:47:32 +0000 |
1521 | +++ Template/NLO/MCatNLO/PYAnalyzer/py6an_HwU_pp_tj.f 2016-03-04 16:01:53 +0000 |
1522 | @@ -48,11 +48,7 @@ |
1523 | integer nwgt,max_weight,nwgt_analysis |
1524 | common/cnwgt/nwgt |
1525 | common/c_analysis/nwgt_analysis |
1526 | - integer maxRWGT |
1527 | - parameter (maxRWGT=100) |
1528 | - double precision wgtxsecRWGT(maxRWGT) |
1529 | - parameter (max_weight=maxscales*maxscales+maxpdfs+maxRWGT+1) |
1530 | - character*15 weights_info(max_weight) |
1531 | + character*50 weights_info(max_weight_shower) |
1532 | common/cwgtsinfo/weights_info |
1533 | c |
1534 | c Initialize histograms |
1535 | |
1536 | === modified file 'Template/NLO/MCatNLO/PYAnalyzer/py6an_HwU_pp_ttx.f' |
1537 | --- Template/NLO/MCatNLO/PYAnalyzer/py6an_HwU_pp_ttx.f 2015-12-04 15:47:32 +0000 |
1538 | +++ Template/NLO/MCatNLO/PYAnalyzer/py6an_HwU_pp_ttx.f 2016-03-04 16:01:53 +0000 |
1539 | @@ -48,11 +48,7 @@ |
1540 | integer nwgt,max_weight,nwgt_analysis |
1541 | common/cnwgt/nwgt |
1542 | common/c_analysis/nwgt_analysis |
1543 | - integer maxRWGT |
1544 | - parameter (maxRWGT=100) |
1545 | - double precision wgtxsecRWGT(maxRWGT) |
1546 | - parameter (max_weight=maxscales*maxscales+maxpdfs+maxRWGT+1) |
1547 | - character*15 weights_info(max_weight) |
1548 | + character*50 weights_info(max_weight_shower) |
1549 | common/cwgtsinfo/weights_info |
1550 | c |
1551 | c Initialize histograms |
1552 | |
1553 | === modified file 'Template/NLO/MCatNLO/PYAnalyzer/py6an_HwU_pp_ttx_v2.f' |
1554 | --- Template/NLO/MCatNLO/PYAnalyzer/py6an_HwU_pp_ttx_v2.f 2015-12-04 15:47:32 +0000 |
1555 | +++ Template/NLO/MCatNLO/PYAnalyzer/py6an_HwU_pp_ttx_v2.f 2016-03-04 16:01:53 +0000 |
1556 | @@ -48,11 +48,7 @@ |
1557 | integer nwgt,max_weight,nwgt_analysis |
1558 | common/cnwgt/nwgt |
1559 | common/c_analysis/nwgt_analysis |
1560 | - integer maxRWGT |
1561 | - parameter (maxRWGT=100) |
1562 | - double precision wgtxsecRWGT(maxRWGT) |
1563 | - parameter (max_weight=maxscales*maxscales+maxpdfs+maxRWGT+1) |
1564 | - character*15 weights_info(max_weight) |
1565 | + character*50 weights_info(max_weight_shower) |
1566 | common/cwgtsinfo/weights_info |
1567 | c |
1568 | c Initialize histograms |
1569 | |
1570 | === modified file 'Template/NLO/MCatNLO/PYAnalyzer/py6an_HwU_rates.f' |
1571 | --- Template/NLO/MCatNLO/PYAnalyzer/py6an_HwU_rates.f 2015-12-04 15:47:32 +0000 |
1572 | +++ Template/NLO/MCatNLO/PYAnalyzer/py6an_HwU_rates.f 2016-03-04 16:01:53 +0000 |
1573 | @@ -42,11 +42,7 @@ |
1574 | integer nwgt,max_weight,nwgt_analysis |
1575 | common/cnwgt/nwgt |
1576 | common/c_analysis/nwgt_analysis |
1577 | - integer maxRWGT |
1578 | - parameter (maxRWGT=100) |
1579 | - double precision wgtxsecRWGT(maxRWGT) |
1580 | - parameter (max_weight=maxscales*maxscales+maxpdfs+maxRWGT+1) |
1581 | - character*15 weights_info(max_weight) |
1582 | + character*50 weights_info(max_weight_shower) |
1583 | common/cwgtsinfo/weights_info |
1584 | c Initialize histograms |
1585 | call HwU_inithist(nwgt,weights_info) |
1586 | |
1587 | === modified file 'Template/NLO/MCatNLO/include/LHEFRead.h' |
1588 | --- Template/NLO/MCatNLO/include/LHEFRead.h 2015-06-12 07:55:36 +0000 |
1589 | +++ Template/NLO/MCatNLO/include/LHEFRead.h 2016-03-04 16:01:53 +0000 |
1590 | @@ -16,75 +16,41 @@ |
1591 | LHEF::Reader reader; |
1592 | |
1593 | |
1594 | - void lhef_read_wgtsinfo_(int &cwgtinfo_nn, char (cwgtinfo_weights_info[350][15])) { |
1595 | + void lhef_read_wgtsinfo_(int &cwgtinfo_nn, char (cwgtinfo_weights_info[1024][50])) { |
1596 | |
1597 | // Read header of event file |
1598 | std::stringstream hss; |
1599 | - std::string hs,hsvec[5]; |
1600 | - cwgtinfo_nn=0; |
1601 | - |
1602 | + std::string hs; |
1603 | + sprintf(cwgtinfo_weights_info[0], "%50s","central value"); |
1604 | + cwgtinfo_nn=1; |
1605 | while (true){ |
1606 | hss << reader.headerBlock; |
1607 | std::getline(hss,hs,'\n'); |
1608 | if (hs.find("</header>") != std::string::npos) break; |
1609 | - |
1610 | - // Read the scale block |
1611 | - if (hs.find("<weightgroup type='scale_variation'") != std::string::npos) { |
1612 | - while (true) { |
1613 | - std::getline(hss,hs,'\n'); |
1614 | - if (hs.find("</weightgroup>") != std::string::npos) break; |
1615 | - //find the values of muR and muF |
1616 | - std::string xmuR = hs.substr(hs.find("muR")+4,hs.length()); |
1617 | - xmuR = xmuR.substr(0,xmuR.find("muF")-1); |
1618 | - std::string xmuF = hs.substr(hs.find("muF")+4,hs.length()); |
1619 | - xmuF = xmuF.substr(0,xmuF.find("</w")-1); |
1620 | - double muR = atof(xmuR.c_str()); |
1621 | - double muF = atof(xmuF.c_str()); |
1622 | - //store the plot label |
1623 | - sprintf(cwgtinfo_weights_info[cwgtinfo_nn], "muR=%2.1f muF=%2.1f", muR, muF); |
1624 | - ++cwgtinfo_nn; |
1625 | - } |
1626 | - } |
1627 | - |
1628 | - // Read the PDF block |
1629 | - if (hs.find("<weightgroup type='PDF_variation'") != std::string::npos) { |
1630 | - while (true) { |
1631 | - std::getline(hss,hs,'\n'); |
1632 | - if (hs.find("</weightgroup>") != std::string::npos) break; |
1633 | - //find the PDF set used |
1634 | - std::string PDF = hs.substr(hs.find("pdfset")+8,hs.length()); |
1635 | - PDF = PDF.substr(0,PDF.find("</w")-1); |
1636 | - int iPDF = atoi(PDF.c_str()); |
1637 | - //store the plot label |
1638 | - sprintf(cwgtinfo_weights_info[cwgtinfo_nn], "PDF=%8d ", iPDF); |
1639 | - ++cwgtinfo_nn; |
1640 | - } |
1641 | - } |
1642 | - |
1643 | - // Read the mg_reweighting block |
1644 | - if (hs.find("<weightgroup type='mg_reweighting'") != std::string::npos) { |
1645 | - while (true) { |
1646 | - std::getline(hss,hs,'\n'); |
1647 | - if (hs.find("</weightgroup>") != std::string::npos) break; |
1648 | + // Read the wgt information |
1649 | + if (hs.find("<initrwgt>") != std::string::npos) { |
1650 | + while (true) { |
1651 | + std::getline(hss,hs,'\n'); |
1652 | + if (hs.find("</initrwgt>") != std::string::npos) break; |
1653 | + if (hs.find("<weightgroup") != std::string::npos) continue; |
1654 | + if (hs.find("</weightgroup>") != std::string::npos) continue; |
1655 | if (hs.find("<weight id") != std::string::npos) { |
1656 | - std::string sRWGT = hs.substr(hs.find("weight id")+11,hs.length()); |
1657 | - sRWGT = sRWGT.substr(0,sRWGT.find("'>")); |
1658 | - //store the reweight label |
1659 | - sprintf(cwgtinfo_weights_info[cwgtinfo_nn], "%15s", sRWGT.c_str()); |
1660 | + std::string sRWGT = hs.substr(hs.find("'>")+2,hs.find("</w")-3); |
1661 | + sRWGT = sRWGT.substr(0,sRWGT.find("<")); |
1662 | + sprintf(cwgtinfo_weights_info[cwgtinfo_nn],"%50s",sRWGT.c_str()); |
1663 | ++cwgtinfo_nn; |
1664 | } |
1665 | } |
1666 | } |
1667 | - |
1668 | + |
1669 | } |
1670 | } |
1671 | |
1672 | |
1673 | - void lhef_read_wgts_(double (cwgt_ww[350])) { |
1674 | + void lhef_read_wgts_(double (cwgt_ww[1024])) { |
1675 | |
1676 | // Read events |
1677 | if (reader.readEvent()) { |
1678 | - double wgtxsecmu[4][4],wgtxsecPDF[200]; |
1679 | std::string svec[16],isvec[4],refstr; |
1680 | std::stringstream ss; |
1681 | int i,j; |
1682 | @@ -129,7 +95,6 @@ |
1683 | ++iww; |
1684 | } |
1685 | } |
1686 | - iww-=1; |
1687 | } |
1688 | } |
1689 | } |
1690 | |
1691 | === modified file 'Template/NLO/MCatNLO/srcHerwig/madfks_hwlhin.f' |
1692 | --- Template/NLO/MCatNLO/srcHerwig/madfks_hwlhin.f 2015-06-12 07:34:40 +0000 |
1693 | +++ Template/NLO/MCatNLO/srcHerwig/madfks_hwlhin.f 2016-03-04 16:01:53 +0000 |
1694 | @@ -35,15 +35,11 @@ |
1695 | DOUBLE PRECISION EVWGT_LH |
1696 | COMMON/CEVWGT_LH/EVWGT_LH |
1697 | include 'reweight0.inc' |
1698 | - integer iww,max_weight |
1699 | - integer maxRWGT |
1700 | - parameter (maxRWGT=100) |
1701 | - double precision wgtxsecRWGT(maxRWGT) |
1702 | - parameter (max_weight=maxscales*maxscales+maxpdfs+maxRWGT+1) |
1703 | - double precision ww(max_weight) |
1704 | + integer iww |
1705 | + double precision ww(max_weight_shower) |
1706 | common/cww/ww |
1707 | - integer numRWGTS |
1708 | - common/cnrwgts/numRWGTS |
1709 | + integer nwgt |
1710 | + common/cnwgt/nwgt |
1711 | C |
1712 | IF (IERROR.NE.0) RETURN |
1713 | c |
1714 | @@ -78,104 +74,15 @@ |
1715 | # scale1_lhe,scale2_lhe, |
1716 | # jwgtinfo,mexternal,iwgtnumpartn, |
1717 | # wgtcentral,wgtmumin,wgtmumax,wgtpdfmin,wgtpdfmax |
1718 | - if(jwgtinfo.ge.1.and.jwgtinfo.le.4)then |
1719 | - read(iunit,'(a)')string |
1720 | - read(iunit,401)wgtref,wgtqes2(2) |
1721 | - read(iunit,402)wgtxbj(1,1),wgtxbj(2,1), |
1722 | - # wgtxbj(1,2),wgtxbj(2,2), |
1723 | - # wgtxbj(1,3),wgtxbj(2,3), |
1724 | - # wgtxbj(1,4),wgtxbj(2,4) |
1725 | - if(jwgtinfo.eq.1)then |
1726 | - read(iunit,403)wgtmuR2(1),wgtmuF12(1),wgtmuF22(1), |
1727 | - # wgtmuR2(2),wgtmuF12(2),wgtmuF22(2) |
1728 | - elseif(jwgtinfo.eq.2)then |
1729 | - ii=iSorH_lhe+1 |
1730 | - if(ii.eq.3)ii=1 |
1731 | - read(iunit,404)wgtmuR2(ii),wgtmuF12(ii),wgtmuF22(ii) |
1732 | - do i=1,mexternal |
1733 | - read(iunit,405)(wgtkinE(j,i,iSorH_lhe),j=0,3) |
1734 | - enddo |
1735 | - elseif(jwgtinfo.eq.3 .or. jwgtinfo.eq.4)then |
1736 | - do i=1,mexternal |
1737 | - read(iunit,405)(wgtkinE(j,i,1),j=0,3) |
1738 | - enddo |
1739 | - do i=1,mexternal |
1740 | - read(iunit,405)(wgtkinE(j,i,2),j=0,3) |
1741 | - enddo |
1742 | - endif |
1743 | - read(iunit,441)wgtwreal(1),wgtwreal(2), |
1744 | - # wgtwreal(3),wgtwreal(4) |
1745 | - read(iunit,441)wgtwdeg(3),wgtwdeg(4), |
1746 | - # wgtwdegmuf(3),wgtwdegmuf(4) |
1747 | - read(iunit,405)wgtwborn(2),wgtwns(2), |
1748 | - # wgtwnsmuf(2),wgtwnsmur(2) |
1749 | - do i=1,iwgtnumpartn |
1750 | - read(iunit,442)wgtwmcxsecE(i), |
1751 | - # wgtmcxbjE(1,i),wgtmcxbjE(2,i) |
1752 | - enddo |
1753 | - if(jwgtinfo.eq.4) read(iunit,'(1x,e14.8)') wgtbpower |
1754 | - read(iunit,'(a)')string |
1755 | - elseif(jwgtinfo.eq.8)then |
1756 | - read(iunit,'(a)')string |
1757 | - read(iunit,406)wgtref,wgtxsecmu(1,1),numscales,numPDFpairs |
1758 | - do i=1,numscales |
1759 | - read(iunit,404)(wgtxsecmu(i,j),j=1,numscales) |
1760 | - enddo |
1761 | - do i=1,numPDFpairs |
1762 | - nps=2*i-1 |
1763 | - nng=2*i |
1764 | - read(iunit,404)wgtxsecPDF(nps),wgtxsecPDF(nng) |
1765 | - enddo |
1766 | - read(iunit,'(a)')string |
1767 | - elseif(jwgtinfo.eq.9)then |
1768 | - if (numscales.eq.0 .and. numPDFpairs.eq.0) then |
1769 | - write (*,*) 'event file not correct format' |
1770 | - write(*,*)'FATAL ERROR #3 IN UPEVNT' |
1771 | - stop |
1772 | - endif |
1773 | - read(iunit,'(a)')string |
1774 | - wgtref=XWGTUP/MQQ |
1775 | - do i=1,numscales |
1776 | - do j=1,numscales |
1777 | - call read_rwgt_line(iunit,idwgt,wgtxsecmu(i,j)) |
1778 | - if (numscales.ne.3) then |
1779 | - write (*,*) 'ERROR #1 in UPEVNT:',numscales |
1780 | - stop |
1781 | - endif |
1782 | - if(idwgt.eq.1001.and.(i.ne.1.or.j.ne.1).or. |
1783 | - & idwgt.eq.1002.and.(i.ne.1.or.j.ne.2).or. |
1784 | - & idwgt.eq.1003.and.(i.ne.1.or.j.ne.3).or. |
1785 | - & idwgt.eq.1004.and.(i.ne.2.or.j.ne.1).or. |
1786 | - & idwgt.eq.1005.and.(i.ne.2.or.j.ne.2).or. |
1787 | - & idwgt.eq.1006.and.(i.ne.2.or.j.ne.3).or. |
1788 | - & idwgt.eq.1007.and.(i.ne.3.or.j.ne.1).or. |
1789 | - & idwgt.eq.1008.and.(i.ne.3.or.j.ne.2).or. |
1790 | - & idwgt.eq.1009.and.(i.ne.3.or.j.ne.3))then |
1791 | - write(*,*)'incorrect event wgt id',idwgt,i,j |
1792 | - stop |
1793 | - endif |
1794 | -c 1 = central, |
1795 | -c 2 = (muR0,muF0), 3 = (muR0,muFup), 4 = (muR0,muFdown) |
1796 | -c 5 = (muRup,muF0), 6 = (muRup,muFup), 7 = (muRup,muFdown) |
1797 | -c 8 = (muRdown,muF0), 9 = (muRdown,muFup), 10 = (muRdown,muFdown) |
1798 | - iww=iww+1 |
1799 | - ww(iww)=wgtxsecmu(i,j) |
1800 | + if(jwgtinfo.eq.9)then |
1801 | + if (nwgt.gt.1) then |
1802 | + read(iunit,'(a)')string ! <rwgt> |
1803 | + wgtref=XWGTUP/MQQ |
1804 | + do iww=2,nwgt ! start at 2, because 'central value' is not part of the extra weights |
1805 | + call read_rwgt_line_wgt(iunit,ww(iww)) |
1806 | enddo |
1807 | - enddo |
1808 | - do i=1,2*numPDFpairs |
1809 | - call read_rwgt_line(iunit,idwgt,wgtxsecPDF(i)) |
1810 | - iww=iww+1 |
1811 | - ww(iww)=wgtxsecPDF(i) |
1812 | - enddo |
1813 | - do i=1,numRWGTS |
1814 | - call read_rwgt_line_RWGT(iunit,cidwgt,wgtxsecRWGT(i)) |
1815 | - iww=iww+1 |
1816 | - ww(iww)=wgtxsecRWGT(i) |
1817 | - enddo |
1818 | - if (numscales.eq.0) then |
1819 | - wgtxsecmu(1,1)=wgtref |
1820 | + read(iunit,'(a)')string ! </rwgt> |
1821 | endif |
1822 | - read(iunit,'(a)')string |
1823 | else |
1824 | do while(index(string,'</event>').eq.0) |
1825 | read(iunit,'(a)')string |
1826 | @@ -233,80 +140,48 @@ |
1827 | & ICOLUP(2,MAXNUP),PUP(5,MAXNUP),VTIMUP(MAXNUP), |
1828 | & SPINUP(MAXNUP) |
1829 | c Hard event file (to be entered in Herwig driver) |
1830 | + integer i |
1831 | CHARACTER*50 QQIN |
1832 | COMMON/VVJIN/QQIN |
1833 | CHARACTER*80 STRING |
1834 | include 'reweight0.inc' |
1835 | - integer nwgt,max_weight |
1836 | + integer nwgt |
1837 | common/cnwgt/nwgt |
1838 | - parameter (max_weight=maxscales*maxscales+maxpdfs+1) |
1839 | - character*15 weights_info(max_weight) |
1840 | + character*50 weights_info(max_weight_shower) |
1841 | common/cwgtsinfo/weights_info |
1842 | - double precision xmuR,xmuF |
1843 | - integer iPDF,i,numRWGTS |
1844 | - common/cnrwgts/numRWGTS |
1845 | - character*20 sRWGT |
1846 | -C |
1847 | - numscales=0 |
1848 | - numPDFpairs=0 |
1849 | - numRWGTS=0 |
1850 | + |
1851 | nwgt=1 |
1852 | - weights_info(nwgt)="central value " |
1853 | + weights_info(nwgt)="central value" |
1854 | IF (IERROR.NE.0) RETURN |
1855 | C--SET UP INPUT FILES |
1856 | OPEN(UNIT=61,FILE=QQIN,STATUS='UNKNOWN') |
1857 | -C--Read (non compulsory) headers here if need be |
1858 | - DO WHILE(.TRUE.) |
1859 | +C--Read (non compulsory) headers here if need be. Look for extra |
1860 | +C--weights. |
1861 | + do |
1862 | READ(61,'(a)')STRING |
1863 | -c --> see if we have the new format for the weights |
1864 | - IF ( INDEX(STRING,"<weightgroup type='scale_variation'").ne.0 |
1865 | - $ .and.STRING(1:1).ne.'#') then |
1866 | - DO WHILE (.TRUE.) |
1867 | - READ(61,'(a)') STRING |
1868 | - if (INDEX(STRING,"</weightgroup>").ne.0 .and. |
1869 | - $ STRING(1:1).ne.'#') exit |
1870 | - numscales=numscales+1 |
1871 | - read(string(index(string,"muR")+4:index(string,"muF")-1),*)xmuR |
1872 | - read(string(index(string,"muF")+4:index(string,"</w")-1),*)xmuF |
1873 | -c 1 = central, |
1874 | -c 2 = (muR0,muF0), 3 = (muR0,muFup), 4 = (muR0,muFdown) |
1875 | -c 5 = (muRup,muF0), 6 = (muRup,muFup), 7 = (muRup,muFdown) |
1876 | -c 8 = (muRdown,muF0), 9 = (muRdown,muFup), 10 = (muRdown,muFdown) |
1877 | - write(weights_info(numscales+1), 111)"muR=",xmuR,"muF=",xmuF |
1878 | - ENDDO |
1879 | - nwgt=nwgt+numscales |
1880 | - numscales=nint(sqrt(dble(numscales))) |
1881 | - if (numscales.ne.3) then |
1882 | - write (*,*) 'ERROR #1 in UPINIT:',numscales |
1883 | - stop |
1884 | - endif |
1885 | - ELSEIF( INDEX(STRING,"<weightgroup type='PDF_variation'").ne.0 |
1886 | - $ .and.STRING(1:1).ne.'#') then |
1887 | - DO WHILE (.TRUE.) |
1888 | - READ(61,'(a)') STRING |
1889 | - if (INDEX(STRING,"</weightgroup>").ne.0 .and. |
1890 | - $ STRING(1:1).ne.'#') exit |
1891 | - numPDFpairs=numPDFpairs+1 |
1892 | - read(string(index(string,"pdf")+7:index(string,"</w")-1),*)iPDF |
1893 | - write(weights_info(numscales**2+numPDFpairs+1),112) |
1894 | - & 'PDF=',iPDF,' ' |
1895 | - ENDDO |
1896 | - nwgt=nwgt+numPDFpairs |
1897 | - numPDFpairs=numPDFpairs/2 |
1898 | - ELSEIF( INDEX(STRING,"<weightgroup type='mg_reweighting'").ne.0 |
1899 | - $ .and.STRING(1:1).ne.'#') then |
1900 | - DO WHILE (.TRUE.) |
1901 | - READ(61,'(a)') STRING |
1902 | - if (INDEX(STRING,"<weight id").ne.0 .and. |
1903 | - $ STRING(1:1).ne.'#')then |
1904 | - numRWGTS=numRWGTS+1 |
1905 | - read(string(index(string,"weight id")+11:index(string,"'>")-1),*)sRWGT |
1906 | - write(weights_info(numscales**2+2*numPDFpairs+numRWGTS+1),113)sRWGT |
1907 | + if (index(string,'<initrwgt>').ne.0) then |
1908 | +c Found extra weight labels: |
1909 | + do |
1910 | + READ(61,'(a)')STRING |
1911 | +c exit when end of weight information is found |
1912 | + IF ( INDEX(STRING,'</initrwgt>').ne.0 .and. |
1913 | + & STRING(1:1).ne.'#' ) exit |
1914 | +c skip comments and weightgroup lines. We just need to copy this |
1915 | +c information |
1916 | + if ( index(string,"<weightgroup").ne.0 .or. |
1917 | + & index(string,"</weightgroup>").ne.0 .or. |
1918 | + & string(1:1).eq.'#') cycle |
1919 | + if (INDEX(STRING,"<weight id").ne.0)then |
1920 | + nwgt=nwgt+1 |
1921 | + read(string(index(string,"'>")+2: index(string |
1922 | + $ ,"</weight>")-1),'(a)') weights_info(nwgt) |
1923 | + if (nwgt.gt.max_weight_shower) then |
1924 | + write (*,*) 'Too many weights in event file. '/ |
1925 | + $ /'Increase max_weight_shower' |
1926 | + stop |
1927 | + endif |
1928 | endif |
1929 | - if (INDEX(STRING,"</weightgroup>").ne.0 .and. |
1930 | - $ STRING(1:1).ne.'#') exit |
1931 | - ENDDO |
1932 | - nwgt=nwgt+numRWGTS |
1933 | + enddo |
1934 | ELSEIF ( INDEX(STRING,'</header>').ne.0 .and. |
1935 | & STRING(1:1).ne.'#' ) then |
1936 | EXIT |
1937 | @@ -396,43 +271,18 @@ |
1938 | END |
1939 | |
1940 | |
1941 | - subroutine read_rwgt_line(unit,id,wgt) |
1942 | -c read a line in the <rwgt> tag. The syntax should be |
1943 | -c <wgt id='1001'> 0.1234567e+01 </wgt> |
1944 | -c The id should be exactly 4 digits long. |
1945 | - implicit none |
1946 | - integer unit,id,wgt_start,id_start |
1947 | - double precision wgt |
1948 | - character*100 buff |
1949 | - read (unit,'(a)') buff |
1950 | -c Use char() to make sure that the non-standard characters are compiler |
1951 | -c independent (char(62)=">", char(61)="=", char(39)="'") |
1952 | - wgt_start=index(buff,CHAR(39)//CHAR(62))+2 |
1953 | - id_start=index(buff,'id'//CHAR(61)//CHAR(39))+4 |
1954 | - read (buff(id_start:100),'(i4)') id |
1955 | - read (buff(wgt_start:100),*) wgt |
1956 | - return |
1957 | - end |
1958 | - |
1959 | - |
1960 | - subroutine read_rwgt_line_RWGT(unit,cid,wgt) |
1961 | -c read a line in the <rwgt> tag. The syntax should be |
1962 | -c <wgt id='1001'> 0.1234567e+01 </wgt> |
1963 | -c The id should be exactly 4 digits long. |
1964 | - implicit none |
1965 | - integer unit,wgt_start,id_start,id_end |
1966 | - double precision wgt |
1967 | - character*100 buff |
1968 | - character*20 cid |
1969 | - read (unit,'(a)') buff |
1970 | -c Use char() to make sure that the non-standard characters are compiler |
1971 | -c independent (char(62)=">", char(61)="=", char(39)="'") |
1972 | - wgt_start=index(buff,CHAR(39)//CHAR(62))+2 |
1973 | - id_start=index(buff,'id'//CHAR(61)//CHAR(39))+4 |
1974 | - id_end=wgt_start-3 |
1975 | - |
1976 | - read (buff(id_start:id_end),*) cid |
1977 | - read (buff(wgt_start:100),*) wgt |
1978 | - |
1979 | + subroutine read_rwgt_line_wgt(unit,wgt) |
1980 | +c read a line in the <rwgt> tag. The syntax should be |
1981 | +c <wgt id='1001'> 0.1234567e+01 </wgt> |
1982 | +c The id should be exactly 4 digits long. |
1983 | + implicit none |
1984 | + integer unit,wgt_start |
1985 | + double precision wgt |
1986 | + character*100 buff |
1987 | + read (unit,'(a)') buff |
1988 | +c Use char() to make sure that the non-standard characters are compiler |
1989 | +c independent (char(62)=">", char(61)="=", char(39)="'") |
1990 | + wgt_start=index(buff,CHAR(39)//CHAR(62))+2 |
1991 | + read (buff(wgt_start:100),*) wgt |
1992 | return |
1993 | end |
1994 | |
1995 | === modified file 'Template/NLO/MCatNLO/srcPythia/madfks_pylhin.f' |
1996 | --- Template/NLO/MCatNLO/srcPythia/madfks_pylhin.f 2015-06-12 07:34:40 +0000 |
1997 | +++ Template/NLO/MCatNLO/srcPythia/madfks_pylhin.f 2016-03-04 16:01:53 +0000 |
1998 | @@ -34,15 +34,11 @@ |
1999 | DOUBLE PRECISION EVWGT_LH |
2000 | COMMON/CEVWGT_LH/EVWGT_LH |
2001 | include 'reweight0.inc' |
2002 | - integer iww,max_weight |
2003 | - integer maxRWGT |
2004 | - parameter (maxRWGT=100) |
2005 | - double precision wgtxsecRWGT(maxRWGT) |
2006 | - parameter (max_weight=maxscales*maxscales+maxpdfs+maxRWGT+1) |
2007 | - double precision ww(max_weight) |
2008 | + integer iww |
2009 | + double precision ww(max_weight_shower) |
2010 | common/cww/ww |
2011 | - integer numRWGTS |
2012 | - common/cnrwgts/numRWGTS |
2013 | + integer nwgt |
2014 | + common/cnwgt/nwgt |
2015 | C |
2016 | COMMON/PYPARS/MSTP(200),PARP(200),MSTI(200),PARI(200) |
2017 | DOUBLE PRECISION EVWEIGHT |
2018 | @@ -81,104 +77,15 @@ |
2019 | # scale1_lhe,scale2_lhe, |
2020 | # jwgtinfo,mexternal,iwgtnumpartn, |
2021 | # wgtcentral,wgtmumin,wgtmumax,wgtpdfmin,wgtpdfmax |
2022 | - if(jwgtinfo.ge.1.and.jwgtinfo.le.4)then |
2023 | - read(iunit,'(a)')string |
2024 | - read(iunit,401)wgtref,wgtqes2(2) |
2025 | - read(iunit,402)wgtxbj(1,1),wgtxbj(2,1), |
2026 | - # wgtxbj(1,2),wgtxbj(2,2), |
2027 | - # wgtxbj(1,3),wgtxbj(2,3), |
2028 | - # wgtxbj(1,4),wgtxbj(2,4) |
2029 | - if(jwgtinfo.eq.1)then |
2030 | - read(iunit,403)wgtmuR2(1),wgtmuF12(1),wgtmuF22(1), |
2031 | - # wgtmuR2(2),wgtmuF12(2),wgtmuF22(2) |
2032 | - elseif(jwgtinfo.eq.2)then |
2033 | - ii=iSorH_lhe+1 |
2034 | - if(ii.eq.3)ii=1 |
2035 | - read(iunit,404)wgtmuR2(ii),wgtmuF12(ii),wgtmuF22(ii) |
2036 | - do i=1,mexternal |
2037 | - read(iunit,405)(wgtkinE(j,i,iSorH_lhe),j=0,3) |
2038 | - enddo |
2039 | - elseif(jwgtinfo.eq.3 .or. jwgtinfo.eq.4)then |
2040 | - do i=1,mexternal |
2041 | - read(iunit,405)(wgtkinE(j,i,1),j=0,3) |
2042 | - enddo |
2043 | - do i=1,mexternal |
2044 | - read(iunit,405)(wgtkinE(j,i,2),j=0,3) |
2045 | - enddo |
2046 | - endif |
2047 | - read(iunit,441)wgtwreal(1),wgtwreal(2), |
2048 | - # wgtwreal(3),wgtwreal(4) |
2049 | - read(iunit,441)wgtwdeg(3),wgtwdeg(4), |
2050 | - # wgtwdegmuf(3),wgtwdegmuf(4) |
2051 | - read(iunit,405)wgtwborn(2),wgtwns(2), |
2052 | - # wgtwnsmuf(2),wgtwnsmur(2) |
2053 | - do i=1,iwgtnumpartn |
2054 | - read(iunit,442)wgtwmcxsecE(i), |
2055 | - # wgtmcxbjE(1,i),wgtmcxbjE(2,i) |
2056 | - enddo |
2057 | - if(jwgtinfo.eq.4) read(iunit,'(1x,e14.8)') wgtbpower |
2058 | - read(iunit,'(a)')string |
2059 | - elseif(jwgtinfo.eq.8)then |
2060 | - read(iunit,'(a)')string |
2061 | - read(iunit,406)wgtref,wgtxsecmu(1,1),numscales,numPDFpairs |
2062 | - do i=1,numscales |
2063 | - read(iunit,404)(wgtxsecmu(i,j),j=1,numscales) |
2064 | - enddo |
2065 | - do i=1,numPDFpairs |
2066 | - nps=2*i-1 |
2067 | - nng=2*i |
2068 | - read(iunit,404)wgtxsecPDF(nps),wgtxsecPDF(nng) |
2069 | - enddo |
2070 | - read(iunit,'(a)')string |
2071 | - elseif(jwgtinfo.eq.9)then |
2072 | - if (numscales.eq.0 .and. numPDFpairs.eq.0) then |
2073 | - write (*,*) 'event file not correct format' |
2074 | - write(*,*)'FATAL ERROR #3 IN UPEVNT' |
2075 | - stop |
2076 | - endif |
2077 | - read(iunit,'(a)')string |
2078 | - wgtref=XWGTUP/MQQ |
2079 | - do i=1,numscales |
2080 | - do j=1,numscales |
2081 | - call read_rwgt_line(iunit,idwgt,wgtxsecmu(i,j)) |
2082 | - if (numscales.ne.3) then |
2083 | - write (*,*) 'ERROR #1 in UPEVNT:',numscales |
2084 | - stop |
2085 | - endif |
2086 | - if(idwgt.eq.1001.and.(i.ne.1.or.j.ne.1).or. |
2087 | - & idwgt.eq.1002.and.(i.ne.1.or.j.ne.2).or. |
2088 | - & idwgt.eq.1003.and.(i.ne.1.or.j.ne.3).or. |
2089 | - & idwgt.eq.1004.and.(i.ne.2.or.j.ne.1).or. |
2090 | - & idwgt.eq.1005.and.(i.ne.2.or.j.ne.2).or. |
2091 | - & idwgt.eq.1006.and.(i.ne.2.or.j.ne.3).or. |
2092 | - & idwgt.eq.1007.and.(i.ne.3.or.j.ne.1).or. |
2093 | - & idwgt.eq.1008.and.(i.ne.3.or.j.ne.2).or. |
2094 | - & idwgt.eq.1009.and.(i.ne.3.or.j.ne.3))then |
2095 | - write(*,*)'incorrect event wgt id',idwgt,i,j |
2096 | - stop |
2097 | - endif |
2098 | -c 1 = central, |
2099 | -c 2 = (muR0,muF0), 3 = (muR0,muFup), 4 = (muR0,muFdown) |
2100 | -c 5 = (muRup,muF0), 6 = (muRup,muFup), 7 = (muRup,muFdown) |
2101 | -c 8 = (muRdown,muF0), 9 = (muRdown,muFup), 10 = (muRdown,muFdown) |
2102 | - iww=iww+1 |
2103 | - ww(iww)=wgtxsecmu(i,j) |
2104 | - enddo |
2105 | - enddo |
2106 | - do i=1,2*numPDFpairs |
2107 | - call read_rwgt_line(iunit,idwgt,wgtxsecPDF(i)) |
2108 | - iww=iww+1 |
2109 | - ww(iww)=wgtxsecPDF(i) |
2110 | - enddo |
2111 | - do i=1,numRWGTS |
2112 | - call read_rwgt_line_RWGT(iunit,cidwgt,wgtxsecRWGT(i)) |
2113 | - iww=iww+1 |
2114 | - ww(iww)=wgtxsecRWGT(i) |
2115 | - enddo |
2116 | - if (numscales.eq.0) then |
2117 | - wgtxsecmu(1,1)=wgtref |
2118 | - endif |
2119 | - read(iunit,'(a)')string |
2120 | + if(jwgtinfo.eq.9)then |
2121 | + if (nwgt.gt.1) then |
2122 | + read(iunit,'(a)')string ! <rwgt> |
2123 | + wgtref=XWGTUP/MQQ |
2124 | + do iww=2,nwgt ! start at 2, because 'central value' is not part of the extra weights |
2125 | + call read_rwgt_line_wgt(iunit,ww(iww)) |
2126 | + enddo |
2127 | + read(iunit,'(a)')string ! </rwgt> |
2128 | + endif |
2129 | else |
2130 | do while(index(string,'</event>').eq.0) |
2131 | read(iunit,'(a)')string |
2132 | @@ -235,20 +142,16 @@ |
2133 | & ICOLUP(2,MAXNUP),PUP(5,MAXNUP),VTIMUP(MAXNUP), |
2134 | & SPINUP(MAXNUP) |
2135 | c Hard event file (to be entered in Herwig driver) |
2136 | + integer i |
2137 | CHARACTER*50 QQIN |
2138 | COMMON/VVJIN/QQIN |
2139 | CHARACTER*80 STRING |
2140 | common/pypars/mstp(200),parp(200),msti(200),pari(200) |
2141 | include 'reweight0.inc' |
2142 | - integer nwgt,max_weight |
2143 | + integer nwgt |
2144 | common/cnwgt/nwgt |
2145 | - parameter (max_weight=maxscales*maxscales+maxpdfs+1) |
2146 | - character*15 weights_info(max_weight) |
2147 | + character*50 weights_info(max_weight_shower) |
2148 | common/cwgtsinfo/weights_info |
2149 | - double precision xmuR,xmuF |
2150 | - integer iPDF,i,numRWGTS |
2151 | - common/cnrwgts/numRWGTS |
2152 | - character*20 sRWGT |
2153 | C |
2154 | numscales=0 |
2155 | numPDFpairs=0 |
2156 | @@ -257,58 +160,33 @@ |
2157 | weights_info(nwgt)="central value " |
2158 | C--SET UP INPUT FILES |
2159 | OPEN(UNIT=61,FILE=QQIN,STATUS='UNKNOWN') |
2160 | -C--Read (non compulsory) headers here if need be |
2161 | - DO WHILE(.TRUE.) |
2162 | +C--Read (non compulsory) headers here if need be. Look for extra |
2163 | +C--weights. |
2164 | + do |
2165 | READ(61,'(a)')STRING |
2166 | -c --> see if we have the new format for the weights |
2167 | - IF ( INDEX(STRING,"<weightgroup type='scale_variation'").ne.0 |
2168 | - $ .and.STRING(1:1).ne.'#') then |
2169 | - DO WHILE (.TRUE.) |
2170 | - READ(61,'(a)') STRING |
2171 | - if (INDEX(STRING,"</weightgroup>").ne.0 .and. |
2172 | - $ STRING(1:1).ne.'#') exit |
2173 | - numscales=numscales+1 |
2174 | - read(string(index(string,"muR")+4:index(string,"muF")-1),*)xmuR |
2175 | - read(string(index(string,"muF")+4:index(string,"</w")-1),*)xmuF |
2176 | -c 1 = central, |
2177 | -c 2 = (muR0,muF0), 3 = (muR0,muFup), 4 = (muR0,muFdown) |
2178 | -c 5 = (muRup,muF0), 6 = (muRup,muFup), 7 = (muRup,muFdown) |
2179 | -c 8 = (muRdown,muF0), 9 = (muRdown,muFup), 10 = (muRdown,muFdown) |
2180 | - write(weights_info(numscales+1), 111)"muR=",xmuR,"muF=",xmuF |
2181 | - ENDDO |
2182 | - nwgt=nwgt+numscales |
2183 | - numscales=nint(sqrt(dble(numscales))) |
2184 | - if (numscales.ne.3) then |
2185 | - write (*,*) 'ERROR #1 in UPINIT:',numscales |
2186 | - stop |
2187 | - endif |
2188 | - ELSEIF( INDEX(STRING,"<weightgroup type='PDF_variation'").ne.0 |
2189 | - $ .and.STRING(1:1).ne.'#') then |
2190 | - DO WHILE (.TRUE.) |
2191 | - READ(61,'(a)') STRING |
2192 | - if (INDEX(STRING,"</weightgroup>").ne.0 .and. |
2193 | - $ STRING(1:1).ne.'#') exit |
2194 | - numPDFpairs=numPDFpairs+1 |
2195 | - read(string(index(string,"pdf")+7:index(string,"</w")-1),*)iPDF |
2196 | - write(weights_info(numscales**2+numPDFpairs+1),112) |
2197 | - & 'PDF=',iPDF,' ' |
2198 | - ENDDO |
2199 | - nwgt=nwgt+numPDFpairs |
2200 | - numPDFpairs=numPDFpairs/2 |
2201 | - ELSEIF( INDEX(STRING,"<weightgroup type='mg_reweighting'").ne.0 |
2202 | - $ .and.STRING(1:1).ne.'#') then |
2203 | - DO WHILE (.TRUE.) |
2204 | - READ(61,'(a)') STRING |
2205 | - if (INDEX(STRING,"<weight id").ne.0 .and. |
2206 | - $ STRING(1:1).ne.'#')then |
2207 | - numRWGTS=numRWGTS+1 |
2208 | - read(string(index(string,"weight id")+11:index(string,"'>")-1),*)sRWGT |
2209 | - write(weights_info(numscales**2+2*numPDFpairs+numRWGTS+1),113)sRWGT |
2210 | + if (index(string,'<initrwgt>').ne.0) then |
2211 | +c Found extra weight labels: |
2212 | + do |
2213 | + READ(61,'(a)')STRING |
2214 | +c exit when end of weight information is found |
2215 | + IF ( INDEX(STRING,'</initrwgt>').ne.0 .and. |
2216 | + & STRING(1:1).ne.'#' ) exit |
2217 | +c skip comments and weightgroup lines. We just need to copy this |
2218 | +c information |
2219 | + if ( index(string,"<weightgroup").ne.0 .or. |
2220 | + & index(string,"</weightgroup>").ne.0 .or. |
2221 | + & string(1:1).eq.'#') cycle |
2222 | + if (INDEX(STRING,"<weight id").ne.0)then |
2223 | + nwgt=nwgt+1 |
2224 | + read(string(index(string,"'>")+2: index(string |
2225 | + $ ,"</weight>")-1),'(a)')weights_info(nwgt) |
2226 | + if (nwgt.gt.max_weight_shower) then |
2227 | + write (*,*) 'Too many weights in event file. '/ |
2228 | + $ /'Increase max_weight_shower' |
2229 | + stop |
2230 | + endif |
2231 | endif |
2232 | - if (INDEX(STRING,"</weightgroup>").ne.0 .and. |
2233 | - $ STRING(1:1).ne.'#') exit |
2234 | - ENDDO |
2235 | - nwgt=nwgt+numRWGTS |
2236 | + enddo |
2237 | ELSEIF ( INDEX(STRING,'</header>').ne.0 .and. |
2238 | & STRING(1:1).ne.'#' ) then |
2239 | EXIT |
2240 | @@ -528,43 +406,18 @@ |
2241 | |
2242 | |
2243 | |
2244 | - subroutine read_rwgt_line(unit,id,wgt) |
2245 | -c read a line in the <rwgt> tag. The syntax should be |
2246 | -c <wgt id='1001'> 0.1234567e+01 </wgt> |
2247 | -c The id should be exactly 4 digits long. |
2248 | - implicit none |
2249 | - integer unit,id,wgt_start,id_start |
2250 | - double precision wgt |
2251 | - character*100 buff |
2252 | - read (unit,'(a)') buff |
2253 | -c Use char() to make sure that the non-standard characters are compiler |
2254 | -c independent (char(62)=">", char(61)="=", char(39)="'") |
2255 | - wgt_start=index(buff,CHAR(39)//CHAR(62))+2 |
2256 | - id_start=index(buff,'id'//CHAR(61)//CHAR(39))+4 |
2257 | - read (buff(id_start:100),'(i4)') id |
2258 | - read (buff(wgt_start:100),*) wgt |
2259 | - return |
2260 | - end |
2261 | - |
2262 | - |
2263 | - subroutine read_rwgt_line_RWGT(unit,cid,wgt) |
2264 | -c read a line in the <rwgt> tag. The syntax should be |
2265 | -c <wgt id='1001'> 0.1234567e+01 </wgt> |
2266 | -c The id should be exactly 4 digits long. |
2267 | - implicit none |
2268 | - integer unit,wgt_start,id_start,id_end |
2269 | - double precision wgt |
2270 | - character*100 buff |
2271 | - character*20 cid |
2272 | - read (unit,'(a)') buff |
2273 | -c Use char() to make sure that the non-standard characters are compiler |
2274 | -c independent (char(62)=">", char(61)="=", char(39)="'") |
2275 | - wgt_start=index(buff,CHAR(39)//CHAR(62))+2 |
2276 | - id_start=index(buff,'id'//CHAR(61)//CHAR(39))+4 |
2277 | - id_end=wgt_start-3 |
2278 | - |
2279 | - read (buff(id_start:id_end),*) cid |
2280 | - read (buff(wgt_start:100),*) wgt |
2281 | - |
2282 | + subroutine read_rwgt_line_wgt(unit,wgt) |
2283 | +c read a line in the <rwgt> tag. The syntax should be |
2284 | +c <wgt id='1001'> 0.1234567e+01 </wgt> |
2285 | +c The id should be exactly 4 digits long. |
2286 | + implicit none |
2287 | + integer unit,wgt_start |
2288 | + double precision wgt |
2289 | + character*100 buff |
2290 | + read (unit,'(a)') buff |
2291 | +c Use char() to make sure that the non-standard characters are compiler |
2292 | +c independent (char(62)=">", char(61)="=", char(39)="'") |
2293 | + wgt_start=index(buff,CHAR(39)//CHAR(62))+2 |
2294 | + read (buff(wgt_start:100),*) wgt |
2295 | return |
2296 | end |
2297 | |
2298 | === modified file 'Template/NLO/MCatNLO/srcPythia8/Pythia8.cc' |
2299 | --- Template/NLO/MCatNLO/srcPythia8/Pythia8.cc 2015-06-12 07:55:36 +0000 |
2300 | +++ Template/NLO/MCatNLO/srcPythia8/Pythia8.cc 2016-03-04 16:01:53 +0000 |
2301 | @@ -21,7 +21,7 @@ |
2302 | #define cevwgt cevwgt_ |
2303 | |
2304 | extern "C" { |
2305 | - void pyabeg_(int&,char(*)[15]); |
2306 | + void pyabeg_(int&,char(*)[50]); |
2307 | void pyaend_(double&); |
2308 | void pyanal_(int&,double(*)); |
2309 | } |
2310 | @@ -30,8 +30,8 @@ |
2311 | Pythia pythia; |
2312 | |
2313 | int cwgtinfo_nn; |
2314 | - char cwgtinfo_weights_info[350][15]; |
2315 | - double cwgt_ww[350]; |
2316 | + char cwgtinfo_weights_info[1024][50]; |
2317 | + double cwgt_ww[1024]; |
2318 | |
2319 | string inputname="Pythia8.cmd",outputname="Pythia8.hep"; |
2320 | |
2321 | @@ -135,6 +135,7 @@ |
2322 | for (; iLHEFread<nTry ; ++iLHEFread) { |
2323 | read.lhef_read_wgts_(cwgt_ww); |
2324 | } |
2325 | + cwgt_ww[0]=cevwgt.EVWGT; |
2326 | pyanal_(cwgtinfo_nn,cwgt_ww); |
2327 | |
2328 | if (iEvent % nstep == 0 && iEvent >= 100){ |
2329 | |
2330 | === modified file 'Template/NLO/MCatNLO/srcPythia8/Pythia82.cc' |
2331 | --- Template/NLO/MCatNLO/srcPythia8/Pythia82.cc 2015-06-12 07:55:36 +0000 |
2332 | +++ Template/NLO/MCatNLO/srcPythia8/Pythia82.cc 2016-03-04 16:01:53 +0000 |
2333 | @@ -22,7 +22,7 @@ |
2334 | #define cevwgt cevwgt_ |
2335 | |
2336 | extern "C" { |
2337 | - void pyabeg_(int&,char(*)[15]); |
2338 | + void pyabeg_(int&,char(*)[50]); |
2339 | void pyaend_(double&); |
2340 | void pyanal_(int&,double(*)); |
2341 | } |
2342 | @@ -31,8 +31,8 @@ |
2343 | Pythia pythia; |
2344 | |
2345 | int cwgtinfo_nn; |
2346 | - char cwgtinfo_weights_info[350][15]; |
2347 | - double cwgt_ww[350]; |
2348 | + char cwgtinfo_weights_info[1024][50]; |
2349 | + double cwgt_ww[1024]; |
2350 | |
2351 | string inputname="Pythia8.cmd",outputname="Pythia8.hep"; |
2352 | |
2353 | @@ -141,6 +141,7 @@ |
2354 | for (; iLHEFread<nTry ; ++iLHEFread) { |
2355 | read.lhef_read_wgts_(cwgt_ww); |
2356 | } |
2357 | + cwgt_ww[0]=cevwgt.EVWGT; |
2358 | pyanal_(cwgtinfo_nn,cwgt_ww); |
2359 | |
2360 | if (iEvent % nstep == 0 && iEvent >= 100){ |
2361 | |
2362 | === modified file 'Template/NLO/Source/PDF/pdfwrap.f' |
2363 | --- Template/NLO/Source/PDF/pdfwrap.f 2014-05-16 08:09:51 +0000 |
2364 | +++ Template/NLO/Source/PDF/pdfwrap.f 2016-03-04 16:01:53 +0000 |
2365 | @@ -292,3 +292,30 @@ |
2366 | end |
2367 | |
2368 | |
2369 | + subroutine numberPDFm(idummy) |
2370 | + implicit none |
2371 | + integer idummy |
2372 | + write (*,*) 'ERROR: YOU ARE IN THE numberPDFm SUBROUTINE.' |
2373 | + write (*,*) 'THIS SUBROUTINE SHOULD NEVER BE USED' |
2374 | + stop |
2375 | + return |
2376 | + end |
2377 | + |
2378 | + subroutine initPDFm(idummy1,idummy2) |
2379 | + implicit none |
2380 | + integer idummy1,idummy2 |
2381 | + write (*,*) 'ERROR: YOU ARE IN THE initPDFm SUBROUTINE.' |
2382 | + write (*,*) 'THIS SUBROUTINE SHOULD NEVER BE USED' |
2383 | + stop |
2384 | + return |
2385 | + end |
2386 | + |
2387 | + subroutine initPDFsetbynamem(idummy,cdummy) |
2388 | + implicit none |
2389 | + integer idummy |
2390 | + character*(*) cdummy |
2391 | + write (*,*) 'ERROR: YOU ARE IN THE initPDFsetbynamem SUBROUTINE.' |
2392 | + write (*,*) 'THIS SUBROUTINE SHOULD NEVER BE USED' |
2393 | + stop |
2394 | + return |
2395 | + end |
2396 | |
2397 | === modified file 'Template/NLO/Source/PDF/pdg2pdf_lhapdf.f' |
2398 | --- Template/NLO/Source/PDF/pdg2pdf_lhapdf.f 2015-10-21 14:57:34 +0000 |
2399 | +++ Template/NLO/Source/PDF/pdg2pdf_lhapdf.f 2016-03-04 16:01:53 +0000 |
2400 | @@ -35,7 +35,7 @@ |
2401 | include 'pdf.inc' |
2402 | C |
2403 | integer i,j,ihlast(20),ipart,iporg,ireuse,imemlast(20),iset,imem |
2404 | - & ,i_replace,ii |
2405 | + & ,i_replace,ii,isetlast(20) |
2406 | double precision xlast(20),xmulast(20),pdflast(-7:7,20) |
2407 | save ihlast,xlast,xmulast,pdflast,imemlast |
2408 | data ihlast/20*-99/ |
2409 | @@ -43,6 +43,7 @@ |
2410 | data xmulast/20*-99d9/ |
2411 | data pdflast/300*-99d9/ |
2412 | data imemlast/20*-99/ |
2413 | + data isetlast/20*-99/ |
2414 | data i_replace/20/ |
2415 | |
2416 | if (ih.eq.0) then |
2417 | @@ -59,8 +60,6 @@ |
2418 | return |
2419 | elseif (x.lt.0d0 .or. x.gt.1d0) then |
2420 | write (*,*) 'PDF not supported for Bjorken x ', x |
2421 | - open(unit=26,file='../../../error',status='unknown') |
2422 | - write(26,*) 'Error: PDF not supported for Bjorken x ',x |
2423 | stop 1 |
2424 | endif |
2425 | |
2426 | @@ -74,19 +73,11 @@ |
2427 | write(*,*) 'PDF not supported for pdg ',ipdg |
2428 | write(*,*) 'For lepton colliders, please set the lpp* '// |
2429 | $ 'variables to 0 in the run_card' |
2430 | - open(unit=26,file='../../../error',status='unknown') |
2431 | - write(26,*) 'Error: PDF not supported for pdg ',ipdg |
2432 | stop 1 |
2433 | endif |
2434 | |
2435 | c Determine the iset used in lhapdf |
2436 | call getnset(iset) |
2437 | - if (iset.ne.1) then |
2438 | - write (*,*) 'PDF not supported for Bjorken x ', x |
2439 | - open(unit=26,file='../../../error',status='unknown') |
2440 | - write(26,*) 'Error: PDF not supported for Bjorken x ',x |
2441 | - stop 1 |
2442 | - endif |
2443 | |
2444 | c Determine the member of the set (function of lhapdf) |
2445 | call getnmem(iset,imem) |
2446 | @@ -100,8 +91,10 @@ |
2447 | if (x.eq.xlast(ii)) then |
2448 | if (xmu.eq.xmulast(ii)) then |
2449 | if (imem.eq.imemlast(ii)) then |
2450 | - ireuse = ii |
2451 | - exit |
2452 | + if (iset.eq.isetlast(ii)) then |
2453 | + ireuse = ii |
2454 | + exit |
2455 | + endif |
2456 | endif |
2457 | endif |
2458 | endif |
2459 | @@ -128,6 +121,7 @@ |
2460 | xmulast(i_replace)=xmu |
2461 | ihlast(i_replace)=ih |
2462 | imemlast(i_replace)=imem |
2463 | + isetlast(i_replace)=iset |
2464 | c |
2465 | pdg2pdf=pdflast(ipart,i_replace) |
2466 | return |
2467 | |
2468 | === modified file 'Template/NLO/Source/PDF/pdg2pdf_lhapdf6.f' |
2469 | --- Template/NLO/Source/PDF/pdg2pdf_lhapdf6.f 2016-02-02 17:38:59 +0000 |
2470 | +++ Template/NLO/Source/PDF/pdg2pdf_lhapdf6.f 2016-03-04 16:01:53 +0000 |
2471 | @@ -35,7 +35,7 @@ |
2472 | include 'pdf.inc' |
2473 | C |
2474 | integer i,j,ihlast(20),ipart,iporg,ireuse,imemlast(20),iset,imem |
2475 | - & ,i_replace,ii,ipartlast(20) |
2476 | + & ,i_replace,ii,ipartlast(20),isetlast(20) |
2477 | double precision xlast(20),xmulast(20),pdflast(20) |
2478 | save ihlast,xlast,xmulast,pdflast,imemlast,ipartlast |
2479 | data ihlast/20*-99/ |
2480 | @@ -44,6 +44,7 @@ |
2481 | data xmulast/20*-99d9/ |
2482 | data pdflast/20*-99d9/ |
2483 | data imemlast/20*-99/ |
2484 | + data isetlast/20*-99/ |
2485 | data i_replace/20/ |
2486 | |
2487 | if (ih.eq.0) then |
2488 | @@ -60,8 +61,6 @@ |
2489 | return |
2490 | elseif (x.lt.0d0 .or. x.gt.1d0) then |
2491 | write (*,*) 'PDF not supported for Bjorken x ', x |
2492 | - open(unit=26,file='../../../error',status='unknown') |
2493 | - write(26,*) 'Error: PDF not supported for Bjorken x ',x |
2494 | stop 1 |
2495 | endif |
2496 | |
2497 | @@ -75,20 +74,11 @@ |
2498 | write(*,*) 'PDF not supported for pdg ',ipdg |
2499 | write(*,*) 'For lepton colliders, please set the lpp* '// |
2500 | $ 'variables to 0 in the run_card' |
2501 | - open(unit=26,file='../../../error',status='unknown') |
2502 | - write(26,*) 'Error: PDF not supported for pdg ',ipdg |
2503 | stop 1 |
2504 | endif |
2505 | |
2506 | c Determine the iset used in lhapdf |
2507 | call getnset(iset) |
2508 | - if (iset.ne.1) then |
2509 | - write (*,*) 'PDF not supported for Bjorken x ', x |
2510 | - open(unit=26,file='../../../error',status='unknown') |
2511 | - write(26,*) 'Error: PDF not supported for Bjorken x ',x |
2512 | - stop 1 |
2513 | - endif |
2514 | - |
2515 | c Determine the member of the set (function of lhapdf) |
2516 | call getnmem(iset,imem) |
2517 | |
2518 | @@ -102,8 +92,10 @@ |
2519 | if (x.eq.xlast(ii)) then |
2520 | if (xmu.eq.xmulast(ii)) then |
2521 | if (imem.eq.imemlast(ii)) then |
2522 | - ireuse = ii |
2523 | - exit |
2524 | + if (iset.eq.isetlast(ii)) then |
2525 | + ireuse = ii |
2526 | + exit |
2527 | + endif |
2528 | endif |
2529 | endif |
2530 | endif |
2531 | @@ -126,13 +118,14 @@ |
2532 | |
2533 | c Call lhapdf and give the current values to the arrays that should |
2534 | c be saved |
2535 | - call evolvepart(ipart,x,xmu,pdg2pdf) |
2536 | + call evolvepartm(iset,ipart,x,xmu,pdg2pdf) |
2537 | pdg2pdf=pdg2pdf/x |
2538 | pdflast(i_replace)=pdg2pdf |
2539 | xlast(i_replace)=x |
2540 | xmulast(i_replace)=xmu |
2541 | ihlast(i_replace)=ih |
2542 | imemlast(i_replace)=imem |
2543 | + isetlast(i_replace)=iset |
2544 | c |
2545 | return |
2546 | end |
2547 | |
2548 | === modified file 'Template/NLO/Source/run.inc' |
2549 | --- Template/NLO/Source/run.inc 2015-09-14 18:56:28 +0000 |
2550 | +++ Template/NLO/Source/run.inc 2016-03-04 16:01:53 +0000 |
2551 | @@ -22,15 +22,15 @@ |
2552 | c Ratios of current values of scales over their reference values. The |
2553 | c latter may be fixed or dynamic |
2554 | double precision muR_over_ref,muF1_over_ref,muF2_over_ref, |
2555 | - # QES_over_ref |
2556 | + # QES_over_ref,muF_over_ref |
2557 | common/cscales_fact/muR_over_ref,muF1_over_ref,muF2_over_ref, |
2558 | - # QES_over_ref |
2559 | + # QES_over_ref,muF_over_ref |
2560 | |
2561 | c Values of fixed reference scales, to be given in input |
2562 | double precision muR_ref_fixed,muF1_ref_fixed, |
2563 | - # muF2_ref_fixed,QES_ref_fixed |
2564 | + # muF2_ref_fixed,QES_ref_fixed,muF_ref_fixed |
2565 | common/cscales_fixed_values/muR_ref_fixed,muF1_ref_fixed, |
2566 | - # muF2_ref_fixed,QES_ref_fixed |
2567 | + # muF2_ref_fixed,QES_ref_fixed,muF_ref_fixed |
2568 | |
2569 | c Values of the current scales squared. The information is partly |
2570 | c redundant with that of common block /to_scale/ |
2571 | |
2572 | === modified file 'Template/NLO/Source/setrun.f' |
2573 | --- Template/NLO/Source/setrun.f 2015-03-11 13:44:47 +0000 |
2574 | +++ Template/NLO/Source/setrun.f 2016-03-04 16:01:53 +0000 |
2575 | @@ -25,6 +25,7 @@ |
2576 | include 'run.inc' |
2577 | include 'alfas.inc' |
2578 | include 'MODEL/coupl.inc' |
2579 | + include '../SubProcesses/reweight0.inc' |
2580 | |
2581 | double precision D |
2582 | common/to_dj/D |
2583 | @@ -81,6 +82,26 @@ |
2584 | call to_upper(shower_MC) |
2585 | C |
2586 | |
2587 | +c Determine if there is a need to do scale and/or PDF reweighting |
2588 | + do_rwgt_scale=.false. |
2589 | + do i=1,dyn_scale(0) |
2590 | + if (lscalevar(i) .or. dyn_scale(0).gt.1) then |
2591 | + do_rwgt_scale=.true. |
2592 | + exit |
2593 | + endif |
2594 | + enddo |
2595 | + do_rwgt_pdf=.false. |
2596 | + do i=1,lhaPDFid(0) |
2597 | + if (lpdfvar(i) .or. lhaPDFid(0).gt.1) then |
2598 | + do_rwgt_pdf=.true. |
2599 | + exit |
2600 | + endif |
2601 | + enddo |
2602 | + |
2603 | +c Default scale and PDF choice used for the actual run |
2604 | + dynamical_scale_choice=dyn_scale(1) |
2605 | + lhaid=lhaPDFid(1) |
2606 | + |
2607 | c merging cuts |
2608 | xqcut=0d0 |
2609 | xmtc=0d0 |
2610 | @@ -179,6 +200,14 @@ |
2611 | enddo |
2612 | call get_pdfup(pdlabel,pdfgup,pdfsup,lhaid) |
2613 | |
2614 | + if (lpdfvar(1) .and. (lpp(1).ne.0.or.lpp(2).ne.0) ) then |
2615 | +c fill the nmemPDF(i) array with the number of PDF error set. This we |
2616 | +c get from LHAPDF. |
2617 | + call numberPDFm(1,nmemPDF(1)) |
2618 | + else |
2619 | + nmemPDF(1)=0 |
2620 | + endif |
2621 | + |
2622 | return |
2623 | 99 write(*,*) 'error in reading' |
2624 | return |
2625 | |
2626 | === modified file 'Template/NLO/SubProcesses/c_weight.inc' |
2627 | --- Template/NLO/SubProcesses/c_weight.inc 2015-02-13 20:03:34 +0000 |
2628 | +++ Template/NLO/SubProcesses/c_weight.inc 2016-03-04 16:01:53 +0000 |
2629 | @@ -1,7 +1,7 @@ |
2630 | * -*-fortran-*- |
2631 | |
2632 | integer max_contr,max_wgt,max_iproc |
2633 | - parameter (max_contr=128,max_wgt=256,max_iproc=100) |
2634 | + parameter (max_contr=128,max_wgt=1024,max_iproc=100) |
2635 | logical H_event(max_contr) |
2636 | integer nFKS(max_contr),itype(max_contr),QCDpower(max_contr) |
2637 | $ ,pdg(nexternal,max_contr),pdg_uborn(nexternal,max_contr) |
2638 | |
2639 | === modified file 'Template/NLO/SubProcesses/collect_events.f' |
2640 | --- Template/NLO/SubProcesses/collect_events.f 2014-06-18 11:49:44 +0000 |
2641 | +++ Template/NLO/SubProcesses/collect_events.f 2016-03-04 16:01:53 +0000 |
2642 | @@ -216,7 +216,7 @@ |
2643 | common /c_i_orig/i_orig |
2644 | integer ioutput,junit(80) |
2645 | integer imaxevt,maxevt,ii,numoffiles,nevents,itot,iunit, |
2646 | - # mx_of_evt(80),i0,i,j |
2647 | + # mx_of_evt(80),i0,i,j,jj,kk,n,nn |
2648 | double precision evwgt,evwgt_sign |
2649 | integer ione |
2650 | parameter (ione=1) |
2651 | @@ -250,6 +250,7 @@ |
2652 | integer lprup_l(100),nproc_l |
2653 | logical found_proc |
2654 | include 'reweight_all.inc' |
2655 | + include 'run.inc' |
2656 | integer proc_id_tot(0:100) |
2657 | double precision xsec(100),xsecABS,xerr(100) |
2658 | logical get_xsec_from_res1 |
2659 | @@ -412,7 +413,7 @@ |
2660 | # IDBMUP,EBMUP,PDFGUP,PDFSUP,IDWTUP,NPRUP, |
2661 | # XSECUP,XERRUP,abs(evwgt),LPRUP) |
2662 | itot=maxevt |
2663 | - do ii=1,maxevt |
2664 | + do i=1,maxevt |
2665 | rnd=fk88random(iseed) |
2666 | call whichone(rnd,numoffiles,itot,mx_of_evt,junit,iunit,i0) |
2667 | call read_lhef_event(iunit, |
2668 | @@ -425,14 +426,32 @@ |
2669 | c Overwrite the weights. Also overwrite the weights used for PDF & scale |
2670 | c reweighting |
2671 | evwgt_sign=dsign(evwgt,XWGTUP) |
2672 | - do i=1,numscales |
2673 | - do j=1,numscales |
2674 | - wgtxsecmu(i,j)=wgtxsecmu(i,j)*evwgt_sign/XWGTUP |
2675 | - enddo |
2676 | - enddo |
2677 | - do i=1,numPDFpairs*2 |
2678 | - wgtxsecPDF(i)=wgtxsecPDF(i)*evwgt_sign/XWGTUP |
2679 | - enddo |
2680 | + if (do_rwgt_scale) then |
2681 | + do kk=1,dyn_scale(0) |
2682 | + if (lscalevar(kk)) then |
2683 | + do ii=1,nint(scalevarF(0)) |
2684 | + do jj=1,nint(scalevarR(0)) |
2685 | + wgtxsecmu(jj,ii,kk)=wgtxsecmu(jj,ii,kk) |
2686 | + $ *evwgt_sign/XWGTUP |
2687 | + enddo |
2688 | + enddo |
2689 | + else |
2690 | + wgtxsecmu(1,1,kk)=wgtxsecmu(1,1,kk) |
2691 | + $ *evwgt_sign/XWGTUP |
2692 | + endif |
2693 | + enddo |
2694 | + endif |
2695 | + if (do_rwgt_pdf) then |
2696 | + do nn=1,lhaPDFid(0) |
2697 | + if (lpdfvar(nn)) then |
2698 | + do n=0,nmemPDF(nn) |
2699 | + wgtxsecPDF(n,nn)=wgtxsecPDF(n,nn)*evwgt_sign/XWGTUP |
2700 | + enddo |
2701 | + else |
2702 | + wgtxsecPDF(0,nn)=wgtxsecPDF(0,nn)*evwgt_sign/XWGTUP |
2703 | + endif |
2704 | + enddo |
2705 | + endif |
2706 | endif |
2707 | call write_lhef_event(ioutput, |
2708 | # NUP,IDPRUP,evwgt_sign,SCALUP,AQEDUP,AQCDUP, |
2709 | |
2710 | === modified file 'Template/NLO/SubProcesses/fks_singular.f' |
2711 | --- Template/NLO/SubProcesses/fks_singular.f 2015-12-16 16:13:10 +0000 |
2712 | +++ Template/NLO/SubProcesses/fks_singular.f 2016-03-04 16:01:53 +0000 |
2713 | @@ -1276,9 +1276,10 @@ |
2714 | include 'reweight.inc' |
2715 | include 'reweightNLO.inc' |
2716 | include 'timing_variables.inc' |
2717 | - integer i,kr,kf,iwgt_save |
2718 | - double precision xlum(maxscales),dlum,pi,mu2_r(maxscales) |
2719 | - & ,mu2_f(maxscales),mu2_q,alphas,g(maxscales),rwgt_muR_dep_fac |
2720 | + integer i,kr,kf,iwgt_save,dd |
2721 | + double precision xlum(maxscales),dlum,pi,mu2_r(maxscales),c_mu2_r |
2722 | + $ ,c_mu2_f,mu2_f(maxscales),mu2_q,alphas,g(maxscales) |
2723 | + $ ,rwgt_muR_dep_fac |
2724 | external rwgt_muR_dep_fac |
2725 | parameter (pi=3.1415926535897932385d0) |
2726 | external dlum,alphas |
2727 | @@ -1297,33 +1298,41 @@ |
2728 | xbk(1) = bjx(1,i) |
2729 | xbk(2) = bjx(2,i) |
2730 | mu2_q=scales2(1,i) |
2731 | +c Loop over the dynamical_scale_choices |
2732 | + do dd=1,dyn_scale(0) |
2733 | c renormalisation scale variation (requires recomputation of the strong |
2734 | c coupling) |
2735 | - do kr=1,numscales |
2736 | - mu2_r(kr)=scales2(2,i)*yfactR(kr)**2 |
2737 | - g(kr)=sqrt(4d0*pi*alphas(sqrt(mu2_r(kr)))) |
2738 | - enddo |
2739 | + call set_mu_central(i,dd,c_mu2_r,c_mu2_f) |
2740 | + do kr=1,nint(scalevarR(0)) |
2741 | + if ((.not. lscalevar(dd)) .and. kr.ne.1) exit |
2742 | + mu2_r(kr)=c_mu2_r*scalevarR(kr)**2 |
2743 | + g(kr)=sqrt(4d0*pi*alphas(sqrt(mu2_r(kr)))) |
2744 | + enddo |
2745 | c factorisation scale variation (require recomputation of the PDFs) |
2746 | - do kf=1,numscales |
2747 | - mu2_f(kf)=scales2(3,i)*yfactF(kf)**2 |
2748 | - q2fact(1)=mu2_f(kf) |
2749 | - q2fact(2)=mu2_f(kf) |
2750 | - xlum(kf) = dlum() |
2751 | - enddo |
2752 | - do kr=1,numscales |
2753 | - do kf=1,numscales |
2754 | - iwgt=iwgt+1 ! increment the iwgt for the wgts() array |
2755 | - if (iwgt.gt.max_wgt) then |
2756 | - write (*,*) 'ERROR too many weights in reweight_scale' |
2757 | - & ,iwgt,max_wgt |
2758 | - stop 1 |
2759 | - endif |
2760 | + do kf=1,nint(scalevarF(0)) |
2761 | + if ((.not. lscalevar(dd)) .and. kf.ne.1) exit |
2762 | + mu2_f(kf)=c_mu2_f*scalevarF(kf)**2 |
2763 | + q2fact(1)=mu2_f(kf) |
2764 | + q2fact(2)=mu2_f(kf) |
2765 | + xlum(kf) = dlum() |
2766 | + enddo |
2767 | + do kf=1,nint(scalevarF(0)) |
2768 | + if ((.not. lscalevar(dd)) .and. kf.ne.1) exit |
2769 | + do kr=1,nint(scalevarR(0)) |
2770 | + if ((.not. lscalevar(dd)) .and. kr.ne.1) exit |
2771 | + iwgt=iwgt+1 ! increment the iwgt for the wgts() array |
2772 | + if (iwgt.gt.max_wgt) then |
2773 | + write (*,*) 'ERROR too many weights in '/ |
2774 | + $ /'reweight_scale',iwgt,max_wgt |
2775 | + stop 1 |
2776 | + endif |
2777 | c add the weights to the array |
2778 | - wgts(iwgt,i)=xlum(kf) * (wgt(1,i)+wgt(2,i)*log(mu2_r(kr) |
2779 | - & /mu2_q)+wgt(3,i)*log(mu2_f(kf)/mu2_q))*g(kr) |
2780 | - & **QCDpower(i) |
2781 | - wgts(iwgt,i)=wgts(iwgt,i) |
2782 | - & *rwgt_muR_dep_fac(sqrt(mu2_r(kr)),sqrt(mu2_r(1))) |
2783 | + wgts(iwgt,i)=xlum(kf) * (wgt(1,i)+wgt(2,i) |
2784 | + $ *log(mu2_r(kr)/mu2_q)+wgt(3,i)*log(mu2_f(kf) |
2785 | + $ /mu2_q))*g(kr)**QCDpower(i) |
2786 | + wgts(iwgt,i)=wgts(iwgt,i)*rwgt_muR_dep_fac( |
2787 | + & sqrt(mu2_r(kr)),sqrt(scales2(2,i))) |
2788 | + enddo |
2789 | enddo |
2790 | enddo |
2791 | enddo |
2792 | @@ -1355,14 +1364,22 @@ |
2793 | common/c_nFKSprocess/nFKSprocess |
2794 | call cpu_time(tBefore) |
2795 | if (icontr.eq.0) return |
2796 | + if (dyn_scale(0).gt.1) then |
2797 | + write (*,*) "When doing NNLL+NLO veto, "/ |
2798 | + $ /"can only do one dynamical_scale_choice",dyn_scale(0) |
2799 | + stop |
2800 | + endif |
2801 | + |
2802 | c currently we have 'iwgt' weights in the wgts() array. |
2803 | iwgt_save=iwgt |
2804 | c compute the new veto multiplier factor |
2805 | - do ks=1,numscales |
2806 | - do kh=1,numscales |
2807 | + do ks=1,nint(scalevarR(0)) |
2808 | + if ((.not. lscalevar(1)) .and. ks.ne.1) exit |
2809 | + do kh=1,nint(scalevarF(0)) |
2810 | + if ((.not. lscalevar(1)) .and. kh.ne.1) exit |
2811 | if (H1_factor_virt.ne.0d0) then |
2812 | - call compute_veto_multiplier(H1_factor_virt,yfactR(ks) |
2813 | - & ,yfactF(kh),veto_multiplier_new(ks,kh)) |
2814 | + call compute_veto_multiplier(H1_factor_virt,scalevarR(ks) |
2815 | + $ ,scalevarF(kh),veto_multiplier_new(ks,kh)) |
2816 | veto_multiplier_new(ks,kh)=veto_multiplier_new(ks,kh) |
2817 | & /veto_multiplier |
2818 | else |
2819 | @@ -1377,17 +1394,19 @@ |
2820 | xbk(1) = bjx(1,i) |
2821 | xbk(2) = bjx(2,i) |
2822 | mu2_q=scales2(1,i) |
2823 | +c Hard scale variation |
2824 | + do kh=1,nint(scalevarF(0)) |
2825 | + if ((.not. lscalevar(1)) .and. kh.ne.1) exit |
2826 | c soft scale variation |
2827 | - do ks=1,numscales |
2828 | - mu2_r(ks)=scales2(2,i)*yfactR(ks)**2 |
2829 | - g(ks)=sqrt(4d0*pi*alphas(sqrt(mu2_r(ks)))) |
2830 | - mu2_f(ks)=scales2(2,i)*yfactR(ks)**2 |
2831 | - q2fact(1)=mu2_f(ks) |
2832 | - q2fact(2)=mu2_f(ks) |
2833 | - xlum(ks) = dlum() |
2834 | -c Hard scale variation |
2835 | - do kh=1,numscales |
2836 | - iwgt=iwgt+1 ! increment the iwgt for the wgts() array |
2837 | + do ks=1,nint(scalevarR(0)) |
2838 | + if ((.not. lscalevar(1)) .and. ks.ne.1) exit |
2839 | + mu2_r(ks)=scales2(2,i)*scalevarR(ks)**2 |
2840 | + g(ks)=sqrt(4d0*pi*alphas(sqrt(mu2_r(ks)))) |
2841 | + mu2_f(ks)=scales2(2,i)*scalevarR(ks)**2 |
2842 | + q2fact(1)=mu2_f(ks) |
2843 | + q2fact(2)=mu2_f(ks) |
2844 | + xlum(ks) = dlum() |
2845 | + iwgt=iwgt+1 ! increment the iwgt for the wgts() array |
2846 | if (iwgt.gt.max_wgt) then |
2847 | write (*,*) 'ERROR too many weights in reweight_scale' |
2848 | & ,iwgt,max_wgt |
2849 | @@ -1401,14 +1420,14 @@ |
2850 | else |
2851 | c special for the itype=7 (i.e, the veto-compensating factor) |
2852 | call compute_veto_compensating_factor(H1_factor_virt |
2853 | - & ,born_wgt_veto,yfactR(ks),yfactF(kh) |
2854 | + & ,born_wgt_veto,scalevarR(ks),scalevarF(kh) |
2855 | & ,veto_compensating_factor_new) |
2856 | wgts(iwgt,i)=xlum(ks) * wgt(1,i)*g(ks)**QCDpower(i) |
2857 | & /veto_compensating_factor |
2858 | & *veto_compensating_factor_new |
2859 | endif |
2860 | - wgts(iwgt,i)=wgts(iwgt,i) |
2861 | - & *rwgt_muR_dep_fac(sqrt(mu2_r(ks)),sqrt(mu2_r(1))) |
2862 | + wgts(iwgt,i)=wgts(iwgt,i)*rwgt_muR_dep_fac( |
2863 | + & sqrt(mu2_r(ks)),sqrt(scales2(2,i))) |
2864 | wgts(iwgt,i)=wgts(iwgt,i)*veto_multiplier_new(ks,kh) |
2865 | enddo |
2866 | enddo |
2867 | @@ -1428,8 +1447,7 @@ |
2868 | include 'reweight.inc' |
2869 | include 'reweightNLO.inc' |
2870 | include 'timing_variables.inc' |
2871 | - integer n,izero,i |
2872 | - parameter (izero=0) |
2873 | + integer n,i,nn |
2874 | double precision xlum,dlum,pi,mu2_r,mu2_f,mu2_q,rwgt_muR_dep_fac,g |
2875 | & ,alphas |
2876 | external rwgt_muR_dep_fac |
2877 | @@ -1439,38 +1457,40 @@ |
2878 | common/c_nFKSprocess/nFKSprocess |
2879 | call cpu_time(tBefore) |
2880 | if (icontr.eq.0) return |
2881 | + do nn=1,lhaPDFid(0) |
2882 | c Use as external loop the one over the PDF sets and as internal the one |
2883 | c over the icontr. This reduces the number of calls to InitPDF and |
2884 | c allows for better caching of the PDFs |
2885 | - do n=1,numPDFs-1 |
2886 | - iwgt=iwgt+1 |
2887 | - if (iwgt.gt.max_wgt) then |
2888 | - write (*,*) 'ERROR too many weights in reweight_pdf',iwgt |
2889 | - & ,max_wgt |
2890 | - stop 1 |
2891 | - endif |
2892 | - call InitPDF(n) |
2893 | - do i=1,icontr |
2894 | - nFKSprocess=nFKS(i) |
2895 | - xbk(1) = bjx(1,i) |
2896 | - xbk(2) = bjx(2,i) |
2897 | - mu2_q=scales2(1,i) |
2898 | - mu2_r=scales2(2,i) |
2899 | - mu2_f=scales2(3,i) |
2900 | - q2fact(1)=mu2_f |
2901 | - q2fact(2)=mu2_f |
2902 | + do n=0,nmemPDF(nn) |
2903 | + iwgt=iwgt+1 |
2904 | + if (iwgt.gt.max_wgt) then |
2905 | + write (*,*) 'ERROR too many weights in reweight_pdf',iwgt |
2906 | + & ,max_wgt |
2907 | + stop 1 |
2908 | + endif |
2909 | + call InitPDFm(nn,n) |
2910 | + do i=1,icontr |
2911 | + nFKSprocess=nFKS(i) |
2912 | + xbk(1) = bjx(1,i) |
2913 | + xbk(2) = bjx(2,i) |
2914 | + mu2_q=scales2(1,i) |
2915 | + mu2_r=scales2(2,i) |
2916 | + mu2_f=scales2(3,i) |
2917 | + q2fact(1)=mu2_f |
2918 | + q2fact(2)=mu2_f |
2919 | c Compute the luminosity |
2920 | - xlum = dlum() |
2921 | + xlum = dlum() |
2922 | c Recompute the strong coupling: alpha_s in the PDF might change |
2923 | - g=sqrt(4d0*pi*alphas(sqrt(mu2_r))) |
2924 | + g=sqrt(4d0*pi*alphas(sqrt(mu2_r))) |
2925 | c add the weights to the array |
2926 | - wgts(iwgt,i)=xlum * (wgt(1,i) + wgt(2,i)*log(mu2_r/mu2_q) + |
2927 | - & wgt(3,i)*log(mu2_f/mu2_q))*g**QCDpower(i) |
2928 | - wgts(iwgt,i)=wgts(iwgt,i)* |
2929 | - & rwgt_muR_dep_fac(sqrt(mu2_r),sqrt(mu2_r)) |
2930 | + wgts(iwgt,i)=xlum * (wgt(1,i) + wgt(2,i)*log(mu2_r/mu2_q) |
2931 | + $ +wgt(3,i)*log(mu2_f/mu2_q))*g**QCDpower(i) |
2932 | + wgts(iwgt,i)=wgts(iwgt,i)* |
2933 | + & rwgt_muR_dep_fac(sqrt(mu2_r),sqrt(mu2_r)) |
2934 | + enddo |
2935 | enddo |
2936 | enddo |
2937 | - call InitPDF(izero) |
2938 | + call InitPDFm(1,0) |
2939 | call cpu_time(tAfter) |
2940 | tr_pdf=tr_pdf+(tAfter-tBefore) |
2941 | return |
2942 | @@ -6010,3 +6030,32 @@ |
2943 | FK88RANDOM = SEED*MINV |
2944 | END |
2945 | |
2946 | + |
2947 | + subroutine set_mu_central(ic,dd,c_mu2_r,c_mu2_f) |
2948 | + implicit none |
2949 | + include 'nexternal.inc' |
2950 | + include 'c_weight.inc' |
2951 | + include 'reweight0.inc' |
2952 | + include 'run.inc' |
2953 | + integer ic,dd,i,j |
2954 | + double precision c_mu2_r,c_mu2_f,muR,muF,pp(0:3,nexternal) |
2955 | + if (dd.eq.1) then |
2956 | + c_mu2_r=scales2(2,ic) |
2957 | + c_mu2_f=scales2(3,ic) |
2958 | + else |
2959 | +c need to recompute the scales using the momenta |
2960 | + dynamical_scale_choice=dyn_scale(dd) |
2961 | + do i=1,nexternal |
2962 | + do j=0,3 |
2963 | + pp(j,i)=momenta(j,i,ic) |
2964 | + enddo |
2965 | + enddo |
2966 | + call set_ren_scale(pp,muR) |
2967 | + c_mu2_r=muR**2 |
2968 | + call set_fac_scale(pp,muF) |
2969 | + c_mu2_f=muF**2 |
2970 | +c reset the default dynamical_scale_choice |
2971 | + dynamical_scale_choice=dyn_scale(1) |
2972 | + endif |
2973 | + return |
2974 | + end |
2975 | |
2976 | === modified file 'Template/NLO/SubProcesses/handling_lhe_events.f' |
2977 | --- Template/NLO/SubProcesses/handling_lhe_events.f 2015-03-03 10:11:02 +0000 |
2978 | +++ Template/NLO/SubProcesses/handling_lhe_events.f 2016-03-04 16:01:53 +0000 |
2979 | @@ -14,9 +14,6 @@ |
2980 | integer event_id |
2981 | common /c_event_id/ event_id |
2982 | data event_id /-99/ |
2983 | - logical rwgt_skip |
2984 | - common /crwgt_skip/ rwgt_skip |
2985 | - data rwgt_skip /.false./ |
2986 | integer nattr,npNLO,npLO |
2987 | common/event_attributes/nattr,npNLO,npLO |
2988 | data nattr,npNLO,npLO /0,-1,-1/ |
2989 | @@ -24,8 +21,12 @@ |
2990 | |
2991 | subroutine write_lhef_header(ifile,nevents,MonteCarlo) |
2992 | implicit none |
2993 | + include 'run.inc' |
2994 | + include 'reweight0.inc' |
2995 | + integer idwgt,kk,ii,jj,nn,n |
2996 | integer ifile,nevents |
2997 | character*10 MonteCarlo |
2998 | + character*13 temp |
2999 | c Scales |
3000 | character*80 muR_id_str,muF1_id_str,muF2_id_str,QES_id_str |
3001 | common/cscales_id_string/muR_id_str,muF1_id_str, |
3002 | @@ -35,6 +36,63 @@ |
3003 | # '<LesHouchesEvents version="3.0">' |
3004 | write(ifile,'(a)') |
3005 | # ' <!--' |
3006 | + if (do_rwgt_scale .or. do_rwgt_pdf) then |
3007 | + write(ifile,'(a)') ' <initrwgt>' |
3008 | + idwgt=1000 |
3009 | + if (do_rwgt_scale) then |
3010 | + do kk=1,dyn_scale(0) |
3011 | + write(ifile,'(a,i4,a)') |
3012 | + & " <weightgroup name='scale_variation ", |
3013 | + & dyn_scale(kk),"' combine='envelope'>" |
3014 | + if (lscalevar(kk)) then |
3015 | + do ii=1,nint(scalevarF(0)) |
3016 | + do jj=1,nint(scalevarR(0)) |
3017 | + idwgt=idwgt+1 |
3018 | + write(ifile,'(a,i4,a,i4,a,e11.5,a,e11.5,a)') |
3019 | + $ " <weight id='",idwgt,"'> dyn=", |
3020 | + $ dyn_scale(kk)," muR=",scalevarR(jj)," muF=" |
3021 | + $ ,scalevarF(ii)," </weight>" |
3022 | + enddo |
3023 | + enddo |
3024 | + else |
3025 | + idwgt=idwgt+1 |
3026 | + write(ifile,'(a,i4,a,i4,a,e11.5,a,e11.5,a)') |
3027 | + $ " <weight id='",idwgt,"'> dyn=", |
3028 | + $ dyn_scale(kk)," muR=",1d0 ," muF=",1d0 |
3029 | + $ ," </weight>" |
3030 | + endif |
3031 | + write(ifile,'(a)') " </weightgroup>" |
3032 | + enddo |
3033 | + endif |
3034 | + if (do_rwgt_pdf) then |
3035 | + do nn=1,lhaPDFid(0) |
3036 | + if (lpdfvar(nn)) then |
3037 | + write(ifile,'(a)') " <weightgroup "/ |
3038 | + & /"name='PDF_variation "/ |
3039 | + & /trim(adjustl(lhaPDFsetname(nn)))/ |
3040 | + & /"' combine='unknown'>" |
3041 | + do n=0,nmemPDF(nn) |
3042 | + idwgt=idwgt+1 |
3043 | + write(temp,'(a4,i8)') "PDF=",lhaPDFid(nn)+n |
3044 | + write(ifile,'(a,i4,a)') " <weight id='" ,idwgt |
3045 | + $ ,"'> "//trim(adjustl(temp))//' ' |
3046 | + $ //trim(adjustl(lhaPDFsetname(nn)))/ |
3047 | + $ /" </weight>" |
3048 | + enddo |
3049 | + else |
3050 | + write(ifile,'(a)') " <weightgroup "/ |
3051 | + & /"name='PDF_variation' combine='none'>" |
3052 | + idwgt=idwgt+1 |
3053 | + write(temp,'(a4,i8)') "PDF=",lhaPDFid(nn) |
3054 | + write(ifile,'(a,i4,a)') " <weight id='" ,idwgt |
3055 | + $ ,"'> "//trim(adjustl(temp))//' ' |
3056 | + $ //trim(adjustl(lhaPDFsetname(nn)))//" </weight>" |
3057 | + endif |
3058 | + write(ifile,'(a)') " </weightgroup>" |
3059 | + enddo |
3060 | + endif |
3061 | + write(ifile,'(a)') ' </initrwgt>' |
3062 | + endif |
3063 | write(ifile,'(a)')' <scalesfunctionalform>' |
3064 | write(ifile,'(a)')muR_id_str(1:len_trim(muR_id_str)) |
3065 | write(ifile,'(a)')muF1_id_str(1:len_trim(muF1_id_str)) |
3066 | @@ -57,7 +115,7 @@ |
3067 | |
3068 | subroutine write_lhef_header_banner(ifile,nevents,MonteCarlo,path) |
3069 | implicit none |
3070 | - integer ifile, i, idwgt, nevents,iseed |
3071 | + integer ifile, i, idwgt, nevents,iseed,ii,jj,kk,nn,n |
3072 | double precision mcmass(-16:21) |
3073 | c parameter to allow to include run_card.inc |
3074 | include './run.inc' |
3075 | @@ -66,6 +124,7 @@ |
3076 | character*20 pdlabel |
3077 | integer iappl |
3078 | character*7 event_norm |
3079 | + character*13 temp |
3080 | c other parameter |
3081 | integer nevents_old |
3082 | character*80 muR_id_str,muF1_id_str,muF2_id_str,QES_id_str |
3083 | @@ -74,9 +133,6 @@ |
3084 | character*10 MonteCarlo |
3085 | character*100 path |
3086 | character*72 buffer,buffer_lc,buffer2 |
3087 | - logical rwgt_skip |
3088 | - common /crwgt_skip/ rwgt_skip |
3089 | - logical rwgt_skip_pdf,rwgt_skip_scales |
3090 | integer event_id |
3091 | common /c_event_id/ event_id |
3092 | include 'reweight_all.inc' |
3093 | @@ -107,12 +163,6 @@ |
3094 | 88 close(92) |
3095 | write(ifile,'(a)') ' </slha>' |
3096 | write(ifile,'(a)') ' <MGRunCard>' |
3097 | - rwgt_skip_pdf=.true. |
3098 | - rwgt_skip_scales=.true. |
3099 | - rwgt_skip=.true. |
3100 | - pdf_set_min=-1 |
3101 | - pdf_set_max=-1 |
3102 | - numscales=0 |
3103 | c import the parameter from the run_card |
3104 | nevents_old = nevents |
3105 | include './run_card.inc' |
3106 | @@ -126,14 +176,9 @@ |
3107 | close(93) |
3108 | goto 95 |
3109 | 96 write (*,*) '"randinit" file not found in write_lhef_header_'/ |
3110 | - & /'banner: not overwriting iseed in event file header.' |
3111 | + & /'banner: not overwriting iseed in event file header.' |
3112 | c Scale variation |
3113 | - 95 if (do_rwgt_scale.or.do_rwgt_pdf) rwgt_skip=.false. |
3114 | - if (do_rwgt_scale) then |
3115 | - rwgt_skip_scales = .false. |
3116 | - numscales=3 |
3117 | - endif |
3118 | - if (do_rwgt_pdf) rwgt_skip_pdf=.false. |
3119 | + 95 continue |
3120 | |
3121 | c copy the run_card as part of the banner. |
3122 | open (unit=92,file=path(1:index(path," ")-1)//'run_card.dat' |
3123 | @@ -156,13 +201,6 @@ |
3124 | write(ifile,'(a)') buffer |
3125 | enddo |
3126 | 87 close(92) |
3127 | - if ( (pdf_set_min.ne.-1 .and. pdf_set_max.eq.-1) .or. |
3128 | - & (pdf_set_min.eq.-1 .and. pdf_set_max.ne.-1)) then |
3129 | - write (*,*) 'Not consistent PDF reweigthing parameters'/ |
3130 | - $ /' found in the run_card.',pdf_set_min,pdf_set_max |
3131 | - stop |
3132 | - endif |
3133 | - if (.not.rwgt_skip_pdf) numPDFpairs=(pdf_set_max-pdf_set_min+1)/2 |
3134 | write(ifile,'(a)') ' </MGRunCard>' |
3135 | c Functional form of the scales |
3136 | write(ifile,'(a)') ' <scalesfunctionalform>' |
3137 | @@ -183,51 +221,60 @@ |
3138 | write (ifile,'(2x,i6,3x,e12.6)')21,mcmass(21) |
3139 | write(ifile,'(a)') ' </MonteCarloMasses>' |
3140 | c Write here the reweight information if need be |
3141 | - if (.not.rwgt_skip) then |
3142 | + if (do_rwgt_scale .or. do_rwgt_pdf) then |
3143 | write(ifile,'(a)') ' <initrwgt>' |
3144 | - if (numscales.ne.0) then |
3145 | - if (numscales.ne.3) then |
3146 | - write (*,*) 'Error in handling_lhe_events.f:' |
3147 | - write (*,*) 'number of scale not equal to three' |
3148 | - $ ,numscales |
3149 | - stop |
3150 | - endif |
3151 | - write(ifile,'(a)') " <weightgroup "/ |
3152 | - & /"type='scale_variation' combine='envelope'>" |
3153 | - write(ifile,602) " <weight id='1001'>"/ |
3154 | - $ /" muR=",1d0," muF=",1d0," </weight>" |
3155 | - write(ifile,602) " <weight id='1002'>"/ |
3156 | - $ /" muR=",1d0," muF=",rw_Fscale_up," </weight>" |
3157 | - write(ifile,602) " <weight id='1003'>"/ |
3158 | - $ /" muR=",1d0," muF=",rw_Fscale_down," </weight>" |
3159 | - write(ifile,602) " <weight id='1004'>"/ |
3160 | - $ /" muR=",rw_Rscale_up," muF=",1d0," </weight>" |
3161 | - write(ifile,602) " <weight id='1005'> muR=" |
3162 | - $ ,rw_Rscale_up," muF=",rw_Fscale_up," </weight>" |
3163 | - write(ifile,602) " <weight id='1006'> muR=" |
3164 | - $ ,rw_Rscale_up," muF=",rw_Fscale_down," </weight>" |
3165 | - write(ifile,602) " <weight id='1007'> muR=" |
3166 | - $ ,rw_Rscale_down," muF=",1d0," </weight>" |
3167 | - write(ifile,602) " <weight id='1008'> muR=" |
3168 | - $ ,rw_Rscale_down," muF=",rw_Fscale_up," </weight>" |
3169 | - write(ifile,602) " <weight id='1009'> muR=" |
3170 | - $ ,rw_Rscale_down," muF=",rw_Fscale_down," </weight>" |
3171 | - write(ifile,'(a)') " </weightgroup>" |
3172 | + idwgt=1000 |
3173 | + if (do_rwgt_scale) then |
3174 | + do kk=1,dyn_scale(0) |
3175 | + write(ifile,'(a,i4,a)') |
3176 | + & " <weightgroup name='scale_variation ", |
3177 | + & dyn_scale(kk),"' combine='envelope'>" |
3178 | + if (lscalevar(kk)) then |
3179 | + do ii=1,nint(scalevarF(0)) |
3180 | + do jj=1,nint(scalevarR(0)) |
3181 | + idwgt=idwgt+1 |
3182 | + write(ifile,'(a,i4,a,i4,a,e11.5,a,e11.5,a)') |
3183 | + $ " <weight id='",idwgt,"'> dyn=", |
3184 | + $ dyn_scale(kk)," muR=",scalevarR(jj)," muF=" |
3185 | + $ ,scalevarF(ii)," </weight>" |
3186 | + enddo |
3187 | + enddo |
3188 | + else |
3189 | + idwgt=idwgt+1 |
3190 | + write(ifile,'(a,i4,a,i4,a,e11.5,a,e11.5,a)') |
3191 | + $ " <weight id='",idwgt,"'> dyn=", |
3192 | + $ dyn_scale(kk)," muR=",1d0 ," muF=",1d0 |
3193 | + $ ," </weight>" |
3194 | + endif |
3195 | + write(ifile,'(a)') " </weightgroup>" |
3196 | + enddo |
3197 | endif |
3198 | - if (numPDFpairs.ne.0) then |
3199 | - if (pdf_set_min.lt.90000) then ! MSTW & CTEQ |
3200 | - write(ifile,'(a)') " <weightgroup "/ |
3201 | - & /"type='PDF_variation' combine='hessian'>" |
3202 | - else ! NNPDF |
3203 | - write(ifile,'(a)') " <weightgroup "/ |
3204 | - & /"type='PDF_variation' combine='gaussian'>" |
3205 | - endif |
3206 | - do i=1,numPDFpairs*2 |
3207 | - idwgt=2000+i |
3208 | - write(ifile,'(a,i4,a,i6,a)') " <weight id='",idwgt, |
3209 | - $ "'> pdfset=",pdf_set_min+(i-1)," </weight>" |
3210 | + if (do_rwgt_pdf) then |
3211 | + do nn=1,lhaPDFid(0) |
3212 | + if (lpdfvar(nn)) then |
3213 | + write(ifile,'(a)') " <weightgroup "/ |
3214 | + & /"name='PDF_variation "/ |
3215 | + & /trim(adjustl(lhaPDFsetname(nn)))/ |
3216 | + & /"' combine='unknown'>" |
3217 | + do n=0,nmemPDF(nn) |
3218 | + idwgt=idwgt+1 |
3219 | + write(temp,'(a4,i8)') "PDF=",lhaPDFid(nn)+n |
3220 | + write(ifile,'(a,i4,a)') " <weight id='" ,idwgt |
3221 | + $ ,"'> "//trim(adjustl(temp))//' ' |
3222 | + $ //trim(adjustl(lhaPDFsetname(nn)))/ |
3223 | + $ /" </weight>" |
3224 | + enddo |
3225 | + else |
3226 | + write(ifile,'(a)') " <weightgroup "/ |
3227 | + & /"name='PDF_variation' combine='none'>" |
3228 | + idwgt=idwgt+1 |
3229 | + write(temp,'(a4,i8)') "PDF=",lhaPDFid(nn) |
3230 | + write(ifile,'(a,i4,a)') " <weight id='" ,idwgt |
3231 | + $ ,"'> "//trim(adjustl(temp))//' ' |
3232 | + $ //trim(adjustl(lhaPDFsetname(nn)))//" </weight>" |
3233 | + endif |
3234 | + write(ifile,'(a)') " </weightgroup>" |
3235 | enddo |
3236 | - write(ifile,'(a)') " </weightgroup>" |
3237 | endif |
3238 | write(ifile,'(a)') ' </initrwgt>' |
3239 | endif |
3240 | @@ -246,13 +293,16 @@ |
3241 | & /' run_card.dat not found :',path(1:index(path," ")-1) |
3242 | & //'run_card.dat' |
3243 | stop |
3244 | - 602 format(a,e11.5,a,e11.5,a) |
3245 | end |
3246 | |
3247 | |
3248 | subroutine read_lhef_header(ifile,nevents,MonteCarlo) |
3249 | implicit none |
3250 | - integer ifile,nevents,i,ii,ii2,iistr |
3251 | + include 'reweight0.inc' |
3252 | + include './run.inc' |
3253 | + logical already_found |
3254 | + integer ifile,nevents,i,ii,ii2,iistr,itemp |
3255 | + double precision temp |
3256 | character*10 MonteCarlo |
3257 | character*80 string,string0 |
3258 | character*3 event_norm |
3259 | @@ -264,7 +314,7 @@ |
3260 | MonteCarlo = '' |
3261 | c |
3262 | string=' ' |
3263 | - dowhile(string.ne.' -->') |
3264 | + do while(string.ne.' -->') |
3265 | string0=string |
3266 | if (index(string,'</header>').ne.0) return |
3267 | read(ifile,'(a)')string |
3268 | @@ -285,13 +335,92 @@ |
3269 | read(ifile,'(a)') muF2_id_str |
3270 | read(ifile,'(a)') QES_id_str |
3271 | endif |
3272 | +c Find the reweight information for scale and PDF uncertainties |
3273 | + if (index(string,'<initrwgt>').ne.0) then |
3274 | + dyn_scale(0)=0 |
3275 | + lhaPDFid(0)=0 |
3276 | + lscalevar(1)=.false. |
3277 | + lpdfvar(1)=.false. |
3278 | + do_rwgt_scale=.false. |
3279 | + do_rwgt_pdf=.false. |
3280 | + do |
3281 | +c find the start of a weightgroup |
3282 | + do |
3283 | + read(ifile,'(a)')string |
3284 | + if (index(string,'<weightgroup').ne.0) exit |
3285 | + if (index(string,'</initrwgt').ne.0) exit |
3286 | + enddo |
3287 | + if (index(string,"name='scale_variation").ne.0) then |
3288 | + do_rwgt_scale=.true. |
3289 | + dyn_scale(0)=dyn_scale(0)+1 |
3290 | + read(ifile,'(a)')string |
3291 | + read(string(index(string,'dyn=')+4:),*) |
3292 | + $ dyn_scale(dyn_scale(0)) |
3293 | + read(string(index(string,'muR=')+4:),*) scalevarR(1) |
3294 | + read(string(index(string,'muF=')+4:),*) scalevarF(1) |
3295 | + scalevarR(0)=1d0 |
3296 | + scalevarF(0)=1d0 |
3297 | + do |
3298 | + read(ifile,'(a)')string |
3299 | + if (index(string,'</weightgroup>').ne.0) exit |
3300 | + read(string(index(string,'muR=')+4:),*) temp |
3301 | + already_found=.false. |
3302 | + do i=1,nint(scalevarR(0)) |
3303 | + if (temp.eq.scalevarR(i)) already_found=.true. |
3304 | + enddo |
3305 | + if (.not.already_found) then |
3306 | + scalevarR(0)=scalevarR(0)+1d0 |
3307 | + scalevarR(nint(scalevarR(0)))=temp |
3308 | + endif |
3309 | + read(string(index(string,'muF=')+4:),*) temp |
3310 | + already_found=.false. |
3311 | + do i=1,nint(scalevarF(0)) |
3312 | + if (temp.eq.scalevarF(i)) already_found=.true. |
3313 | + enddo |
3314 | + if (.not.already_found) then |
3315 | + scalevarF(0)=scalevarF(0)+1d0 |
3316 | + scalevarF(nint(scalevarF(0)))=temp |
3317 | + endif |
3318 | + enddo |
3319 | + if (scalevarR(0).gt.1d0 .or. scalevarF(0).gt.1d0) then |
3320 | + lscalevar(dyn_scale(0))=.true. |
3321 | + else |
3322 | + lscalevar(dyn_scale(0))=.false. |
3323 | + endif |
3324 | + elseif (index(string,"name='PDF_variation").ne.0) then |
3325 | + do_rwgt_pdf=.true. |
3326 | + lhaPDFid(0)=lhaPDFid(0)+1 |
3327 | + nmemPDF(lhaPDFid(0))=-1 |
3328 | + do |
3329 | + read(ifile,'(a)')string |
3330 | + if (index(string,'</weightgroup>').ne.0) exit |
3331 | + nmemPDF(lhaPDFid(0))=nmemPDF(lhaPDFid(0))+1 |
3332 | + if (nmemPDF(lhaPDFid(0)).eq.0) then |
3333 | + read(string(index(string,'PDF=')+4:),*) |
3334 | + $ lhaPDFid(lhaPDFid(0)) |
3335 | + $ ,lhaPDFsetname(lhaPDFid(0)) |
3336 | + lhaPDFsetname(lhaPDFid(0)) |
3337 | + $ =trim(adjustl(lhaPDFsetname(lhaPDFid(0)))) |
3338 | + endif |
3339 | + enddo |
3340 | + if (nmemPDF(lhaPDFid(0)).gt.0) then |
3341 | + lpdfvar(lhaPDFid(0))=.true. |
3342 | + else |
3343 | + lpdfvar(lhaPDFid(0))=.false. |
3344 | + endif |
3345 | + elseif (index(string,'</initrwgt').ne.0) then |
3346 | + exit |
3347 | + endif |
3348 | + enddo |
3349 | + endif |
3350 | enddo |
3351 | + |
3352 | c Works only if the name of the MC is the last line of the comments |
3353 | MonteCarlo=string0(1:10) |
3354 | call case_trap4(10,MonteCarlo) |
3355 | c Here we are at the end of (user-defined) comments. Now go to end |
3356 | c of headers |
3357 | - dowhile(index(string,'</header>').eq.0) |
3358 | + do while(index(string,'</header>').eq.0) |
3359 | string0=string |
3360 | read(ifile,'(a)')string |
3361 | enddo |
3362 | @@ -325,7 +454,7 @@ |
3363 | itempPDF=0 |
3364 | c |
3365 | string=' ' |
3366 | - dowhile(string.ne.' -->') |
3367 | + do while(string.ne.' -->') |
3368 | string0=string |
3369 | if (index(string,'</header>').ne.0) return |
3370 | read(ifile,'(a)')string |
3371 | @@ -344,7 +473,7 @@ |
3372 | if( index(string,'<montecarlomasses>').ne.0 .or. |
3373 | # index(string,'<MonteCarloMasses>').ne.0 )then |
3374 | read(ifile,'(a)')string |
3375 | - dowhile( index(string,'</montecarlomasses>').eq.0 .and. |
3376 | + do while( index(string,'</montecarlomasses>').eq.0 .and. |
3377 | # index(string,'</MonteCarloMasses>').eq.0 ) |
3378 | read(string,*)ipart,temp |
3379 | if(ipart.lt.-16.or.ipart.gt.21)then |
3380 | @@ -356,23 +485,30 @@ |
3381 | read(ifile,'(a)')string |
3382 | enddo |
3383 | endif |
3384 | - if( index(string,'scale_variation').ne.0 )then |
3385 | - read(ifile,'(a)')string |
3386 | - itempsc=1 |
3387 | - dowhile( index(string,'</weightgroup>').eq.0 ) |
3388 | - read(ifile,'(a)')string |
3389 | - itempsc=itempsc+1 |
3390 | - enddo |
3391 | - itempsc=itempsc-1 |
3392 | - endif |
3393 | - if( index(string,'PDF_variation').ne.0 )then |
3394 | - read(ifile,'(a)')string |
3395 | - itempPDF=1 |
3396 | - dowhile( index(string,'</weightgroup>').eq.0 ) |
3397 | - read(ifile,'(a)')string |
3398 | - itempPDF=itempPDF+1 |
3399 | - enddo |
3400 | - itempPDF=itempPDF-1 |
3401 | +c Find the reweight information for scale and PDF uncertainties |
3402 | + if (index(string,'<initrwgt>').ne.0) then |
3403 | + do |
3404 | + do |
3405 | + read(ifile,'(a)')string |
3406 | + if (index(string,'<weightgroup').ne.0) exit |
3407 | + if (index(string,'</initrwgt').ne.0) exit |
3408 | + enddo |
3409 | + if (index(string,"name='scale_variation").eq.0) then |
3410 | + do |
3411 | + read(ifile,'(a)')string |
3412 | + if (index(string,'</weightgroup>').ne.0) exit |
3413 | + itempsc=itempsc+1 |
3414 | + enddo |
3415 | + elseif (index(string,"name='PDF_variation").eq.0) then |
3416 | + do |
3417 | + read(ifile,'(a)')string |
3418 | + if (index(string,'</weightgroup>').ne.0) exit |
3419 | + itempsc=itempsc+1 |
3420 | + enddo |
3421 | + elseif (index(string,'</initrwgt').ne.0) then |
3422 | + exit |
3423 | + endif |
3424 | + enddo |
3425 | endif |
3426 | if(index(string,'<scalesfunctionalform>').ne.0) then |
3427 | read(ifile,'(a)') muR_id_str |
3428 | @@ -386,7 +522,7 @@ |
3429 | call case_trap4(10,MonteCarlo) |
3430 | c Here we are at the end of (user-defined) comments. Now go to end |
3431 | c of headers |
3432 | - dowhile(index(string,'</header>').eq.0) |
3433 | + do while(index(string,'</header>').eq.0) |
3434 | string0=string |
3435 | read(ifile,'(a)')string |
3436 | enddo |
3437 | @@ -465,14 +601,12 @@ |
3438 | DOUBLE PRECISION XWGTUP,SCALUP,AQEDUP,AQCDUP, |
3439 | # PUP(5,*),VTIMUP(*),SPINUP(*) |
3440 | character*140 buff |
3441 | - integer ifile,i |
3442 | + integer ifile,i,kk |
3443 | character*9 ch1 |
3444 | integer isorh_lhe,ifks_lhe,jfks_lhe,fksfather_lhe,ipartner_lhe |
3445 | double precision scale1_lhe,scale2_lhe |
3446 | integer ii,j,nps,nng,iFKS,idwgt |
3447 | double precision wgtcentral,wgtmumin,wgtmumax,wgtpdfmin,wgtpdfmax |
3448 | - logical rwgt_skip |
3449 | - common /crwgt_skip/ rwgt_skip |
3450 | integer event_id |
3451 | common /c_event_id/ event_id |
3452 | integer i_process |
3453 | @@ -480,6 +614,7 @@ |
3454 | integer nattr,npNLO,npLO |
3455 | common/event_attributes/nattr,npNLO,npLO |
3456 | include 'reweight_all.inc' |
3457 | + include './run.inc' |
3458 | include 'unlops.inc' |
3459 | c if event_id is zero or positive (that means that there was a call |
3460 | c to write_lhef_header_banner) update it and write it |
3461 | @@ -539,129 +674,14 @@ |
3462 | # PUP(1,I),PUP(2,I),PUP(3,I),PUP(4,I),PUP(5,I), |
3463 | # VTIMUP(I),SPINUP(I) |
3464 | enddo |
3465 | - if(buff(1:1).eq.'#' .and. .not.rwgt_skip) then |
3466 | + if(buff(1:1).eq.'#' .and. (do_rwgt_scale .or. do_rwgt_pdf)) then |
3467 | write(ifile,'(a)') buff(1:len_trim(buff)) |
3468 | read(buff,*)ch1,iSorH_lhe,ifks_lhe,jfks_lhe, |
3469 | # fksfather_lhe,ipartner_lhe, |
3470 | # scale1_lhe,scale2_lhe, |
3471 | # jwgtinfo,mexternal,iwgtnumpartn, |
3472 | # wgtcentral,wgtmumin,wgtmumax,wgtpdfmin,wgtpdfmax |
3473 | - if(jwgtinfo.ge.1.and.jwgtinfo.le.4)then |
3474 | - write(ifile,'(a)') ' <rwgt>' |
3475 | - write(ifile,401)wgtref,wgtqes2(2) |
3476 | - write(ifile,402)wgtxbj(1,1),wgtxbj(2,1), |
3477 | - # wgtxbj(1,2),wgtxbj(2,2), |
3478 | - # wgtxbj(1,3),wgtxbj(2,3), |
3479 | - # wgtxbj(1,4),wgtxbj(2,4) |
3480 | - if(jwgtinfo.eq.1)then |
3481 | - write(ifile,403)wgtmuR2(1),wgtmuF12(1),wgtmuF22(1), |
3482 | - # wgtmuR2(2),wgtmuF12(2),wgtmuF22(2) |
3483 | - elseif(jwgtinfo.eq.2)then |
3484 | - ii=iSorH_lhe+1 |
3485 | - if(ii.eq.3)ii=1 |
3486 | - write(ifile,404)wgtmuR2(ii),wgtmuF12(ii),wgtmuF22(ii) |
3487 | - do i=1,mexternal |
3488 | - write(ifile,405)(wgtkinE(j,i,iSorH_lhe),j=0,3) |
3489 | - enddo |
3490 | - elseif(jwgtinfo.eq.3 .or. jwgtinfo.eq.4)then |
3491 | - do i=1,mexternal |
3492 | - write(ifile,405)(wgtkinE(j,i,1),j=0,3) |
3493 | - enddo |
3494 | - do i=1,mexternal |
3495 | - write(ifile,405)(wgtkinE(j,i,2),j=0,3) |
3496 | - enddo |
3497 | - endif |
3498 | - write(ifile,441)wgtwreal(1),wgtwreal(2), |
3499 | - # wgtwreal(3),wgtwreal(4) |
3500 | - write(ifile,441)wgtwdeg(3),wgtwdeg(4), |
3501 | - # wgtwdegmuf(3),wgtwdegmuf(4) |
3502 | - write(ifile,405)wgtwborn(2),wgtwns(2), |
3503 | - # wgtwnsmuf(2),wgtwnsmur(2) |
3504 | - do i=1,iwgtnumpartn |
3505 | - write(ifile,442)wgtwmcxsecE(i), |
3506 | - # wgtmcxbjE(1,i),wgtmcxbjE(2,i) |
3507 | - enddo |
3508 | - if(jwgtinfo.eq.4) write(ifile, |
3509 | - f '(1x,e14.8,1x,e14.8,1x,i4,1x,i4)') |
3510 | - & wgtbpower,wgtcpower,nFKSprocess_used,nFKSprocess_used_born |
3511 | - write(ifile,'(a)') ' </rwgt>' |
3512 | - elseif(jwgtinfo.eq.5) then |
3513 | - write(ifile,'(a)')' <rwgt>' |
3514 | - if (iSorH_lhe.eq.1) then ! S-event |
3515 | - write(ifile,'(1x,e14.8,1x,e14.8,i4,i4)') |
3516 | - f wgtbpower,wgtcpower,nScontributions,i_process |
3517 | - write(ifile,'(1x,i4,1x,e14.8)') nFKSprocess_used_born |
3518 | - & ,wgtref_nbody_all(i_process) |
3519 | - do i=1,mexternal |
3520 | - write(ifile,405)(wgtkin_all(j,i,2,0),j=0,3) |
3521 | - enddo |
3522 | - write(ifile,402) wgtxbj_all(1,2,0),wgtxbj_all(2,2,0) |
3523 | - write(ifile,'(1x,e14.8)') wgtqes2_all(2,0) |
3524 | - write(ifile,405)wgtwborn_all,wgtwns_all, |
3525 | - & wgtwnsmuf_all,wgtwnsmur_all |
3526 | - write(ifile,404) wgtmuR2_all(2,0),wgtmuF12_all(2,0) |
3527 | - $ ,wgtmuF22_all(2,0) |
3528 | - do ii=1,nScontributions |
3529 | - write(ifile,'(1x,i4)') nFKSprocess_reweight(ii) |
3530 | - iFKS=nFKSprocess_reweight(ii)*2-1 |
3531 | - write(ifile,'(1x,e14.8,1x,i4)') |
3532 | - & wgtref_all(iFKS,i_process),iwgtnumpartn_all(iFKS) |
3533 | - do i=1,mexternal |
3534 | - write(ifile,405)(wgtkin_all(j,i,1,iFKS),j=0,3) |
3535 | - enddo |
3536 | - write(ifile,402) |
3537 | - & wgtxbj_all(1,1,iFKS),wgtxbj_all(2,1,iFKS), |
3538 | - & wgtxbj_all(1,2,iFKS),wgtxbj_all(2,2,iFKS), |
3539 | - & wgtxbj_all(1,3,iFKS),wgtxbj_all(2,3,iFKS), |
3540 | - & wgtxbj_all(1,4,iFKS),wgtxbj_all(2,4,iFKS) |
3541 | - write(ifile,'(1x,e14.8)') wgtqes2_all(2,iFKS) |
3542 | - write(ifile,441)wgtwreal_all(1,iFKS),wgtwreal_all(2 |
3543 | - & ,iFKS),wgtwreal_all(3,iFKS),wgtwreal_all(4,iFKS) |
3544 | - write(ifile,441)wgtwdeg_all(3,iFKS),wgtwdeg_all(4,iFKS) |
3545 | - & ,wgtwdegmuf_all(3,iFKS),wgtwdegmuf_all(4,iFKS) |
3546 | - do i=1,iwgtnumpartn_all(iFKS) |
3547 | - write(ifile,442)wgtwmcxsec_all(i,iFKS), |
3548 | - & wgtmcxbj_all(1,i,iFKS),wgtmcxbj_all(2,i,iFKS) |
3549 | - enddo |
3550 | - write(ifile,404) wgtmuR2_all(1,iFKS),wgtmuF12_all(1 |
3551 | - $ ,iFKS),wgtmuF22_all(1,iFKS) |
3552 | - write(ifile,404) wgtmuR2_all(2,iFKS),wgtmuF12_all(2 |
3553 | - $ ,iFKS),wgtmuF22_all(2,iFKS) |
3554 | - enddo |
3555 | - elseif (iSorH_lhe.eq.2) then ! H-event |
3556 | - write(ifile,'(1x,e14.8,1x,e14.8,i4)') |
3557 | - f wgtbpower,wgtcpower,i_process |
3558 | - iFKS=nFKSprocess_used*2 |
3559 | - write(ifile,'(1x,i4)') nFKSprocess_used |
3560 | - write(ifile,'(1x,e14.8,1x,i4)') wgtref_all(iFKS,i_process) |
3561 | - & ,iwgtnumpartn_all(iFKS) |
3562 | - do i=1,mexternal |
3563 | - write(ifile,405)(wgtkin_all(j,i,1,iFKS),j=0,3) |
3564 | - enddo |
3565 | - do i=1,mexternal |
3566 | - write(ifile,405)(wgtkin_all(j,i,2,iFKS),j=0,3) |
3567 | - enddo |
3568 | - write(ifile,402) |
3569 | - & wgtxbj_all(1,1,iFKS),wgtxbj_all(2,1,iFKS), |
3570 | - & wgtxbj_all(1,2,iFKS),wgtxbj_all(2,2,iFKS), |
3571 | - & wgtxbj_all(1,3,iFKS),wgtxbj_all(2,3,iFKS), |
3572 | - & wgtxbj_all(1,4,iFKS),wgtxbj_all(2,4,iFKS) |
3573 | - write(ifile,441)wgtwreal_all(1,iFKS),wgtwreal_all(2 |
3574 | - & ,iFKS),wgtwreal_all(3,iFKS),wgtwreal_all(4,iFKS) |
3575 | - do i=1,iwgtnumpartn_all(iFKS) |
3576 | - write(ifile,442)wgtwmcxsec_all(i,iFKS), |
3577 | - & wgtmcxbj_all(1,i,iFKS),wgtmcxbj_all(2,i,iFKS) |
3578 | - enddo |
3579 | - write(ifile,404) wgtmuR2_all(1,iFKS),wgtmuF12_all(1,iFKS) |
3580 | - $ ,wgtmuF22_all(1,iFKS) |
3581 | - write(ifile,404) wgtmuR2_all(2,iFKS),wgtmuF12_all(2,iFKS) |
3582 | - $ ,wgtmuF22_all(2,iFKS) |
3583 | - else |
3584 | - write (*,*) 'Not an S- or H-event in write_lhef_event' |
3585 | - stop |
3586 | - endif |
3587 | - write(ifile,'(a)')' </rwgt>' |
3588 | - elseif(jwgtinfo.eq.-5) then |
3589 | + if(jwgtinfo.eq.-5) then |
3590 | write(ifile,'(a)')' <rwgt>' |
3591 | write (ifile,'(1x,d16.10,3(1x,i4))') wgtref,n_ctr_found |
3592 | & ,n_mom_conf,nint(wgtcpower) |
3593 | @@ -685,34 +705,47 @@ |
3594 | $ VTIMUP_H(I),SPINUP_H(I) |
3595 | enddo |
3596 | write(ifile,'(a)')' </unlops>' |
3597 | - elseif(jwgtinfo.eq.8)then |
3598 | - write(ifile,'(a)') ' <rwgt>' |
3599 | - write(ifile,406)wgtref,wgtxsecmu(1,1),numscales,numPDFpairs |
3600 | - do i=1,numscales |
3601 | - write(ifile,404)(wgtxsecmu(i,j),j=1,numscales) |
3602 | - enddo |
3603 | - do i=1,numPDFpairs |
3604 | - nps=2*i-1 |
3605 | - nng=2*i |
3606 | - write(ifile,404)wgtxsecPDF(nps),wgtxsecPDF(nng) |
3607 | - enddo |
3608 | - write(ifile,'(a)') ' </rwgt>' |
3609 | - |
3610 | elseif(jwgtinfo.eq.9)then |
3611 | - write(ifile,'(a)') ' <rwgt>' |
3612 | - do i=1,numscales |
3613 | - do j=1,numscales |
3614 | - idwgt=1000+(i-1)*numscales+j |
3615 | - write(ifile,601) " <wgt id='",idwgt,"'>",wgtxsecmu(i |
3616 | - $ ,j)," </wgt>" |
3617 | - enddo |
3618 | - enddo |
3619 | - do i=1,2*numPDFpairs |
3620 | - idwgt=2000+i |
3621 | - write(ifile,601) " <wgt id='",idwgt,"'>",wgtxsecPDF(i) |
3622 | - $ ," </wgt>" |
3623 | - enddo |
3624 | - write(ifile,'(a)') ' </rwgt>' |
3625 | + if (do_rwgt_scale .or. do_rwgt_pdf) then |
3626 | + write(ifile,'(a)') ' <rwgt>' |
3627 | + idwgt=1000 |
3628 | + if (do_rwgt_scale) then |
3629 | + do kk=1,dyn_scale(0) |
3630 | + if (lscalevar(kk)) then |
3631 | + do i=1,nint(scalevarF(0)) |
3632 | + do j=1,nint(scalevarR(0)) |
3633 | + idwgt=idwgt+1 |
3634 | + write(ifile,601) " <wgt id='",idwgt,"'>" |
3635 | + $ ,wgtxsecmu(j,i,kk)," </wgt>" |
3636 | + enddo |
3637 | + enddo |
3638 | + else |
3639 | + idwgt=idwgt+1 |
3640 | + write(ifile,601) " <wgt id='",idwgt,"'>" |
3641 | + $ ,wgtxsecmu(1,1,kk)," </wgt>" |
3642 | + endif |
3643 | + enddo |
3644 | + endif |
3645 | + if (do_rwgt_pdf) then |
3646 | + do j=1,lhaPDFid(0) |
3647 | + if (lpdfvar(j)) then |
3648 | + do i=0,nmemPDF(j) |
3649 | + idwgt=idwgt+1 |
3650 | + write(ifile,601) " <wgt id='",idwgt,"'>" |
3651 | + $ ,wgtxsecPDF(i,j)," </wgt>" |
3652 | + enddo |
3653 | + else |
3654 | + idwgt=idwgt+1 |
3655 | + write(ifile,601) " <wgt id='",idwgt,"'>" |
3656 | + $ ,wgtxsecPDF(0,j)," </wgt>" |
3657 | + endif |
3658 | + enddo |
3659 | + endif |
3660 | + write(ifile,'(a)') ' </rwgt>' |
3661 | + endif |
3662 | + else |
3663 | + write(*,*) 'Unknown jwgtinfo in handling_lhe_events',jwgtinfo |
3664 | + stop |
3665 | endif |
3666 | endif |
3667 | write(ifile,'(a)') ' </event>' |
3668 | @@ -739,7 +772,7 @@ |
3669 | INTEGER NUP,IDPRUP,IDUP(*),ISTUP(*),MOTHUP(2,*),ICOLUP(2,*) |
3670 | DOUBLE PRECISION XWGTUP,SCALUP,AQEDUP,AQCDUP, |
3671 | # PUP(5,*),VTIMUP(*),SPINUP(*) |
3672 | - integer ifile,i |
3673 | + integer ifile,i,kk |
3674 | character*140 buff |
3675 | character*80 string |
3676 | character*12 dummy12 |
3677 | @@ -755,6 +788,7 @@ |
3678 | common/event_attributes/nattr,npNLO,npLO |
3679 | include 'reweight_all.inc' |
3680 | include 'unlops.inc' |
3681 | + include 'run.inc' |
3682 | c |
3683 | read(ifile,'(a)')string |
3684 | nattr=0 |
3685 | @@ -783,128 +817,7 @@ |
3686 | # jwgtinfo,mexternal,iwgtnumpartn, |
3687 | # wgtcentral,wgtmumin,wgtmumax,wgtpdfmin,wgtpdfmax |
3688 | |
3689 | - if(jwgtinfo.ge.1.and.jwgtinfo.le.4)then |
3690 | - read(ifile,'(a)')string |
3691 | - read(ifile,401)wgtref,wgtqes2(2) |
3692 | - read(ifile,402)wgtxbj(1,1),wgtxbj(2,1), |
3693 | - # wgtxbj(1,2),wgtxbj(2,2), |
3694 | - # wgtxbj(1,3),wgtxbj(2,3), |
3695 | - # wgtxbj(1,4),wgtxbj(2,4) |
3696 | - if(jwgtinfo.eq.1)then |
3697 | - read(ifile,403)wgtmuR2(1),wgtmuF12(1),wgtmuF22(1), |
3698 | - # wgtmuR2(2),wgtmuF12(2),wgtmuF22(2) |
3699 | - elseif(jwgtinfo.eq.2)then |
3700 | - ii=iSorH_lhe+1 |
3701 | - if(ii.eq.3)ii=1 |
3702 | - read(ifile,404)wgtmuR2(ii),wgtmuF12(ii),wgtmuF22(ii) |
3703 | - do i=1,mexternal |
3704 | - read(ifile,405)(wgtkinE(j,i,iSorH_lhe),j=0,3) |
3705 | - enddo |
3706 | - elseif(jwgtinfo.eq.3 .or. jwgtinfo.eq.4)then |
3707 | - do i=1,mexternal |
3708 | - read(ifile,405)(wgtkinE(j,i,1),j=0,3) |
3709 | - enddo |
3710 | - do i=1,mexternal |
3711 | - read(ifile,405)(wgtkinE(j,i,2),j=0,3) |
3712 | - enddo |
3713 | - endif |
3714 | - read(ifile,441)wgtwreal(1),wgtwreal(2), |
3715 | - # wgtwreal(3),wgtwreal(4) |
3716 | - read(ifile,441)wgtwdeg(3),wgtwdeg(4), |
3717 | - # wgtwdegmuf(3),wgtwdegmuf(4) |
3718 | - read(ifile,405)wgtwborn(2),wgtwns(2), |
3719 | - # wgtwnsmuf(2),wgtwnsmur(2) |
3720 | - do i=1,iwgtnumpartn |
3721 | - read(ifile,442)wgtwmcxsecE(i), |
3722 | - # wgtmcxbjE(1,i),wgtmcxbjE(2,i) |
3723 | - enddo |
3724 | - if(jwgtinfo.eq.4) read(ifile, |
3725 | - f '(1x,e14.8,1x,e14.8,1x,i4,1x,i4)') |
3726 | - & wgtbpower,wgtcpower,nFKSprocess_used,nFKSprocess_used_born |
3727 | - read(ifile,'(a)')string |
3728 | - elseif(jwgtinfo.eq.5) then |
3729 | - read(ifile,'(a)')string |
3730 | - if (iSorH_lhe.eq.1) then ! S-event |
3731 | - read(ifile,'(1x,e14.8,1x,e14.8,i4,i4)') |
3732 | - f wgtbpower,wgtcpower,nScontributions |
3733 | - $ ,i_process |
3734 | - read(ifile,'(1x,i4,1x,e14.8)') nFKSprocess_used_born |
3735 | - & ,wgtref_nbody_all(i_process) |
3736 | - do i=1,mexternal |
3737 | - read(ifile,405)(wgtkin_all(j,i,2,0),j=0,3) |
3738 | - enddo |
3739 | - read(ifile,402) wgtxbj_all(1,2,0),wgtxbj_all(2,2,0) |
3740 | - read(ifile,'(1x,e14.8)') wgtqes2_all(2,0) |
3741 | - read(ifile,405)wgtwborn_all,wgtwns_all, |
3742 | - & wgtwnsmuf_all,wgtwnsmur_all |
3743 | - read(ifile,404) wgtmuR2_all(2,0),wgtmuF12_all(2,0) |
3744 | - $ ,wgtmuF22_all(2,0) |
3745 | - do ii=1,nScontributions |
3746 | - read(ifile,'(1x,i4)') nFKSprocess_reweight(ii) |
3747 | - iFKS=nFKSprocess_reweight(ii)*2-1 |
3748 | - read(ifile,'(1x,e14.8,1x,i4)') wgtref_all(iFKS |
3749 | - $ ,i_process),iwgtnumpartn_all(iFKS) |
3750 | - do i=1,mexternal |
3751 | - read(ifile,405)(wgtkin_all(j,i,1,iFKS),j=0,3) |
3752 | - enddo |
3753 | - do i=1,mexternal |
3754 | - do j=0,3 |
3755 | - wgtkin_all(j,i,2,iFKS)=wgtkin_all(j,i,2,0) |
3756 | - enddo |
3757 | - enddo |
3758 | - read(ifile,402) |
3759 | - & wgtxbj_all(1,1,iFKS),wgtxbj_all(2,1,iFKS), |
3760 | - & wgtxbj_all(1,2,iFKS),wgtxbj_all(2,2,iFKS), |
3761 | - & wgtxbj_all(1,3,iFKS),wgtxbj_all(2,3,iFKS), |
3762 | - & wgtxbj_all(1,4,iFKS),wgtxbj_all(2,4,iFKS) |
3763 | - read(ifile,'(1x,e14.8)') wgtqes2_all(2,iFKS) |
3764 | - read(ifile,441)wgtwreal_all(1,iFKS),wgtwreal_all(2 |
3765 | - & ,iFKS),wgtwreal_all(3,iFKS),wgtwreal_all(4,iFKS) |
3766 | - read(ifile,441)wgtwdeg_all(3,iFKS),wgtwdeg_all(4,iFKS) |
3767 | - & ,wgtwdegmuf_all(3,iFKS),wgtwdegmuf_all(4,iFKS) |
3768 | - do i=1,iwgtnumpartn_all(iFKS) |
3769 | - read(ifile,442)wgtwmcxsec_all(i,iFKS), |
3770 | - & wgtmcxbj_all(1,i,iFKS),wgtmcxbj_all(2,i,iFKS) |
3771 | - enddo |
3772 | - read(ifile,404) wgtmuR2_all(1,iFKS),wgtmuF12_all(1 |
3773 | - $ ,iFKS),wgtmuF22_all(1,iFKS) |
3774 | - read(ifile,404) wgtmuR2_all(2,iFKS),wgtmuF12_all(2 |
3775 | - $ ,iFKS),wgtmuF22_all(2,iFKS) |
3776 | - enddo |
3777 | - elseif (iSorH_lhe.eq.2) then ! H-event |
3778 | - read(ifile,'(1x,e14.8,1x,e14.8,i4)') |
3779 | - f wgtbpower,wgtcpower,i_process |
3780 | - read(ifile,'(1x,i4)') nFKSprocess_used |
3781 | - iFKS=nFKSprocess_used*2 |
3782 | - read(ifile,'(1x,e14.8,1x,i4)') wgtref_all(iFKS,i_process) |
3783 | - $ ,iwgtnumpartn_all(iFKS) |
3784 | - do i=1,mexternal |
3785 | - read(ifile,405)(wgtkin_all(j,i,1,iFKS),j=0,3) |
3786 | - enddo |
3787 | - do i=1,mexternal |
3788 | - read(ifile,405)(wgtkin_all(j,i,2,iFKS),j=0,3) |
3789 | - enddo |
3790 | - read(ifile,402) |
3791 | - & wgtxbj_all(1,1,iFKS),wgtxbj_all(2,1,iFKS), |
3792 | - & wgtxbj_all(1,2,iFKS),wgtxbj_all(2,2,iFKS), |
3793 | - & wgtxbj_all(1,3,iFKS),wgtxbj_all(2,3,iFKS), |
3794 | - & wgtxbj_all(1,4,iFKS),wgtxbj_all(2,4,iFKS) |
3795 | - read(ifile,441)wgtwreal_all(1,iFKS),wgtwreal_all(2 |
3796 | - & ,iFKS),wgtwreal_all(3,iFKS),wgtwreal_all(4,iFKS) |
3797 | - do i=1,iwgtnumpartn_all(iFKS) |
3798 | - read(ifile,442)wgtwmcxsec_all(i,iFKS), |
3799 | - & wgtmcxbj_all(1,i,iFKS),wgtmcxbj_all(2,i,iFKS) |
3800 | - enddo |
3801 | - read(ifile,404) wgtmuR2_all(1,iFKS),wgtmuF12_all(1,iFKS) |
3802 | - $ ,wgtmuF22_all(1,iFKS) |
3803 | - read(ifile,404) wgtmuR2_all(2,iFKS),wgtmuF12_all(2,iFKS) |
3804 | - $ ,wgtmuF22_all(2,iFKS) |
3805 | - else |
3806 | - write (*,*) 'Not an S- or H-event in write_lhef_event' |
3807 | - stop |
3808 | - endif |
3809 | - read(ifile,'(a)')string |
3810 | - elseif(jwgtinfo.eq.-5) then |
3811 | + if(jwgtinfo.eq.-5) then |
3812 | read(ifile,'(a)')string |
3813 | read(ifile,*) wgtref,n_ctr_found,n_mom_conf,wgtcpower |
3814 | do i=1,n_mom_conf |
3815 | @@ -916,7 +829,7 @@ |
3816 | read (ifile,'(a)') n_ctr_str(i) |
3817 | enddo |
3818 | read(ifile,'(a)')string |
3819 | - elseif(jwgtinfo.eq.15) then |
3820 | + elseif(jwgtinfo.eq.15) then |
3821 | read(ifile,'(a)') string |
3822 | read(ifile,*)NUP_H |
3823 | do i=1,NUP_H |
3824 | @@ -926,33 +839,39 @@ |
3825 | $ VTIMUP_H(I),SPINUP_H(I) |
3826 | enddo |
3827 | read(ifile,'(a)') string |
3828 | - elseif(jwgtinfo.eq.8)then |
3829 | - read(ifile,'(a)')string |
3830 | - read(ifile,406)wgtref,wgtxsecmu(1,1),numscales,numPDFpairs |
3831 | - do i=1,numscales |
3832 | - read(ifile,404)(wgtxsecmu(i,j),j=1,numscales) |
3833 | - enddo |
3834 | - do i=1,numPDFpairs |
3835 | - nps=2*i-1 |
3836 | - nng=2*i |
3837 | - read(ifile,404)wgtxsecPDF(nps),wgtxsecPDF(nng) |
3838 | - enddo |
3839 | - read(ifile,'(a)')string |
3840 | elseif(jwgtinfo.eq.9)then |
3841 | - read(ifile,'(a)')string |
3842 | - wgtref=XWGTUP |
3843 | - do i=1,numscales |
3844 | - do j=1,numscales |
3845 | - call read_rwgt_line(ifile,idwgt,wgtxsecmu(i,j)) |
3846 | - enddo |
3847 | - enddo |
3848 | - do i=1,2*numPDFpairs |
3849 | - call read_rwgt_line(ifile,idwgt,wgtxsecPDF(i)) |
3850 | - enddo |
3851 | - if (numscales.eq.0 .and. numPDFpairs.ne.0) then |
3852 | - wgtxsecmu(1,1)=XWGTUP |
3853 | + if (do_rwgt_scale .or. do_rwgt_pdf) then |
3854 | + read(ifile,'(a)')string |
3855 | + wgtref=XWGTUP |
3856 | + if (do_rwgt_scale) then |
3857 | + do kk=1,dyn_scale(0) |
3858 | + if (lscalevar(kk)) then |
3859 | + do i=1,nint(scalevarF(0)) |
3860 | + do j=1,nint(scalevarR(0)) |
3861 | + call read_rwgt_line(ifile,idwgt,wgtxsecmu(j,i,kk)) |
3862 | + enddo |
3863 | + enddo |
3864 | + else |
3865 | + call read_rwgt_line(ifile,idwgt,wgtxsecmu(1,1,kk)) |
3866 | + endif |
3867 | + enddo |
3868 | + endif |
3869 | + if (do_rwgt_pdf) then |
3870 | + do j=1,lhaPDFid(0) |
3871 | + if (lpdfvar(j)) then |
3872 | + do i=0,nmemPDF(j) |
3873 | + call read_rwgt_line(ifile,idwgt,wgtxsecPDF(i,j)) |
3874 | + enddo |
3875 | + else |
3876 | + call read_rwgt_line(ifile,idwgt,wgtxsecPDF(0,j)) |
3877 | + endif |
3878 | + enddo |
3879 | + endif |
3880 | + read(ifile,'(a)')string |
3881 | endif |
3882 | - read(ifile,'(a)')string |
3883 | + else |
3884 | + write(*,*) 'Unknown jwgtinfo in handling_lhe_events',jwgtinfo |
3885 | + stop |
3886 | endif |
3887 | read(ifile,'(a)')string |
3888 | else |
3889 | @@ -982,7 +901,7 @@ |
3890 | INTEGER NUP,IDPRUP,IDUP(*),ISTUP(*),MOTHUP(2,*),ICOLUP(2,*) |
3891 | DOUBLE PRECISION XWGTUP,SCALUP,AQEDUP,AQCDUP, |
3892 | # PUP(5,*),VTIMUP(*),SPINUP(*) |
3893 | - integer ifile,i |
3894 | + integer ifile,i,kk |
3895 | character*140 buff |
3896 | character*80 string |
3897 | character*12 dummy12 |
3898 | @@ -998,6 +917,7 @@ |
3899 | common/event_attributes/nattr,npNLO,npLO |
3900 | include 'reweight_all.inc' |
3901 | include 'unlops.inc' |
3902 | + include 'run.inc' |
3903 | c |
3904 | read(ifile,'(a)')string |
3905 | if(index(string,'<event').eq.0)then |
3906 | @@ -1035,128 +955,7 @@ |
3907 | # scale1_lhe,scale2_lhe, |
3908 | # jwgtinfo,mexternal,iwgtnumpartn, |
3909 | # wgtcentral,wgtmumin,wgtmumax,wgtpdfmin,wgtpdfmax |
3910 | - if(jwgtinfo.ge.1.and.jwgtinfo.le.4)then |
3911 | - read(ifile,'(a)')string |
3912 | - read(ifile,401)wgtref,wgtqes2(2) |
3913 | - read(ifile,402)wgtxbj(1,1),wgtxbj(2,1), |
3914 | - # wgtxbj(1,2),wgtxbj(2,2), |
3915 | - # wgtxbj(1,3),wgtxbj(2,3), |
3916 | - # wgtxbj(1,4),wgtxbj(2,4) |
3917 | - if(jwgtinfo.eq.1)then |
3918 | - read(ifile,403)wgtmuR2(1),wgtmuF12(1),wgtmuF22(1), |
3919 | - # wgtmuR2(2),wgtmuF12(2),wgtmuF22(2) |
3920 | - elseif(jwgtinfo.eq.2)then |
3921 | - ii=iSorH_lhe+1 |
3922 | - if(ii.eq.3)ii=1 |
3923 | - read(ifile,404)wgtmuR2(ii),wgtmuF12(ii),wgtmuF22(ii) |
3924 | - do i=1,mexternal |
3925 | - read(ifile,405)(wgtkinE(j,i,iSorH_lhe),j=0,3) |
3926 | - enddo |
3927 | - elseif(jwgtinfo.eq.3 .or. jwgtinfo.eq.4)then |
3928 | - do i=1,mexternal |
3929 | - read(ifile,405)(wgtkinE(j,i,1),j=0,3) |
3930 | - enddo |
3931 | - do i=1,mexternal |
3932 | - read(ifile,405)(wgtkinE(j,i,2),j=0,3) |
3933 | - enddo |
3934 | - endif |
3935 | - read(ifile,441)wgtwreal(1),wgtwreal(2), |
3936 | - # wgtwreal(3),wgtwreal(4) |
3937 | - read(ifile,441)wgtwdeg(3),wgtwdeg(4), |
3938 | - # wgtwdegmuf(3),wgtwdegmuf(4) |
3939 | - read(ifile,405)wgtwborn(2),wgtwns(2), |
3940 | - # wgtwnsmuf(2),wgtwnsmur(2) |
3941 | - do i=1,iwgtnumpartn |
3942 | - read(ifile,442)wgtwmcxsecE(i), |
3943 | - # wgtmcxbjE(1,i),wgtmcxbjE(2,i) |
3944 | - enddo |
3945 | - if(jwgtinfo.eq.4) read(ifile, |
3946 | - f '(1x,e14.8,1x,e14.8,1x,i4,1x,i4)') |
3947 | - & wgtbpower,wgtcpower,nFKSprocess_used,nFKSprocess_used_born |
3948 | - read(ifile,'(a)')string |
3949 | - elseif(jwgtinfo.eq.5) then |
3950 | - read(ifile,'(a)')string |
3951 | - if (iSorH_lhe.eq.1) then ! S-event |
3952 | - read(ifile,'(1x,e14.8,1x,e14.8,i4,i4)') |
3953 | - f wgtbpower,wgtcpower,nScontributions |
3954 | - $ ,i_process |
3955 | - read(ifile,'(1x,i4,1x,e14.8)') nFKSprocess_used_born |
3956 | - & ,wgtref_nbody_all(i_process) |
3957 | - do i=1,mexternal |
3958 | - read(ifile,405)(wgtkin_all(j,i,2,0),j=0,3) |
3959 | - enddo |
3960 | - read(ifile,402) wgtxbj_all(1,2,0),wgtxbj_all(2,2,0) |
3961 | - read(ifile,'(1x,e14.8)') wgtqes2_all(2,0) |
3962 | - read(ifile,405)wgtwborn_all,wgtwns_all, |
3963 | - & wgtwnsmuf_all,wgtwnsmur_all |
3964 | - read(ifile,404) wgtmuR2_all(2,0),wgtmuF12_all(2,0) |
3965 | - $ ,wgtmuF22_all(2,0) |
3966 | - do ii=1,nScontributions |
3967 | - read(ifile,'(1x,i4)') nFKSprocess_reweight(ii) |
3968 | - iFKS=nFKSprocess_reweight(ii)*2-1 |
3969 | - read(ifile,'(1x,e14.8,1x,i4)') wgtref_all(iFKS |
3970 | - $ ,i_process),iwgtnumpartn_all(iFKS) |
3971 | - do i=1,mexternal |
3972 | - read(ifile,405)(wgtkin_all(j,i,1,iFKS),j=0,3) |
3973 | - enddo |
3974 | - do i=1,mexternal |
3975 | - do j=0,3 |
3976 | - wgtkin_all(j,i,2,iFKS)=wgtkin_all(j,i,2,0) |
3977 | - enddo |
3978 | - enddo |
3979 | - read(ifile,402) |
3980 | - & wgtxbj_all(1,1,iFKS),wgtxbj_all(2,1,iFKS), |
3981 | - & wgtxbj_all(1,2,iFKS),wgtxbj_all(2,2,iFKS), |
3982 | - & wgtxbj_all(1,3,iFKS),wgtxbj_all(2,3,iFKS), |
3983 | - & wgtxbj_all(1,4,iFKS),wgtxbj_all(2,4,iFKS) |
3984 | - read(ifile,'(1x,e14.8)') wgtqes2_all(2,iFKS) |
3985 | - read(ifile,441)wgtwreal_all(1,iFKS),wgtwreal_all(2 |
3986 | - & ,iFKS),wgtwreal_all(3,iFKS),wgtwreal_all(4,iFKS) |
3987 | - read(ifile,441)wgtwdeg_all(3,iFKS),wgtwdeg_all(4,iFKS) |
3988 | - & ,wgtwdegmuf_all(3,iFKS),wgtwdegmuf_all(4,iFKS) |
3989 | - do i=1,iwgtnumpartn_all(iFKS) |
3990 | - read(ifile,442)wgtwmcxsec_all(i,iFKS), |
3991 | - & wgtmcxbj_all(1,i,iFKS),wgtmcxbj_all(2,i,iFKS) |
3992 | - enddo |
3993 | - read(ifile,404) wgtmuR2_all(1,iFKS),wgtmuF12_all(1 |
3994 | - $ ,iFKS),wgtmuF22_all(1,iFKS) |
3995 | - read(ifile,404) wgtmuR2_all(2,iFKS),wgtmuF12_all(2 |
3996 | - $ ,iFKS),wgtmuF22_all(2,iFKS) |
3997 | - enddo |
3998 | - elseif (iSorH_lhe.eq.2) then ! H-event |
3999 | - read(ifile,'(1x,e14.8,1x,e14.8,i4)') |
4000 | - f wgtbpower,wgtcpower,i_process |
4001 | - read(ifile,'(1x,i4)') nFKSprocess_used |
4002 | - iFKS=nFKSprocess_used*2 |
4003 | - read(ifile,'(1x,e14.8,1x,i4)') wgtref_all(iFKS,i_process) |
4004 | - & ,iwgtnumpartn_all(iFKS) |
4005 | - do i=1,mexternal |
4006 | - read(ifile,405)(wgtkin_all(j,i,1,iFKS),j=0,3) |
4007 | - enddo |
4008 | - do i=1,mexternal |
4009 | - read(ifile,405)(wgtkin_all(j,i,2,iFKS),j=0,3) |
4010 | - enddo |
4011 | - read(ifile,402) |
4012 | - & wgtxbj_all(1,1,iFKS),wgtxbj_all(2,1,iFKS), |
4013 | - & wgtxbj_all(1,2,iFKS),wgtxbj_all(2,2,iFKS), |
4014 | - & wgtxbj_all(1,3,iFKS),wgtxbj_all(2,3,iFKS), |
4015 | - & wgtxbj_all(1,4,iFKS),wgtxbj_all(2,4,iFKS) |
4016 | - read(ifile,441)wgtwreal_all(1,iFKS),wgtwreal_all(2 |
4017 | - & ,iFKS),wgtwreal_all(3,iFKS),wgtwreal_all(4,iFKS) |
4018 | - do i=1,iwgtnumpartn_all(iFKS) |
4019 | - read(ifile,442)wgtwmcxsec_all(i,iFKS), |
4020 | - & wgtmcxbj_all(1,i,iFKS),wgtmcxbj_all(2,i,iFKS) |
4021 | - enddo |
4022 | - read(ifile,404) wgtmuR2_all(1,iFKS),wgtmuF12_all(1,iFKS) |
4023 | - $ ,wgtmuF22_all(1,iFKS) |
4024 | - read(ifile,404) wgtmuR2_all(2,iFKS),wgtmuF12_all(2,iFKS) |
4025 | - $ ,wgtmuF22_all(2,iFKS) |
4026 | - else |
4027 | - write (*,*) 'Not an S- or H-event in write_lhef_event' |
4028 | - stop |
4029 | - endif |
4030 | - read(ifile,'(a)')string |
4031 | - elseif(jwgtinfo.eq.-5) then |
4032 | + if(jwgtinfo.eq.-5) then |
4033 | read(ifile,'(a)')string |
4034 | read(ifile,*) wgtref,n_ctr_found,n_mom_conf,wgtcpower |
4035 | do i=1,n_mom_conf |
4036 | @@ -1168,7 +967,7 @@ |
4037 | read (ifile,'(a)') n_ctr_str(i) |
4038 | enddo |
4039 | read(ifile,'(a)')string |
4040 | - elseif(jwgtinfo.eq.15) then |
4041 | + elseif(jwgtinfo.eq.15) then |
4042 | read(ifile,'(a)') string |
4043 | read(ifile,*)NUP_H |
4044 | do i=1,NUP_H |
4045 | @@ -1178,33 +977,39 @@ |
4046 | $ VTIMUP_H(I),SPINUP_H(I) |
4047 | enddo |
4048 | read(ifile,'(a)') string |
4049 | - elseif(jwgtinfo.eq.8)then |
4050 | - read(ifile,'(a)')string |
4051 | - read(ifile,406)wgtref,wgtxsecmu(1,1),numscales,numPDFpairs |
4052 | - do i=1,numscales |
4053 | - read(ifile,404)(wgtxsecmu(i,j),j=1,numscales) |
4054 | - enddo |
4055 | - do i=1,numPDFpairs |
4056 | - nps=2*i-1 |
4057 | - nng=2*i |
4058 | - read(ifile,404)wgtxsecPDF(nps),wgtxsecPDF(nng) |
4059 | - enddo |
4060 | - read(ifile,'(a)')string |
4061 | elseif(jwgtinfo.eq.9)then |
4062 | - read(ifile,'(a)')string |
4063 | - wgtref=XWGTUP |
4064 | - do i=1,numscales |
4065 | - do j=1,numscales |
4066 | - call read_rwgt_line(ifile,idwgt,wgtxsecmu(i,j)) |
4067 | - enddo |
4068 | - enddo |
4069 | - do i=1,2*numPDFpairs |
4070 | - call read_rwgt_line(ifile,idwgt,wgtxsecPDF(i)) |
4071 | - enddo |
4072 | - if (numscales.eq.0 .and. numPDFpairs.ne.0) then |
4073 | - wgtxsecmu(1,1)=XWGTUP |
4074 | + if (do_rwgt_scale .or. do_rwgt_pdf) then |
4075 | + read(ifile,'(a)')string |
4076 | + wgtref=XWGTUP |
4077 | + if (do_rwgt_scale) then |
4078 | + do kk=1,dyn_scale(0) |
4079 | + if (lscalevar(kk)) then |
4080 | + do i=1,nint(scalevarF(0)) |
4081 | + do j=1,nint(scalevarR(0)) |
4082 | + call read_rwgt_line(ifile,idwgt,wgtxsecmu(j,i,kk)) |
4083 | + enddo |
4084 | + enddo |
4085 | + else |
4086 | + call read_rwgt_line(ifile,idwgt,wgtxsecmu(1,1,kk)) |
4087 | + endif |
4088 | + enddo |
4089 | + endif |
4090 | + if (do_rwgt_pdf) then |
4091 | + do j=1,lhaPDFid(0) |
4092 | + if (lpdfvar(j)) then |
4093 | + do i=0,nmemPDF(j) |
4094 | + call read_rwgt_line(ifile,idwgt,wgtxsecPDF(i,j)) |
4095 | + enddo |
4096 | + else |
4097 | + call read_rwgt_line(ifile,idwgt,wgtxsecPDF(0,j)) |
4098 | + endif |
4099 | + enddo |
4100 | + endif |
4101 | + read(ifile,'(a)')string |
4102 | endif |
4103 | - read(ifile,'(a)')string |
4104 | + else |
4105 | + write(*,*) 'Unknown jwgtinfo in handling_lhe_events',jwgtinfo |
4106 | + stop |
4107 | endif |
4108 | read(ifile,'(a)')string |
4109 | else |
4110 | @@ -1266,7 +1071,6 @@ |
4111 | |
4112 | function iistr(string) |
4113 | c returns the position of the first non-blank character in string |
4114 | -c |
4115 | implicit none |
4116 | logical is_i |
4117 | character*(*) string |
4118 | |
4119 | === modified file 'Template/NLO/SubProcesses/madfks_plot.f' |
4120 | --- Template/NLO/SubProcesses/madfks_plot.f 2015-12-16 16:13:10 +0000 |
4121 | +++ Template/NLO/SubProcesses/madfks_plot.f 2016-03-04 16:01:53 +0000 |
4122 | @@ -6,77 +6,92 @@ |
4123 | include 'reweight0.inc' |
4124 | integer nwgt,max_weight |
4125 | parameter (max_weight=maxscales*maxscales+maxpdfs+1) |
4126 | - character*15 weights_info(max_weight) |
4127 | - integer i,npdfs,ii,jj,n |
4128 | - double precision xsecScale_acc(maxscales,maxscales) |
4129 | - $ ,xsecPDFr_acc(0:maxPDFs) |
4130 | + character*50 weights_info(max_weight) |
4131 | + character*13 temp |
4132 | + integer i,npdfs,ii,jj,n,kk,nn |
4133 | + double precision xsecScale_acc(maxscales,maxscales,maxdynscales) |
4134 | + $ ,xsecPDFr_acc(0:maxPDFs,maxPDFsets) |
4135 | common /scale_pdf_print/xsecScale_acc,xsecPDFr_acc |
4136 | integer iappl |
4137 | common /for_applgrid/ iappl |
4138 | include "appl_common.inc" |
4139 | - |
4140 | nwgt=1 |
4141 | - weights_info(nwgt)=" central value" |
4142 | + weights_info(nwgt)="central value " |
4143 | if (do_rwgt_scale) then |
4144 | - nwgt=nwgt+9 |
4145 | - if (numscales.ne.3) then |
4146 | - write (*,*) 'ERROR #1 in initplot:',numscales |
4147 | - stop 1 |
4148 | - endif |
4149 | - if (ickkw.ne.-1) then |
4150 | -c Renormalisation and factorisation scale uncertainties |
4151 | - write (weights_info(nwgt-8),'(a4,f3.1,x,a4,f3.1)') |
4152 | - & "muR=",1.0,"muF=",1d0 |
4153 | - write (weights_info(nwgt-7),'(a4,f3.1,x,a4,f3.1)') |
4154 | - & "muR=",1.0,"muF=",rw_Fscale_up |
4155 | - write (weights_info(nwgt-6),'(a4,f3.1,x,a4,f3.1)') |
4156 | - & "muR=",1.0,"muF=",rw_Fscale_down |
4157 | - write (weights_info(nwgt-5),'(a4,f3.1,x,a4,f3.1)') |
4158 | - & "muR=",rw_Rscale_up,"muF=",1d0 |
4159 | - write (weights_info(nwgt-4),'(a4,f3.1,x,a4,f3.1)') |
4160 | - & "muR=",rw_Rscale_up,"muF=",rw_Fscale_up |
4161 | - write (weights_info(nwgt-3),'(a4,f3.1,x,a4,f3.1)') |
4162 | - & "muR=",rw_Rscale_up,"muF=",rw_Fscale_down |
4163 | - write (weights_info(nwgt-2),'(a4,f3.1,x,a4,f3.1)') |
4164 | - & "muR=",rw_Rscale_down,"muF=",1d0 |
4165 | - write (weights_info(nwgt-1),'(a4,f3.1,x,a4,f3.1)') |
4166 | - & "muR=",rw_Rscale_down,"muF=",rw_Fscale_up |
4167 | - write (weights_info(nwgt ),'(a4,f3.1,x,a4,f3.1)') |
4168 | - & "muR=",rw_Rscale_down,"muF=",rw_Fscale_down |
4169 | - else |
4170 | -c Soft and Hard scale variations for NLO+NNLO jet veto |
4171 | - write (weights_info(nwgt-8),'(a4,f3.1,x,a4,f3.1)') |
4172 | - & "muS=",1.0,"muH=",1.0 |
4173 | - write (weights_info(nwgt-7),'(a4,f3.1,x,a4,f3.1)') |
4174 | - & "muS=",1.0,"muH=",2.0 |
4175 | - write (weights_info(nwgt-6),'(a4,f3.1,x,a4,f3.1)') |
4176 | - & "muS=",1.0,"muH=",0.5 |
4177 | - write (weights_info(nwgt-5),'(a4,f3.1,x,a4,f3.1)') |
4178 | - & "muS=",2.0,"muH=",1.0 |
4179 | - write (weights_info(nwgt-4),'(a4,f3.1,x,a4,f3.1)') |
4180 | - & "muS=",2.0,"muH=",2.0 |
4181 | - write (weights_info(nwgt-3),'(a4,f3.1,x,a4,f3.1)') |
4182 | - & "muS=",2.0,"muH=",0.5 |
4183 | - write (weights_info(nwgt-2),'(a4,f3.1,x,a4,f3.1)') |
4184 | - & "muS=",0.5,"muH=",1.0 |
4185 | - write (weights_info(nwgt-1),'(a4,f3.1,x,a4,f3.1)') |
4186 | - & "muS=",0.5,"muH=",2.0 |
4187 | - write (weights_info(nwgt ),'(a4,f3.1,x,a4,f3.1)') |
4188 | - & "muS=",0.5,"muH=",0.5 |
4189 | - endif |
4190 | + do kk=1,dyn_scale(0) |
4191 | +c set the weights_info string for scale variations |
4192 | + if (lscalevar(kk)) then |
4193 | + do ii=1,nint(scalevarF(0)) |
4194 | + do jj=1,nint(scalevarR(0)) |
4195 | + nwgt=nwgt+1 |
4196 | + if (ickkw.ne.-1) then |
4197 | + write(weights_info(nwgt), |
4198 | + & '(a4,i4,x,a4,f6.3,x,a4,f6.3)') |
4199 | + $ "dyn=",dyn_scale(kk),"muR=",scalevarR(jj) |
4200 | + $ ,"muF=",scalevarF(ii) |
4201 | + else |
4202 | + write(weights_info(nwgt), |
4203 | + & '(a4,i4,x,a4,f6.3,x,a4,f6.3)') |
4204 | + $ "dyn=",dyn_scale(kk),"muS=",scalevarR(jj) |
4205 | + $ ,"muH=",scalevarF(ii) |
4206 | + endif |
4207 | + enddo |
4208 | + enddo |
4209 | + else |
4210 | + nwgt=nwgt+1 |
4211 | + if (ickkw.ne.-1) then |
4212 | + write(weights_info(nwgt),'(a4,i4,x,a4,f6.3,x,a4,f6.3)') |
4213 | + $ "dyn=",dyn_scale(kk),"muR=",scalevarR(1) |
4214 | + $ ,"muF=",scalevarF(1) |
4215 | + else |
4216 | + write(weights_info(nwgt),'(a4,i4,x,a4,f6.3,x,a4,f6.3)') |
4217 | + $ "dyn=",dyn_scale(kk),"muS=",scalevarR(1) |
4218 | + $ ,"muH=",scalevarF(1) |
4219 | + endif |
4220 | + endif |
4221 | + enddo |
4222 | endif |
4223 | if (do_rwgt_pdf) then |
4224 | - npdfs=pdf_set_max-pdf_set_min+1 |
4225 | - if (nwgt+npdfs.gt.max_weight) then |
4226 | - write (*,*) "ERROR in initplot: "/ |
4227 | - $ /"too many PDFs in reweighting" |
4228 | - stop 1 |
4229 | - endif |
4230 | - do i=1,npdfs |
4231 | - write(weights_info(nwgt+i),'(a4,i8,a3)') |
4232 | - & 'PDF=',pdf_set_min-1+i,' ' |
4233 | + do nn=1,lhaPDFid(0) |
4234 | + if (lpdfvar(nn)) then |
4235 | + write (*,*) "Including central PDF with "/ |
4236 | + $ /"uncertainties for "//lhaPDFsetname(nn) |
4237 | + else |
4238 | + write (*,*) "Including central PDF for " |
4239 | + $ //lhaPDFsetname(nn) |
4240 | + endif |
4241 | +c Load all the PDF sets (the 1st one has already by loaded by the call |
4242 | +c to "setrun") |
4243 | + if (nn.gt.1) then |
4244 | + call initpdfsetbynamem(nn,lhaPDFsetname(nn)) |
4245 | + if (lpdfvar(nn)) then |
4246 | + call numberPDFm(nn,nmemPDF(nn)) |
4247 | + else |
4248 | + nmemPDF(nn)=0 |
4249 | + endif |
4250 | + endif |
4251 | + if(nmemPDF(nn)+1.gt.maxPDFs)then |
4252 | + write(*,*)'Too many PDFs: increase maxPDFs in '/ |
4253 | + $ /'reweight0.inc to ',numPDFs+1 |
4254 | + stop |
4255 | + endif |
4256 | +c set the weights_info string for PDF variation |
4257 | + if (lpdfvar(nn)) then |
4258 | + do n=0,nmemPDF(nn) |
4259 | + nwgt=nwgt+1 |
4260 | + write(temp,'(a4,i8)') "PDF=",lhaPDFid(nn)+n |
4261 | + write(weights_info(nwgt),'(a)') trim(adjustl(temp))/ |
4262 | + $ /' '//trim(adjustl(lhaPDFsetname(nn))) |
4263 | + enddo |
4264 | + else |
4265 | + nwgt=nwgt+1 |
4266 | + write(temp,'(a4,i8)') "PDF=",lhaPDFid(nn) |
4267 | + write(weights_info(nwgt),'(a)') trim(adjustl(temp))/ |
4268 | + $ /' '//trim(adjustl(lhaPDFsetname(nn))) |
4269 | + endif |
4270 | enddo |
4271 | - nwgt=nwgt+npdfs |
4272 | +c start with central member of the first set |
4273 | + call InitPDFm(1,0) |
4274 | endif |
4275 | if(iappl.ne.0)then |
4276 | c Initialize grid parameters to negative values. |
4277 | @@ -91,13 +106,25 @@ |
4278 | endif |
4279 | call analysis_begin(nwgt,weights_info) |
4280 | c To keep track of the accumulated results: |
4281 | - do ii=1,numscales |
4282 | - do jj=1,numscales |
4283 | - xsecScale_acc(jj,ii)=0d0 |
4284 | - enddo |
4285 | + do kk=1,dyn_scale(0) |
4286 | + if (lscalevar(kk)) then |
4287 | + do ii=1,nint(scalevarF(0)) |
4288 | + do jj=1,nint(scalevarR(0)) |
4289 | + xsecScale_acc(jj,ii,kk)=0d0 |
4290 | + enddo |
4291 | + enddo |
4292 | + else |
4293 | + xsecScale_acc(1,1,kk)=0d0 |
4294 | + endif |
4295 | enddo |
4296 | - do n=0,npdfs |
4297 | - xsecPDFr_acc(n)=0d0 |
4298 | + do nn=1,lhaPDFid(0) |
4299 | + if (lpdfvar(nn)) then |
4300 | + do n=0,nmemPDF(nn) |
4301 | + xsecPDFr_acc(n,nn)=0d0 |
4302 | + enddo |
4303 | + else |
4304 | + xsecPDFr_acc(0,nn)=0d0 |
4305 | + endif |
4306 | enddo |
4307 | return |
4308 | end |
4309 | @@ -107,8 +134,8 @@ |
4310 | implicit none |
4311 | include "nexternal.inc" |
4312 | include 'reweight0.inc' |
4313 | - include 'reweightNLO.inc' |
4314 | - integer ii,jj,n |
4315 | + include 'run.inc' |
4316 | + integer ii,jj,n,kk,nn |
4317 | logical usexinteg,mint |
4318 | common/cusexinteg/usexinteg,mint |
4319 | integer itmax,ncall |
4320 | @@ -116,8 +143,8 @@ |
4321 | logical useitmax |
4322 | common/cuseitmax/useitmax |
4323 | real*8 xnorm |
4324 | - double precision xsecScale_acc(maxscales,maxscales) |
4325 | - $ ,xsecPDFr_acc(0:maxPDFs) |
4326 | + double precision xsecScale_acc(maxscales,maxscales,maxdynscales) |
4327 | + $ ,xsecPDFr_acc(0:maxPDFs,maxPDFsets) |
4328 | common /scale_pdf_print/xsecScale_acc,xsecPDFr_acc |
4329 | integer iappl |
4330 | common /for_applgrid/ iappl |
4331 | @@ -137,19 +164,32 @@ |
4332 | c Write the accumulated results to a file |
4333 | open (unit=34,file='scale_pdf_dependence.dat',status='unknown') |
4334 | if (.not.useitmax) xnorm=xnorm/float(itmax) |
4335 | - write (34,*) numscales**2 |
4336 | - if (numscales.gt.0) then |
4337 | - write (34,*) ((xsecScale_acc(ii,jj)*xnorm,ii=1 |
4338 | - $ ,numscales),jj=1,numscales) |
4339 | - else |
4340 | - write (34,*) '' |
4341 | + if (do_rwgt_scale) then |
4342 | + write (34,*) "scale variations:" |
4343 | + do kk=1,dyn_scale(0) |
4344 | + if (lscalevar(kk)) then |
4345 | + write (34,*) dyn_scale(kk),nint(scalevarR(0)) |
4346 | + $ ,nint(scalevarF(0)) |
4347 | + write (34,*) ((xsecScale_acc(jj,ii,kk)*xnorm,jj=1 |
4348 | + $ ,nint(scalevarR(0))),ii=1,nint(scalevarF(0))) |
4349 | + else |
4350 | + write (34,*) dyn_scale(kk),1,1 |
4351 | + write (34,*) xsecScale_acc(1,1,kk)*xnorm |
4352 | + endif |
4353 | + enddo |
4354 | endif |
4355 | - if (numPDFs.gt.0) then |
4356 | - write (34,*) numPDFs |
4357 | - write (34,*) (xsecPDFr_acc(n)*xnorm,n=0,numPDFs-1) |
4358 | - else |
4359 | - write(34,*) numPDFs |
4360 | - write (34,*) '' |
4361 | + if (do_rwgt_pdf) then |
4362 | + write (34,*) "pdf variations:" |
4363 | + do nn=1,lhaPDFid(0) |
4364 | + if (lpdfvar(nn)) then |
4365 | + write (34,*) trim(adjustl(lhaPDFsetname(nn))), |
4366 | + $ nmemPDF(nn)+1 |
4367 | + write (34,*) (xsecPDFr_acc(n,nn)*xnorm,n=0,nmemPDF(nn)) |
4368 | + else |
4369 | + write(34,*) lhaPDFsetname(nn),nmemPDF(nn) + 1 |
4370 | + write (34,*) xsecPDFr_acc(0,nn)*xnorm |
4371 | + endif |
4372 | + enddo |
4373 | endif |
4374 | close(34) |
4375 | return |
4376 | @@ -185,7 +225,7 @@ |
4377 | integer itype |
4378 | double precision p(0:4,nexternal),pplab(0:3,nexternal),chybst |
4379 | $ ,shybst,chybstmo |
4380 | - integer i,j,ibody,i_wgt |
4381 | + integer i,j,ibody,i_wgt,ii,jj,kk,n,nn |
4382 | double precision xd(3) |
4383 | data (xd(i),i=1,3) /0d0,0d0,1d0/ |
4384 | integer istatus(nexternal),iPDG(nexternal) |
4385 | @@ -199,8 +239,8 @@ |
4386 | integer nwgt,max_weight |
4387 | parameter (max_weight=maxscales*maxscales+maxpdfs+1) |
4388 | double precision www(max_weight),wgtden,ratio |
4389 | - double precision xsecScale_acc(maxscales,maxscales) |
4390 | - $ ,xsecPDFr_acc(0:maxPDFs) |
4391 | + double precision xsecScale_acc(maxscales,maxscales,maxdynscales) |
4392 | + $ ,xsecPDFr_acc(0:maxPDFs,maxPDFsets) |
4393 | common /scale_pdf_print/xsecScale_acc,xsecPDFr_acc |
4394 | integer iappl |
4395 | common /for_applgrid/ iappl |
4396 | @@ -243,18 +283,33 @@ |
4397 | c Fill the accumulated results |
4398 | i_wgt=1 |
4399 | if (do_rwgt_scale) then |
4400 | - do i=1,numscales |
4401 | - do j=1,numscales |
4402 | + do kk=1,dyn_scale(0) |
4403 | + if (lscalevar(kk)) then |
4404 | + do ii=1,nint(scalevarF(0)) |
4405 | + do jj=1,nint(scalevarR(0)) |
4406 | + i_wgt=i_wgt+1 |
4407 | + xsecScale_acc(jj,ii,kk)=xsecScale_acc(jj,ii,kk) |
4408 | + $ +www(i_wgt) |
4409 | + enddo |
4410 | + enddo |
4411 | + else |
4412 | i_wgt=i_wgt+1 |
4413 | - xsecScale_acc(i,j)=xsecScale_acc(i,j)+www(i_wgt) |
4414 | - enddo |
4415 | + xsecScale_acc(1,1,kk)=xsecScale_acc(1,1,kk) |
4416 | + $ +www(i_wgt) |
4417 | + endif |
4418 | enddo |
4419 | endif |
4420 | if (do_rwgt_pdf) then |
4421 | - xsecPDFr_acc(0)=xsecPDFr_acc(0)+www(1) |
4422 | - do i=1,numPDFs-1 |
4423 | - i_wgt=i_wgt+1 |
4424 | - xsecPDFr_acc(i)=xsecPDFr_acc(i)+www(i_wgt) |
4425 | + do nn=1,lhaPDFid(0) |
4426 | + if (lpdfvar(nn)) then |
4427 | + do n=0,nmemPDF(nn) |
4428 | + i_wgt=i_wgt+1 |
4429 | + xsecPDFr_acc(n,nn)=xsecPDFr_acc(n,nn)+www(i_wgt) |
4430 | + enddo |
4431 | + else |
4432 | + i_wgt=i_wgt+1 |
4433 | + xsecPDFr_acc(0,nn)=xsecPDFr_acc(0,nn)+www(i_wgt) |
4434 | + endif |
4435 | enddo |
4436 | endif |
4437 | 999 return |
4438 | |
4439 | === modified file 'Template/NLO/SubProcesses/makefile' |
4440 | --- Template/NLO/SubProcesses/makefile 2016-02-19 09:48:51 +0000 |
4441 | +++ Template/NLO/SubProcesses/makefile 2016-03-04 16:01:53 +0000 |
4442 | @@ -24,6 +24,11 @@ |
4443 | $(FC) $(LDFLAGS) -o split40 $(SPLIT40) |
4444 | |
4445 | collect_events: $(COLLECT_EVENTS) |
4446 | +<<<<<<< TREE |
4447 | $(FC) $(LDFLAGS) -o collect_events $(COLLECT_EVENTS) $(LINKLIBS) |
4448 | rm handling_lhe_events.o |
4449 | +======= |
4450 | + $(FC) $(LDFLAGS) -o collect_events $(COLLECT_EVENTS) |
4451 | + rm handling_lhe_events.o |
4452 | +>>>>>>> MERGE-SOURCE |
4453 | |
4454 | |
4455 | === modified file 'Template/NLO/SubProcesses/reweight0.inc' |
4456 | --- Template/NLO/SubProcesses/reweight0.inc 2015-03-03 17:09:53 +0000 |
4457 | +++ Template/NLO/SubProcesses/reweight0.inc 2016-03-04 16:01:53 +0000 |
4458 | @@ -65,16 +65,28 @@ |
4459 | c Cross sections after variations of scales and PDFs |
4460 | c |
4461 | integer maxscales,maxPDFs |
4462 | - parameter (maxscales=3) |
4463 | + parameter (maxscales=9) |
4464 | parameter (maxPDFs=200) |
4465 | |
4466 | +c New format to allow for multiple PDF sets and scales (both functional form |
4467 | +c and normal) |
4468 | + integer maxPDFsets, maxdynscales |
4469 | + parameter (maxPDFsets=10,maxdynscales=10) |
4470 | + integer lhaPDFid(0:maxPDFsets),nmemPDF(maxPDFsets) |
4471 | + $ ,dyn_scale(0:maxdynscales) |
4472 | + logical lscalevar(maxdynscales),lpdfvar(maxPDFsets) |
4473 | + character*100 LHAPDFsetname(maxPDFsets) |
4474 | + double precision scalevarR(0:maxscales),scalevarF(0:maxscales) |
4475 | + common/new_format_scale_pdf/LHAPDFsetname,scalevarR,scalevarF |
4476 | + $ ,lhaPDFid,nmemPDF,dyn_scale,lscalevar,lpdfvar |
4477 | + |
4478 | c Number of scale factors (for each scale) and PDF error pairs |
4479 | - integer numscales,numPDFpairs |
4480 | - common/cwgxsec1/numscales,numPDFpairs |
4481 | + integer numscales,numPDFpairs,numPDFs |
4482 | + common/cwgxsec1/numscales,numPDFpairs,numPDFs |
4483 | |
4484 | c Cross sections at different scales and PDFs |
4485 | - double precision wgtxsecmu(maxscales,maxscales), |
4486 | - # wgtxsecPDF(0:maxPDFs) |
4487 | + double precision wgtxsecmu(maxscales,maxscales,maxdynscales), |
4488 | + # wgtxsecPDF(0:maxPDFs,maxPDFsets) |
4489 | common/cwgxsec2/wgtxsecmu,wgtxsecPDF |
4490 | |
4491 | c Cross sections at different scales and PDFs, for NLO computations |
4492 | @@ -136,3 +148,8 @@ |
4493 | character*1024 n_ctr_str(max_n_ctr) |
4494 | double precision momenta_str(0:3,maxparticles,max_n_ctr) |
4495 | common /c_rwgt_lines/n_ctr_str,momenta_str,n_ctr_found,n_mom_conf |
4496 | + |
4497 | + integer max_weight_shower |
4498 | + parameter (max_weight_shower=1024) |
4499 | + |
4500 | + |
4501 | |
4502 | === modified file 'Template/NLO/SubProcesses/reweightNLO.inc' |
4503 | --- Template/NLO/SubProcesses/reweightNLO.inc 2013-10-29 11:45:05 +0000 |
4504 | +++ Template/NLO/SubProcesses/reweightNLO.inc 2016-03-04 16:01:53 +0000 |
4505 | @@ -14,8 +14,3 @@ |
4506 | c in the computation, but this condition may be relaxed |
4507 | integer idpdf(0:maxPDFs) |
4508 | common/cNLOrwgt3/idpdf |
4509 | - |
4510 | -c Total number of PDFs used in the computation (ilastPDF-ifirstPDF+2), |
4511 | -c including the central one |
4512 | - integer numPDFs |
4513 | - common/cNLOrwgt4/numPDFs |
4514 | |
4515 | === modified file 'Template/NLO/SubProcesses/reweight_xsec_events.f' |
4516 | --- Template/NLO/SubProcesses/reweight_xsec_events.f 2015-08-19 12:50:52 +0000 |
4517 | +++ Template/NLO/SubProcesses/reweight_xsec_events.f 2016-03-04 16:01:53 +0000 |
4518 | @@ -6,54 +6,40 @@ |
4519 | c and PDF variations |
4520 | c Compile with makefile_rwgt |
4521 | implicit none |
4522 | - include "nexternal.inc" |
4523 | - include "genps.inc" |
4524 | - include "nFKSconfigs.inc" |
4525 | + include "run.inc" |
4526 | include "reweight_all.inc" |
4527 | - include "run.inc" |
4528 | - character*7 pdlabel,epa_label |
4529 | - integer lhaid |
4530 | + integer i,ii,jj,kk,isave,idpdf(0:maxPDFs),itmp,lef,ifile,maxevt |
4531 | + $ ,iSorH_lhe,ifks_lhe,jfks_lhe,fksfather_lhe,ipartner_lhe |
4532 | + $ ,kwgtinfo,kexternal,jwgtnumpartn,ofile,kf,kr,n,nn |
4533 | + double precision yfactR(maxscales),yfactF(maxscales),value(20) |
4534 | + $ ,scale1_lhe,scale2_lhe,wgtcentral,wgtmumin,wgtmumax,wgtpdfmin |
4535 | + $ ,wgtpdfmax,saved_weight,xsecPDFr_acc(0:maxPDFs,maxPDFsets) |
4536 | + $ ,xsecScale_acc(maxscales,maxscales,maxdynscales) |
4537 | + logical AddInfoLHE,unweighted |
4538 | + character*9 ch1 |
4539 | + character*10 MonteCarlo |
4540 | + character*20 parm(20) |
4541 | + character*80 event_file,fname1 |
4542 | + character*140 buff |
4543 | +c Parameters |
4544 | + integer izero |
4545 | + parameter (izero=0) |
4546 | +c Common blocks |
4547 | + character*7 pdlabel,epa_label |
4548 | + integer lhaid |
4549 | common/to_pdf/lhaid,pdlabel,epa_label |
4550 | - integer maxevt,ifile,ofile,i,jj,isave,ii |
4551 | - double precision saved_weight |
4552 | - logical unweighted |
4553 | +c Les Houches Event File info: |
4554 | integer IDBMUP(2),PDFGUP(2),PDFSUP(2),IDWTUP,NPRUP,LPRUP |
4555 | double precision EBMUP(2),XSECUP,XERRUP,XMAXUP |
4556 | INTEGER MAXNUP |
4557 | PARAMETER (MAXNUP=500) |
4558 | - INTEGER NUP,IDPRUP,IDUP(MAXNUP),ISTUP(MAXNUP), |
4559 | - # MOTHUP(2,MAXNUP),ICOLUP(2,MAXNUP) |
4560 | - DOUBLE PRECISION XWGTUP,SCALUP,AQEDUP,AQCDUP, |
4561 | - # PUP(5,MAXNUP),VTIMUP(MAXNUP),SPINUP(MAXNUP) |
4562 | - integer isorh_lhe,ifks_lhe,jfks_lhe,fksfather_lhe,ipartner_lhe |
4563 | - double precision scale1_lhe,scale2_lhe,percentage |
4564 | - integer kwgtinfo,kexternal,jwgtnumpartn |
4565 | - double precision wgtcentral,wgtmumin,wgtmumax,wgtpdfmin,wgtpdfmax |
4566 | - double precision xmuR_over_ref,xmuF1_over_ref,xmuF2_over_ref, |
4567 | - # xQES_over_ref,pr_muR_over_ref,pr_muF1_over_ref,pr_muF2_over_ref, |
4568 | - # tmp,yfactR(maxscales),yfactF(maxscales),xsecPDFr(0:maxPDFs) |
4569 | - double precision xsecPDFr_acc(0:maxPDFs),xsecScale_acc(maxscales |
4570 | - $ ,maxscales) |
4571 | - double precision compute_rwgt_wgt_Sev,compute_rwgt_wgt_Sev_nbody |
4572 | - & ,compute_rwgt_wgt_Hev |
4573 | - integer kr,kf,n,nng,nps,npairs,nsets,izero,itmp,idpdf(0:maxPDFs) |
4574 | - parameter (izero=0) |
4575 | - integer lef |
4576 | - character*80 event_file,fname1 |
4577 | - character*140 buff |
4578 | - character*10 MonteCarlo |
4579 | - character*9 ch1 |
4580 | - character*20 parm(20) |
4581 | - double precision value(20) |
4582 | - logical AddInfoLHE |
4583 | - external compute_rwgt_wgt_Sev,compute_rwgt_wgt_Sev_nbody |
4584 | - & ,compute_rwgt_wgt_Hev |
4585 | - integer i_process |
4586 | - common/c_i_process/i_process |
4587 | + INTEGER NUP,IDPRUP,IDUP(MAXNUP),ISTUP(MAXNUP),MOTHUP(2,MAXNUP) |
4588 | + $ ,ICOLUP(2,MAXNUP) |
4589 | + DOUBLE PRECISION XWGTUP,SCALUP,AQEDUP,AQCDUP,PUP(5,MAXNUP) |
4590 | + $ ,VTIMUP(MAXNUP),SPINUP(MAXNUP) |
4591 | c |
4592 | call setrun !Sets up run parameters |
4593 | |
4594 | - |
4595 | write(*,*) 'Enter event file name' |
4596 | read(*,*) event_file |
4597 | |
4598 | @@ -66,74 +52,51 @@ |
4599 | isave=0 |
4600 | endif |
4601 | |
4602 | - |
4603 | - xQES_over_ref=QES_over_ref |
4604 | - xmuR_over_ref=muR_over_ref |
4605 | - xmuF1_over_ref=muF1_over_ref |
4606 | - xmuF2_over_ref=muF2_over_ref |
4607 | - write(*,*) 'Using:' |
4608 | - write(*,*) 'QES_over_ref: ', xQES_over_ref |
4609 | - write(*,*) 'muR_over_ref: ', xmuR_over_ref |
4610 | - write(*,*) 'muF1_over_ref: ', xmuF1_over_ref |
4611 | - write(*,*) 'muF2_over_ref: ', xmuF2_over_ref |
4612 | - if (xmuF1_over_ref .ne. xmuF2_over_ref) then |
4613 | - write(*,*) "The variables muF1_over_ref and muF2_over_ref" // |
4614 | - 1 " have to be set equal in the run_card.dat." // |
4615 | - 1 " Run cannot continue, quitting..." |
4616 | - stop |
4617 | - endif |
4618 | - |
4619 | if(do_rwgt_scale)then |
4620 | - yfactR(1)=1.d0 |
4621 | - yfactR(2)=rw_Rscale_up |
4622 | - yfactR(3)=rw_Rscale_down |
4623 | - yfactF(1)=1.d0 |
4624 | - yfactF(2)=rw_Fscale_up |
4625 | - yfactF(3)=rw_Fscale_down |
4626 | - write(*,*) 'Doing scale reweight:' |
4627 | - write(*,*) rw_Fscale_down, ' < mu_F < ', rw_Fscale_up |
4628 | - write(*,*) rw_Rscale_down, ' < mu_R < ', rw_Rscale_up |
4629 | - numscales=3 |
4630 | - else |
4631 | - numscales=0 |
4632 | + do nn=1,dyn_scale(0) |
4633 | + if (lscalevar(nn)) then |
4634 | + write (*,*) "Including scale uncertainties for"/ |
4635 | + $ /" dynamical_scale_choice",dyn_scale(nn) |
4636 | + write (*,*) " - renormalisation scale variation:" |
4637 | + $ ,(scalevarR(i),i=1,nint(scalevarR(0))) |
4638 | + write (*,*) " - factorisation scale variation:" |
4639 | + $ ,(scalevarF(i),i=1,nint(scalevarF(0))) |
4640 | + else |
4641 | + write (*,*) "Including central value for"/ |
4642 | + $ /" dynamical_scale_choice",dyn_scale(nn) |
4643 | + endif |
4644 | + enddo |
4645 | endif |
4646 | |
4647 | -c Note: when ipdf#0, the central PDF set will be used also as a reference |
4648 | -c for the scale uncertainty |
4649 | if(do_rwgt_pdf)then |
4650 | - |
4651 | - idpdf(0)=lhaid |
4652 | - idpdf(1)=pdf_set_min |
4653 | - itmp=pdf_set_max |
4654 | - nsets=itmp-idpdf(1)+1 |
4655 | - write(*,*) 'Doing PDF reweight:' |
4656 | - write(*,*) 'Central set id: ', idpdf(0) |
4657 | - write(*,*) 'Min error set id: ', idpdf(1) |
4658 | - write(*,*) 'Max error set id: ', itmp |
4659 | - if(mod(nsets,2).ne.0)then |
4660 | - write(*,*)'The number of error sets must be even',nsets |
4661 | - stop |
4662 | - else |
4663 | - npairs=nsets/2 |
4664 | - endif |
4665 | - do i=2,nsets |
4666 | - idpdf(i)=idpdf(1)+i-1 |
4667 | - enddo |
4668 | - if(nsets.gt.maxPDFs)then |
4669 | - write(*,*)'Too many PDFs: increase maxPDFs in reweight0.inc' |
4670 | - stop |
4671 | - endif |
4672 | -c |
4673 | - value(1)=idpdf(0) |
4674 | - parm(1)='DEFAULT' |
4675 | - call pdfset(parm,value) |
4676 | -c |
4677 | - numPDFpairs=npairs |
4678 | - else |
4679 | - numPDFpairs=0 |
4680 | + do nn=1,lhaPDFid(0) |
4681 | + if (lpdfvar(nn)) then |
4682 | + write (*,*) "Including central PDF with "/ |
4683 | + $ /"uncertainties for "//lhaPDFsetname(nn) |
4684 | + else |
4685 | + write (*,*) "Including central PDF for " |
4686 | + $ //lhaPDFsetname(nn) |
4687 | + endif |
4688 | +c Load all the PDF sets (the 1st one has already by loaded by the call |
4689 | +c to "setrun") |
4690 | + if (nn.gt.1) then |
4691 | + call initpdfsetbynamem(nn,lhaPDFsetname(nn)) |
4692 | + if (lpdfvar(nn)) then |
4693 | + call numberPDFm(nn,nmemPDF(nn)) |
4694 | + else |
4695 | + nmemPDF(nn)=0 |
4696 | + endif |
4697 | + endif |
4698 | + if(nmemPDF(nn)+1.gt.maxPDFs)then |
4699 | + write(*,*)'Too many PDFs: increase maxPDFs in '/ |
4700 | + $ /'reweight0.inc to ',numPDFs+1 |
4701 | + stop |
4702 | + endif |
4703 | + enddo |
4704 | +c start with central member of the first set |
4705 | + call InitPDFm(1,0) |
4706 | endif |
4707 | |
4708 | -c$$$ call fk88strcat(event_file,'.rwgt',fname1) |
4709 | lef=index(event_file,' ')-1 |
4710 | fname1=event_file(1:lef)//'.rwgt' |
4711 | |
4712 | @@ -147,23 +110,21 @@ |
4713 | & XSECUP,XERRUP,XMAXUP,LPRUP) |
4714 | |
4715 | do i=1,min(10,maxevt) |
4716 | - call read_lhef_event(ifile, |
4717 | - & NUP,IDPRUP,XWGTUP,SCALUP,AQEDUP,AQCDUP, |
4718 | - & IDUP,ISTUP,MOTHUP,ICOLUP,PUP,VTIMUP,SPINUP,buff) |
4719 | - |
4720 | - if(buff(1:1).ne.'#')then |
4721 | - write(*,*)'This event file cannot be reweighted [1]',i |
4722 | - stop |
4723 | - endif |
4724 | - read(buff,*)ch1,iSorH_lhe,ifks_lhe,jfks_lhe, |
4725 | - # fksfather_lhe,ipartner_lhe, |
4726 | - # scale1_lhe,scale2_lhe, |
4727 | - # kwgtinfo,kexternal,jwgtnumpartn, |
4728 | - # wgtcentral,wgtmumin,wgtmumax,wgtpdfmin,wgtpdfmax |
4729 | - if((kwgtinfo.lt.1.or.kwgtinfo.gt.5) .and. kwgtinfo.ne.-5)then |
4730 | - write(*,*)'This event file cannot be reweighted [2]',i |
4731 | - write(*,*)kwgtinfo |
4732 | - stop 1 |
4733 | + call read_lhef_event(ifile, |
4734 | + & NUP,IDPRUP,XWGTUP,SCALUP,AQEDUP,AQCDUP, |
4735 | + & IDUP,ISTUP,MOTHUP,ICOLUP,PUP,VTIMUP,SPINUP,buff) |
4736 | + if(buff(1:1).ne.'#')then |
4737 | + write (*,*) 'This event file cannot be reweighted [1]',i |
4738 | + stop |
4739 | + endif |
4740 | + read(buff,*)ch1,iSorH_lhe,ifks_lhe,jfks_lhe,fksfather_lhe |
4741 | + $ ,ipartner_lhe,scale1_lhe,scale2_lhe,kwgtinfo,kexternal |
4742 | + $ ,jwgtnumpartn,wgtcentral,wgtmumin,wgtmumax,wgtpdfmin |
4743 | + $ ,wgtpdfmax |
4744 | + if(kwgtinfo.ne.-5)then |
4745 | + write (*,*) 'This event file cannot be reweighted [2]',i |
4746 | + write (*,*) kwgtinfo |
4747 | + stop 1 |
4748 | endif |
4749 | if(i.eq.1)then |
4750 | saved_weight=abs(XWGTUP) |
4751 | @@ -198,29 +159,34 @@ |
4752 | & XSECUP,XERRUP,XMAXUP,LPRUP) |
4753 | |
4754 | c To keep track of the accumulated results: |
4755 | - do ii=1,numscales |
4756 | - do jj=1,numscales |
4757 | - xsecScale_acc(jj,ii)=0d0 |
4758 | - enddo |
4759 | - enddo |
4760 | - do n=0,nsets |
4761 | - xsecPDFr_acc(n)=0d0 |
4762 | - enddo |
4763 | - |
4764 | - nScontributions=1 |
4765 | + do kk=1,dyn_scale(0) |
4766 | + if (lscalevar(kk)) then |
4767 | + do ii=1,nint(scalevarF(0)) |
4768 | + do jj=1,nint(scalevarR(0)) |
4769 | + xsecScale_acc(jj,ii,kk)=0d0 |
4770 | + enddo |
4771 | + enddo |
4772 | + else |
4773 | + xsecScale_acc(1,1,kk)=0d0 |
4774 | + endif |
4775 | + enddo |
4776 | + do nn=1,lhaPDFid(0) |
4777 | + if (lpdfvar(nn)) then |
4778 | + do n=0,nmemPDF(nn) |
4779 | + xsecPDFr_acc(n,nn)=0d0 |
4780 | + enddo |
4781 | + else |
4782 | + xsecPDFr_acc(0,nn)=0d0 |
4783 | + endif |
4784 | + enddo |
4785 | + nScontributions=1 |
4786 | |
4787 | c Determine the flavor map between the NLO and Born |
4788 | call find_iproc_map() |
4789 | - |
4790 | - |
4791 | - |
4792 | do i=1,maxevt |
4793 | - |
4794 | - |
4795 | call read_lhef_event(ifile, |
4796 | & NUP,IDPRUP,XWGTUP,SCALUP,AQEDUP,AQCDUP, |
4797 | & IDUP,ISTUP,MOTHUP,ICOLUP,PUP,VTIMUP,SPINUP,buff) |
4798 | - |
4799 | if(buff(1:1).ne.'#')then |
4800 | write(*,*)'This event file cannot be reweighted [3]',i |
4801 | stop |
4802 | @@ -230,246 +196,78 @@ |
4803 | $ ,jwgtnumpartn,wgtcentral,wgtmumin,wgtmumax,wgtpdfmin |
4804 | $ ,wgtpdfmax |
4805 | |
4806 | - if (kwgtinfo.ne.-5) then |
4807 | - call reweight_fill_extra_inverse() |
4808 | - |
4809 | - if(kwgtinfo.lt.1.or.kwgtinfo.gt.5)then |
4810 | - write(*,*)'This event file cannot be reweighted [4]',i |
4811 | - write(*,*)kwgtinfo |
4812 | - stop |
4813 | - endif |
4814 | - if(wgtcentral.ne.0.d0.or.wgtmumin.ne.0.d0.or. |
4815 | - # wgtmumax.ne.0.d0.or.wgtpdfmin.ne.0.d0.or. |
4816 | - # wgtpdfmax.ne.0.d0)then |
4817 | - write(*,*)'This event file was already reweighted',i |
4818 | - write(*,*)wgtcentral,wgtmumin,wgtmumax,wgtpdfmin,wgtpdfmax |
4819 | - stop |
4820 | - endif |
4821 | - |
4822 | - if (kwgtinfo.eq.5) call reweight_settozero() |
4823 | - |
4824 | - if(do_rwgt_scale)then |
4825 | - |
4826 | - wgtmumin=1.d40 |
4827 | - wgtmumax=-1.d40 |
4828 | - |
4829 | - do kr=1,3 |
4830 | - do kf=1,3 |
4831 | - wgtref=0d0 |
4832 | - pr_muR_over_ref=xmuR_over_ref*yfactR(kr) |
4833 | - pr_muF1_over_ref=xmuF1_over_ref*yfactF(kf) |
4834 | - pr_muF2_over_ref=pr_muF1_over_ref |
4835 | - wgtxsecmu(kr,kf)=0d0 |
4836 | - if(iSorH_lhe.eq.1)then |
4837 | -c The nbody contributions |
4838 | - if (kwgtinfo.eq.5) then |
4839 | - call fill_reweight0inc_nbody(i_process) |
4840 | - wgtxsecmu(kr,kf)=wgtxsecmu(kr,kf) |
4841 | - & +compute_rwgt_wgt_Sev_nbody(pr_muR_over_ref |
4842 | - & ,pr_muF1_over_ref, pr_muF2_over_ref |
4843 | - & ,xQES_over_ref, kwgtinfo) |
4844 | - call reweight_settozero() |
4845 | - endif |
4846 | - do ii=1,nScontributions |
4847 | - nFKSprocess_used=nFKSprocess_reweight(ii) |
4848 | - if (kwgtinfo.eq.5) |
4849 | - & call fill_reweight0inc(nFKSprocess_used*2-1 |
4850 | - $ ,i_process) |
4851 | - wgtxsecmu(kr,kf)=wgtxsecmu(kr,kf)+ |
4852 | - & compute_rwgt_wgt_Sev(pr_muR_over_ref |
4853 | - & ,pr_muF1_over_ref, pr_muF2_over_ref |
4854 | - & ,xQES_over_ref, kwgtinfo) |
4855 | - if (kwgtinfo.eq.5) call reweight_settozero() |
4856 | - enddo |
4857 | - elseif(iSorH_lhe.eq.2)then |
4858 | - if (kwgtinfo.eq.5) |
4859 | - & call fill_reweight0inc(nFKSprocess_used*2, |
4860 | - & i_process) |
4861 | - wgtxsecmu(kr,kf)=wgtxsecmu(kr,kf)+ |
4862 | - & compute_rwgt_wgt_Hev(pr_muR_over_ref |
4863 | - & ,pr_muF1_over_ref, pr_muF2_over_ref |
4864 | - & ,xQES_over_ref, kwgtinfo) |
4865 | - if (kwgtinfo.eq.5) call reweight_settozero() |
4866 | - else |
4867 | - write(*,*)'Invalid value of iSorH_lhe',iSorH_lhe |
4868 | - stop |
4869 | - endif |
4870 | -c |
4871 | - tmp=wgtxsecmu(kr,kf) |
4872 | - if(tmp.lt.wgtmumin)wgtmumin=tmp |
4873 | - if(tmp.gt.wgtmumax)wgtmumax=tmp |
4874 | - enddo |
4875 | - enddo |
4876 | - |
4877 | - if (kwgtinfo.eq.5) then |
4878 | - if (iSorH_lhe.eq.1) then |
4879 | - wgtref=wgtref_nbody_all(i_process) |
4880 | - do ii=1,nScontributions |
4881 | - wgtref=wgtref+ wgtref_all(nFKSprocess_reweight(ii)*2 |
4882 | - $ -1,i_process) |
4883 | - enddo |
4884 | - else |
4885 | - wgtref=wgtref_all(nFKSprocess_used*2,i_process) |
4886 | - endif |
4887 | - endif |
4888 | - |
4889 | - if(unweighted)then |
4890 | - wgtcentral=wgtxsecmu(1,1)/wgtref |
4891 | - wgtmumin=wgtmumin/wgtref |
4892 | - wgtmumax=wgtmumax/wgtref |
4893 | - else |
4894 | - wgtcentral=wgtxsecmu(1,1) |
4895 | - endif |
4896 | - |
4897 | - endif |
4898 | - |
4899 | - if(do_rwgt_pdf)then |
4900 | - |
4901 | - do n=0,nsets |
4902 | - wgtref=0d0 |
4903 | - call InitPDF(n) |
4904 | - wgtxsecPDF(n)=0d0 |
4905 | - |
4906 | - if(iSorH_lhe.eq.1)then |
4907 | -c The nbody contributions |
4908 | - if (kwgtinfo.eq.5) then |
4909 | - call fill_reweight0inc_nbody(i_process) |
4910 | - wgtxsecPDF(n)=wgtxsecPDF(n) |
4911 | - $ +compute_rwgt_wgt_Sev_nbody(xmuR_over_ref |
4912 | - $ ,xmuF1_over_ref, xmuF2_over_ref ,xQES_over_ref, |
4913 | - $ kwgtinfo) |
4914 | - call reweight_settozero() |
4915 | - endif |
4916 | - do ii=1,nScontributions |
4917 | - nFKSprocess_used=nFKSprocess_reweight(ii) |
4918 | - if (kwgtinfo.eq.5) |
4919 | - & call fill_reweight0inc(nFKSprocess_used*2-1 |
4920 | - $ ,i_process) |
4921 | - wgtxsecPDF(n)=wgtxsecPDF(n)+ |
4922 | - & compute_rwgt_wgt_Sev(xmuR_over_ref |
4923 | - & ,xmuF1_over_ref, xmuF2_over_ref ,xQES_over_ref, |
4924 | - & kwgtinfo) |
4925 | - if (kwgtinfo.eq.5) call reweight_settozero() |
4926 | - enddo |
4927 | - elseif(iSorH_lhe.eq.2)then |
4928 | - if (kwgtinfo.eq.5) |
4929 | - & call fill_reweight0inc(nFKSprocess_used*2, |
4930 | - & i_process) |
4931 | - wgtxsecPDF(n)=wgtxsecPDF(n)+ |
4932 | - & compute_rwgt_wgt_Hev(xmuR_over_ref ,xmuF1_over_ref, |
4933 | - & xmuF2_over_ref ,xQES_over_ref, kwgtinfo) |
4934 | - if (kwgtinfo.eq.5) call reweight_settozero() |
4935 | - else |
4936 | - write(*,*)'Invalid value of iSorH_lhe',iSorH_lhe |
4937 | - stop |
4938 | - endif |
4939 | -c |
4940 | - if (kwgtinfo.eq.5) then |
4941 | - if (iSorH_lhe.eq.1) then |
4942 | - wgtref=wgtref_nbody_all(i_process) |
4943 | - do ii=1,nScontributions |
4944 | - wgtref=wgtref+wgtref_all(nFKSprocess_reweight(ii) |
4945 | - $ *2-1,i_process) |
4946 | - enddo |
4947 | - else |
4948 | - wgtref=wgtref_all(nFKSprocess_used*2,i_process) |
4949 | - endif |
4950 | - endif |
4951 | - |
4952 | - if(unweighted)then |
4953 | - xsecPDFr(n)=wgtxsecPDF(n)/wgtref |
4954 | - else |
4955 | - xsecPDFr(n)=wgtxsecPDF(n) |
4956 | - endif |
4957 | - enddo |
4958 | - |
4959 | - if(do_rwgt_scale)then |
4960 | - if(abs(xsecPDFr(0)/wgtcentral-1.d0).gt.1.d-6)then |
4961 | - write(*,*)'Central valued computed with mu and PDF differ' |
4962 | - write(*,*)xsecPDFr(0),wgtcentral |
4963 | - stop |
4964 | - endif |
4965 | - else |
4966 | - wgtcentral=xsecPDFr(0) |
4967 | -c The following serves to write on tape the reference cross section |
4968 | -c computed with the new parameters |
4969 | - wgtxsecmu(1,1)=wgtxsecPDF(0) |
4970 | - endif |
4971 | - |
4972 | - wgtpdfmin=0.d0 |
4973 | - wgtpdfmax=0.d0 |
4974 | - |
4975 | - do n=1,npairs |
4976 | - nps=2*n-1 |
4977 | - nng=2*n |
4978 | - |
4979 | - wgtpdfmin=wgtpdfmin+ |
4980 | - # ( max(0.d0, |
4981 | - # xsecPDFr(0)-xsecPDFr(nps), |
4982 | - # xsecPDFr(0)-xsecPDFr(nng)) )**2 |
4983 | - wgtpdfmax=wgtpdfmax+ |
4984 | - # ( max(0.d0, |
4985 | - # xsecPDFr(nps)-xsecPDFr(0), |
4986 | - # xsecPDFr(nng)-xsecPDFr(0)) )**2 |
4987 | - enddo |
4988 | - wgtpdfmin=wgtcentral-sqrt(wgtpdfmin) |
4989 | - wgtpdfmax=wgtcentral+sqrt(wgtpdfmax) |
4990 | - |
4991 | -c Restore default PDFs |
4992 | - call InitPDF(izero) |
4993 | - |
4994 | - endif |
4995 | - |
4996 | - else ! kwgtinfo.eq.-5 |
4997 | - |
4998 | - call fill_wgt_info_from_rwgt_lines |
4999 | - if (do_rwgt_scale)call reweight_scale_ext(yfactR,yfactF) |
5000 | - if (do_rwgt_pdf) call reweight_pdf_ext |
Hi Rik,
This is a nice improvement. Here are my comments on the functionalities:
a) It would be nice to be able to define the list with a python syntax like
range(10)
[1,2,3]
[a for a in range(100) if a%2!=0]
This can simply be done with an 'eval' statement, and Olivier agreed to do it.
So I just wrote that here for reference.
b) The default entry and text for the parameter 'reweight_PDF' and 'reweight_scale' is not very clear, especially because in fact they should now read ('consider_ PDF_variation' and 'consider_ scale_variation ') but we cannot afford to change the name.
Also the stressing the fact that it should be a list *of booleans* should help.
So all in all, I simply suggest to change it by stressing 'booleans' and using the keyword 'variations' instead of 'dependence' which I think is clearer for most people (but I might be wrong).
True = reweight_scale ! Reweight to get scale variations using the scale_choice'
! rw_rscale and rw_fscale factors. Should be a list of booleans
! of length equal to that of the parameter 'dynamical_
! specifying which scales to include in the variation.
and similarly for 'reweight_PDF'.
Also, how can one pick several fixed scales? Is there no other way than modifying the code so as to add additional 'fake dynamical' scales which always return a constant one?
c) When using built-in pdfs, if I have a list defined for lhaid and reweight_PDF (with all reweight_PDF set to False) then the code crashes, which is bit annoying.
d) When doing a fixed order analysis, with two PDF sets and only the second of which has the PDF variations computed, then the plotting fails with:
RuntimeError : Error in LHAPDF: :PDFSet: :uncertainty. Input vector must contain values for all PDF members. /bugs.launchpad .net/madgraph5 valentin/ Documents/ Work/MG5/ improved_ scale_pdf_ handling/ PROCNLO_ loop_sm_ 0/run_06_ tag_1_debug. log'.
Please report this bug on https:/
More information is found in '/Users/
Please attach this file to your report.
d) Otherwise the various runs I did went through fine and I really love the summary printout.
It is very clean. So now that you seem to have streamlined the mapping of the lhaid to the pdfset name, would it be considerable to be able to input the pdfset name instead of its lhaid in the run_card? (just an idea, of course not worth it if not trivial to do).
e) In the context of the PY8 merging systematics branch we talked with Stefan and thought it would be nice to add the 'name' attribute to the XML tag 'weightid' which would dictate the name that this weight will have in the hepmc file (following v3 standards).
We could consider to take the opportunity of this branch to add this here. If you agree, then we should follow the ongoing unofficial convention on how to name the weights of different PDF and scales so that analysis tools like Rivets an other can directly parse it.
Finally, the plots look good, nice work. However, the problem is that I have myself been working quite a lot on histograms.py in the PY8 branch (I used it to automatically generate the DJR plots for different merging scales as part of the systematics study. Btw, I also m...