diff --git a/madgraph/iolibs/export_v4.py b/madgraph/iolibs/export_v4.py index d4b7d58a74..a9e7fe755c 100755 --- a/madgraph/iolibs/export_v4.py +++ b/madgraph/iolibs/export_v4.py @@ -6042,6 +6042,10 @@ def write_driver(self, writer, ncomb, n_grouped_proc, v5=True): else: replace_dict['secondparam']='' + replace_dict['DRIVER_EXTRA_HEADER'] = "" + replace_dict['DRIVER_EXTRA_INITIALISE'] = "" + replace_dict['DRIVER_EXTRA_FINALISE'] = "" + if writer: text = open(path).read() % replace_dict writer.write(text) diff --git a/madgraph/iolibs/template_files/madevent_driver.f b/madgraph/iolibs/template_files/madevent_driver.f index 6d30751420..e34e97b13d 100644 --- a/madgraph/iolibs/template_files/madevent_driver.f +++ b/madgraph/iolibs/template_files/madevent_driver.f @@ -77,12 +77,13 @@ Program DRIVER include 'coupl.inc' ! needs VECSIZE_MEMMAX (defined in vector.inc) INTEGER VECSIZE_USED DATA VECSIZE_USED/VECSIZE_MEMMAX/ ! can be changed at runtime - +%(DRIVER_EXTRA_HEADER)s C----- C BEGIN CODE C----- call cpu_time(t_before) CUMULATED_TIMING = t_before +%(DRIVER_EXTRA_INITIALISE)s c c Read process number c @@ -218,6 +219,7 @@ Program DRIVER rewind(lun) close(lun) +%(DRIVER_EXTRA_FINALISE)s end c $B$ get_user_params $B$ ! tag for MadWeight