Closed idkakorin closed 1 year ago
Hi Igor: the transformation from Q2 to Q2_d = 1/(1+Q2/c), was done to flatten the differential cross-section by taking out the dipole form. It is easy to remove the transformation and the code would work. But what is the impact on efficiency? If it now becomes much slower, perhaps we want to keep it and fix what is wrong with the sampling envelope? But we need some assessment of CPU efficiency first. Please can you check how fast you can generate RES events w/ and w/o that transformation?
Hi Igor: the transformation from Q2 to Q2_d = 1/(1+Q2/c), was done to flatten the differential cross-section by taking out the dipole form. It is easy to remove the transformation and the code would work. But what is the impact on efficiency? If it now becomes much slower, perhaps we want to keep it and fix what is wrong with the sampling envelope? But we need some assessment of CPU efficiency first. Please can you check how fast you can generate RES events w/ and w/o that transformation?
Hi Costas! I understand your point about flattering, but straightforward comparison of previous version and proposed fix would not be quite correct, because in the previous version of code some of the events are accepted, although they should have been rejected. Anyway, such comparison shows, that without fix time/event: 0.00597427 s, with fix: 0.0499688 s.
Now, the maximum is searched in W, QD2 variables. We decided to get rid of envelope.
The test runs of the command:
time gevgen -p 14 -t 1000010010 -n 10000 -e 0.1,100 -f 1 --cross-sections out.xml --tune G00_00a_00_000 --event-generator-list RES
showed that it works faster with this option, see Presentation.pdf.
Fixing of the problem with
RESKinematicsGenerator
reported in issue #282 .I suggest getting rid of the variable
QD2
to avoid confusion with Jacobian, variable transformation and global maximum searching. The functiondouble genie::utils::kinematics::RESImportanceSamplingEnvelope(double * x, double * par)
is used only in RESKinematicsGenerator.cxx, therefore it should not cause problems anywhere else. All changes are trivial.