Link to repository¶
Building HSN generator¶
Start by building uboonecode and larsim. At the moment, the suggested versions are:
--- uboonecode ---
Gen, G4, Detsim: uboonecode v06_26_01 -q e10:prof
Reco: uboonecode v06_26_01_08 -q e10:prof
--- larsim ---
Feature branch: larsim feature/sdporzio_hsngen_prodRelease_v06_26_01.
You can clone both as follows:
mrb g -t v06_26_01 uboonecode mrb g -b feature/sdporzio_hsngen_prodRelease_v06_26_01 larsim
After you have built both, you can test whether the generator works by running:
lar -c prodhsn.fcl
You can copy a version of prodhsn.fcl and change parameters such as mass and decay channel.
The available parameters are as follows:
SterileMass: 0.300 DecayChannel: 2 FluxFile: "/pnfs/uboone/persistent/users/sporzio/HeavySterileNeutrinos/FluxFiles/sterileFlux_m0.300.dat" Distance: 470. GlobalTimeOffset: 3125. BeamWindow: 1600. BoundariesX: [10,246.35] BoundariesY: [-105.53,107.47] BoundariesZ: [10.1,1026.8]
The sterile mass is in GeV. The decay channel takes a code depending on the selected channels. Code are available here:
0: 3-body (nu e e) 1: Isotropic 2-body e pi 2: Isotropic 2-body mu pi 3: Isotropic 2-body nu Pi0 4: Isotropic 2-body nu gamma 5: 3-body (nu mu mu) 6: 3-body (nu mu e)
(mu pi and e pi channels available only, at this time).
Pre-generated flux files are available at this path:
There's 500 files, ranging HSN masses from 0 to 0.490 GeV in steps of 1 MeV.
It's extremely important that the SterileMass parameter matches the correct FluxFile.
E.g.: If you want to generate 420 MeV neutrinos, your parameters will have to be as follows:
... SterileMass: 0.420 FluxFile: "/pnfs/uboone/persistent/users/sporzio/HeavySterileNeutrinos/FluxFiles/sterileFlux_m0.420.dat" ...
For generation on the grid, flux files must be handled differently. In that case, we'll have project.py copy the file directly from persistent and the .fcl file will just access it in the same directory on the grid.
E.g. if I want to generate 0.380 GeV HSN on the grid, I will set the
<jobsub>-f pathtofile</jobsub> flag (which will copy a file to the grid) on the xml file as follows:
<stage name="sim"> <fcl>pathToUploadDir/myProdhsn.fcl</fcl> <fcl>standard_g4_uboone.fcl</fcl> <fcl>standard_detsim_uboone.fcl</fcl> <numjobs>100</numjobs> <outdir>&data_dir;/sim</outdir> <workdir>&work_dir;/sim</workdir> <logdir>&log_dir;/sim</logdir> <jobsub>-f /pnfs/uboone/persistent/users/sporzio/HeavySterileNeutrinos/FluxFiles/sterileFlux_m0.380.dat </jobsub> </stage>
Since the flux file is now directly copied on the same directory where myProdhsn.fcl is executed, the fcl will need to contain only the name of the file (with no path):