24from simulation
import add_simulation
27b2.set_random_seed(1509)
37usePXDDataReduction =
True
40 usePXDDataReduction =
False
45 bkgFiles = glob.glob(
'/sw/belle2/bkg/*.root')
46if bkg ==
'std2GsmallBKG':
47 bkgFiles = glob.glob(
'/sw/belle2/bkg/*.root')
48 bkgFiles = bkgFiles + glob.glob(
'/sw/belle2/bkg.twoPhoton/*usual.root')
50 bkgFiles = glob.glob(
'/sw/belle2/bkg/*.root')
51 bkgFiles = bkgFiles + glob.glob(
'/sw/belle2/bkg.twoPhoton/*.root')
53print(
'background: ' + bkg)
54if(usePXDDataReduction):
55 print(
'simulating PXD Data Reduction')
57 print(
'NOT simulating PXD Data Reduction')
62input_filename =
'./' + release +
'/TV_data_' + release +
'_1509.root'
63output_filename =
'./' + release +
'/TV_sim_' + bkg +
'_' + roi +
'_' + release +
'.root'
67path = b2.create_path()
69progress = b2.register_module(
'Progress')
71root_output = b2.register_module(
'RootOutput')
72root_output.param(
'outputFileName', output_filename)
74root_input = b2.register_module(
'RootInput')
75root_input.param(
'inputFileName', input_filename)
77path.add_module(root_input)
78path.add_module(progress)
80add_simulation(path,
None, bkgFiles,
None, 1.0, usePXDDataReduction)
82path.add_module(root_output)