Skip to content

Commit

Permalink
[gpucpp] regenerate all processes - this completes the add-ons to PR #…
Browse files Browse the repository at this point in the history
  • Loading branch information
valassi committed Aug 31, 2024
1 parent 7e69c82 commit 807f481
Show file tree
Hide file tree
Showing 64 changed files with 512 additions and 691 deletions.
34 changes: 15 additions & 19 deletions epochX/cudacpp/ee_mumu.mad/CODEGEN_mad_ee_mumu_log.txt
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ generate e+ e- > mu+ mu-
No model currently active, so we import the Standard Model
INFO: load particles
INFO: load vertices
DEBUG: model prefixing takes 0.005307912826538086 
DEBUG: model prefixing takes 0.005508899688720703 
INFO: Restrict model sm with file models/sm/restrict_default.dat .
DEBUG: Simplifying conditional expressions 
DEBUG: remove interactions: u s w+ at order: QED=1 
Expand Down Expand Up @@ -177,7 +177,6 @@ INFO: Generating Helas calls for process: e+ e- > mu+ mu- WEIGHTED<=4 @1
INFO: Processing color information for process: e+ e- > mu+ mu- @1
INFO: Creating files in directory P1_epem_mupmum
DEBUG: kwargs[prefix] = 0 [model_handling.py at line 1152] 
DEBUG: process_exporter_cpp =  <PLUGIN.CUDACPP_OUTPUT.model_handling.PLUGIN_OneProcessExporter object at 0x7f09ed66e490> [export_v4.py at line 6261] 
INFO: Creating files in directory .
FileWriter <class 'PLUGIN.CUDACPP_OUTPUT.model_handling.PLUGIN_CPPWriter'> for ././CPPProcess.h
FileWriter <class 'PLUGIN.CUDACPP_OUTPUT.model_handling.PLUGIN_CPPWriter'> for ././CPPProcess.cc
Expand All @@ -186,30 +185,30 @@ INFO: Created files CPPProcess.h and CPPProcess.cc in directory ./.
DEBUG: config_map =  [1, 2] [export_cpp.py at line 711] 
DEBUG: subproc_number =  0 [export_cpp.py at line 712] 
DEBUG: Done [export_cpp.py at line 713] 
DEBUG: vector, subproc_group,self.opt['vector_size'] =  False True 32 [export_v4.py at line 1871] 
DEBUG: vector, subproc_group,self.opt['vector_size'] =  False True 32 [export_v4.py at line 1871] 
DEBUG: vector, subproc_group,self.opt['vector_size'] =  32 True 32 [export_v4.py at line 1871] 
DEBUG: vector, subproc_group,self.opt['vector_size'] =  False True 32 [export_v4.py at line 1877] 
DEBUG: vector, subproc_group,self.opt['vector_size'] =  False True 32 [export_v4.py at line 1877] 
DEBUG: vector, subproc_group,self.opt['vector_size'] =  32 True 32 [export_v4.py at line 1877] 
WARNING: vector code for lepton pdf not implemented. We removed the option to run dressed lepton 
DEBUG: vector, subproc_group,self.opt['vector_size'] =  32 True 32 [export_v4.py at line 1871] 
DEBUG: vector, subproc_group,self.opt['vector_size'] =  32 True 32 [export_v4.py at line 1877] 
INFO: Generating Feynman diagrams for Process: e+ e- > mu+ mu- WEIGHTED<=4 @1
INFO: Finding symmetric diagrams for subprocess group epem_mupmum
DEBUG: os.getcwd() =  /data/avalassi/GPU2023/madgraph4gpuX/MG5aMC/TMPOUT/CODEGEN_mad_ee_mumu/SubProcesses/P1_epem_mupmum [export_v4.py at line 6438] 
DEBUG: os.getcwd() =  /data/avalassi/GPU2023/madgraph4gpuX/MG5aMC/TMPOUT/CODEGEN_mad_ee_mumu/SubProcesses/P1_epem_mupmum [export_v4.py at line 6443] 
DEBUG: len(subproc_diagrams_for_config) =  2 [model_handling.py at line 1520] 
DEBUG: iconfig_to_diag =  {1: 1, 2: 2} [model_handling.py at line 1544] 
DEBUG: diag_to_iconfig =  {1: 1, 2: 2} [model_handling.py at line 1545] 
Generated helas calls for 1 subprocesses (2 diagrams) in 0.004 s
Wrote files for 8 helas calls in 0.112 s
Wrote files for 8 helas calls in 0.107 s
ALOHA: aloha starts to compute helicity amplitudes
ALOHA: aloha creates FFV1 routines
ALOHA: aloha creates FFV2 routines
ALOHA: aloha creates FFV4 routines
ALOHA: aloha creates 3 routines in 0.198 s
ALOHA: aloha creates 3 routines in 0.204 s
ALOHA: aloha starts to compute helicity amplitudes
ALOHA: aloha creates FFV1 routines
ALOHA: aloha creates FFV2 routines
ALOHA: aloha creates FFV4 routines
ALOHA: aloha creates FFV2_4 routines
ALOHA: aloha creates 7 routines in 0.253 s
ALOHA: aloha creates 7 routines in 0.258 s
<class 'aloha.create_aloha.AbstractRoutine'> FFV1
<class 'aloha.create_aloha.AbstractRoutine'> FFV1
<class 'aloha.create_aloha.AbstractRoutine'> FFV2
Expand All @@ -235,27 +234,24 @@ INFO: Generate jpeg diagrams
INFO: Generate web pages
DEBUG: cd /data/avalassi/GPU2023/madgraph4gpuX/MG5aMC/TMPOUT/CODEGEN_mad_ee_mumu; patch -p4 -i /data/avalassi/GPU2023/madgraph4gpuX/epochX/cudacpp/CODEGEN/PLUGIN/CUDACPP_SA_OUTPUT/MG5aMC_patches/PROD/patch.common
patching file Source/genps.inc
patching file Source/makefile
patching file SubProcesses/makefile
DEBUG: cd /data/avalassi/GPU2023/madgraph4gpuX/MG5aMC/TMPOUT/CODEGEN_mad_ee_mumu/SubProcesses/P1_epem_mupmum; patch -p6 -i /data/avalassi/GPU2023/madgraph4gpuX/epochX/cudacpp/CODEGEN/PLUGIN/CUDACPP_SA_OUTPUT/MG5aMC_patches/PROD/patch.P1
patching file auto_dsig1.f
Hunk #1 succeeded at 496 (offset 12 lines).
patching file driver.f
patching file matrix1.f
Hunk #3 succeeded at 230 (offset 9 lines).
Hunk #4 succeeded at 267 (offset 18 lines).
Hunk #5 succeeded at 312 (offset 18 lines).
DEBUG: p.returncode =  0 [output.py at line 242] 
Hunk #2 succeeded at 229 (offset 9 lines).
DEBUG: p.returncode =  0 [output.py at line 255] 
Output to directory /data/avalassi/GPU2023/madgraph4gpuX/MG5aMC/TMPOUT/CODEGEN_mad_ee_mumu done.
Type "launch" to generate events from this process, or see
/data/avalassi/GPU2023/madgraph4gpuX/MG5aMC/TMPOUT/CODEGEN_mad_ee_mumu/README
Run "open index.html" to see more information about this process.
quit

real 0m2.067s
user 0m1.807s
sys 0m0.251s
Code generation completed in 2 seconds
real 0m2.192s
user 0m1.817s
sys 0m0.264s
Code generation completed in 3 seconds
************************************************************
* *
* W E L C O M E to *
Expand Down
5 changes: 3 additions & 2 deletions epochX/cudacpp/ee_mumu.mad/Source/MODEL/makefile
Original file line number Diff line number Diff line change
Expand Up @@ -41,10 +41,11 @@ $(LIBDIR)$(LIBRARY): $(MODEL)
clean:
$(RM) *.o $(LIBDIR)$(LIBRARY)

couplings.f: ../maxparticles.inc ../run.inc
couplings.o: ../maxparticles.inc ../run.inc ../vector.inc
couplings2.o: ../vector.inc

../run.inc:
touch ../run.inc

../maxparticles.inc:
touch ../maxparticles.inc
touch ../maxparticles.inc
17 changes: 7 additions & 10 deletions epochX/cudacpp/ee_mumu.mad/Source/makefile
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ $(LIBDIR)libcernlib.$(libext): CERNLIB
$(LIBDIR)libbias.$(libext): BIAS/dummy
cd BIAS/dummy; make; cd ../../

$(LIBDIR)libmodel.$(libext): MODEL param_card.inc
$(LIBDIR)libmodel.$(libext): MODEL param_card.inc vector.inc
cd MODEL; make
param_card.inc: ../Cards/param_card.dat
../bin/madevent treatcards param
Expand All @@ -72,15 +72,14 @@ $(BINDIR)gensudgrid: $(GENSUDGRID) $(LIBDIR)libpdf.$(libext) $(LIBDIR)libgammaUP

# Dependencies

dsample.o: DiscreteSampler.o dsample.f genps.inc StringCast.o
dsample.o: DiscreteSampler.o dsample.f genps.inc StringCast.o vector.inc
DiscreteSampler.o: StringCast.o
invarients.o: invarients.f genps.inc
setrun.o: setrun.f nexternal.inc leshouche.inc genps.inc
gen_ximprove.o: gen_ximprove.f run_config.inc run_card.inc
gen_ximprove.o: gen_ximprove.f run_config.inc run_card.inc
#combine_events.o: combine_events.f run_config.inc run_card.inc
combine_runs.o: combine_runs.f run_config.inc run_card.inc
select_events.o: select_events.f run_config.inc
setrun.o: setrun.f nexternal.inc leshouche.inc run_card.inc run_config.inc
setrun.o: setrun.f nexternal.inc leshouche.inc run_card.inc run_config.inc genps.inc vector.inc
rw_events.o: rw_events.f run_config.inc

run_card.inc: ../Cards/run_card.dat
Expand Down Expand Up @@ -120,7 +119,7 @@ $(LIBDIR)libiregi.a: $(IREGIDIR)
cd $(IREGIDIR); make
ln -sf ../Source/$(IREGIDIR)libiregi.a $(LIBDIR)libiregi.a

cleanSource:
cleanSource: # Clean builds: fortran in this Source
$(RM) *.o $(LIBRARIES) $(BINARIES)
cd PDF; make clean; cd ..
cd PDF/gammaUPC; make clean; cd ../../
Expand All @@ -133,10 +132,8 @@ cleanSource:
if [ -d $(CUTTOOLSDIR) ]; then cd $(CUTTOOLSDIR); make clean; cd ..; fi
if [ -d $(IREGIDIR) ]; then cd $(IREGIDIR); make clean; cd ..; fi

clean: cleanSource
clean: cleanSource # Clean builds: fortran in this Source and in all P*
for i in `ls -d ../SubProcesses/P*`; do cd $$i; make clean; cd -; done;

cleanavx:
for i in `ls -d ../SubProcesses/P*`; do cd $$i; make cleanavxs; cd -; done;
cleanall: cleanSource # THIS IS THE ONE
cleanall: cleanSource # Clean builds: fortran in this Source and in all P*; cudacpp for all AVX in all P* and in src
for i in `ls -d ../SubProcesses/P*`; do cd $$i; make cleanavxs; cd -; done;
Binary file not shown.
5 changes: 0 additions & 5 deletions epochX/cudacpp/ee_mumu.mad/bin/internal/banner.py
Original file line number Diff line number Diff line change
Expand Up @@ -3157,7 +3157,6 @@ def get_value_from_include(self, path, list_of_params, output_dir):
if path does not exists return the current value in self for all parameter"""

#WARNING DOES NOT HANDLE LIST/DICT so far

# handle case where file is missing
if not os.path.exists(pjoin(output_dir,path)):
misc.sprint("include file not existing", pjoin(output_dir,path))
Expand All @@ -3166,13 +3165,9 @@ def get_value_from_include(self, path, list_of_params, output_dir):
with open(pjoin(output_dir,path), 'r') as fsock:
text = fsock.read()

for name in list_of_params:
misc.sprint(name, name in self.fortran_name)
misc.sprint(self.fortran_name[name] if name in self.fortran_name[name] else name)
to_track = [self.fortran_name[name] if name in self.fortran_name else name for name in list_of_params]
pattern = re.compile(r"\(?(%(names)s)\s?=\s?([^)]*)\)?" % {'names':'|'.join(to_track)}, re.I)
out = dict(pattern.findall(text))
misc.sprint(out)
for name in list_of_params:
if name in self.fortran_name:
value = out[self.fortran_name[name]]
Expand Down
4 changes: 2 additions & 2 deletions epochX/cudacpp/ee_mumu.mad/bin/internal/launch_plugin.py
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ def reset_simd(self, old_value, new_value, name):
# code can handle the new size -> do not recompile
return
Sourcedir = pjoin(os.path.dirname(os.path.dirname(self.path)), 'Source')
subprocess.call(['make', 'cleanavx'], cwd=Sourcedir, stdout=subprocess.DEVNULL, stderr=subprocess.DEVNULL)
subprocess.call(['make', 'cleanall'], cwd=Sourcedir, stdout=subprocess.DEVNULL, stderr=subprocess.DEVNULL)

def reset_makeopts(self, old_value, new_value, name):
if not hasattr(self, 'path'):
Expand All @@ -78,7 +78,7 @@ def reset_makeopts(self, old_value, new_value, name):
else:
raise Exception
Sourcedir = pjoin(os.path.dirname(os.path.dirname(self.path)), 'Source')
subprocess.call(['make', 'cleanavx'], cwd=Sourcedir, stdout=subprocess.DEVNULL, stderr=subprocess.DEVNULL)
subprocess.call(['make', 'cleanall'], cwd=Sourcedir, stdout=subprocess.DEVNULL, stderr=subprocess.DEVNULL)

def plugin_input(self, finput):
return
Expand Down
24 changes: 12 additions & 12 deletions epochX/cudacpp/ee_mumu.sa/CODEGEN_cudacpp_ee_mumu_log.txt
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ generate e+ e- > mu+ mu-
No model currently active, so we import the Standard Model
INFO: load particles
INFO: load vertices
DEBUG: model prefixing takes 0.005346059799194336 
DEBUG: model prefixing takes 0.005733013153076172 
INFO: Restrict model sm with file models/sm/restrict_default.dat .
DEBUG: Simplifying conditional expressions 
DEBUG: remove interactions: u s w+ at order: QED=1 
Expand Down Expand Up @@ -154,7 +154,7 @@ INFO: Checking for minimal orders which gives processes.
INFO: Please specify coupling orders to bypass this step.
INFO: Trying process: e+ e- > mu+ mu- WEIGHTED<=4 @1
INFO: Process has 2 diagrams
1 processes with 2 diagrams generated in 0.004 s
1 processes with 2 diagrams generated in 0.005 s
Total: 1 processes with 2 diagrams
output standalone_cudacpp ../TMPOUT/CODEGEN_cudacpp_ee_mumu
Load PLUGIN.CUDACPP_OUTPUT
Expand All @@ -168,22 +168,22 @@ INFO: Creating subdirectories in directory /data/avalassi/GPU2023/madgraph4gpuX/
INFO: Organizing processes into subprocess groups
INFO: Generating Helas calls for process: e+ e- > mu+ mu- WEIGHTED<=4 @1
INFO: Processing color information for process: e+ e- > mu+ mu- @1
DEBUG: Entering PLUGIN_ProcessExporter.generate_subprocess_directory (create the directory) [output.py at line 196] 
DEBUG: type(subproc_group)=<class 'madgraph.core.helas_objects.HelasMatrixElement'> [output.py at line 197] 
DEBUG: type(fortran_model)=<class 'PLUGIN.CUDACPP_OUTPUT.model_handling.PLUGIN_GPUFOHelasCallWriter'> [output.py at line 198] 
DEBUG: type(me)=<class 'int'> me=0 [output.py at line 199] 
DEBUG: "need to link", self.to_link_in_P =  need to link ['nvtx.h', 'timer.h', 'timermap.h', 'ompnumthreads.h', 'GpuRuntime.h', 'GpuAbstraction.h', 'MemoryAccessHelpers.h', 'MemoryAccessVectors.h', 'MemoryAccessMatrixElements.h', 'MemoryAccessMomenta.h', 'MemoryAccessRandomNumbers.h', 'MemoryAccessWeights.h', 'MemoryAccessAmplitudes.h', 'MemoryAccessWavefunctions.h', 'MemoryAccessGs.h', 'MemoryAccessCouplingsFixed.h', 'MemoryAccessNumerators.h', 'MemoryAccessDenominators.h', 'EventStatistics.h', 'CommonRandomNumbers.h', 'CrossSectionKernels.cc', 'CrossSectionKernels.h', 'MatrixElementKernels.cc', 'MatrixElementKernels.h', 'RamboSamplingKernels.cc', 'RamboSamplingKernels.h', 'RandomNumberKernels.h', 'CommonRandomNumberKernel.cc', 'CurandRandomNumberKernel.cc', 'HiprandRandomNumberKernel.cc', 'Bridge.h', 'BridgeKernels.cc', 'BridgeKernels.h', 'fbridge.cc', 'fbridge.inc', 'fsampler.cc', 'fsampler.inc', 'MadgraphTest.h', 'runTest.cc', 'testmisc.cc', 'testxxx_cc_ref.txt', 'valgrind.h', 'cudacpp.mk', 'testxxx.cc', 'MemoryBuffers.h', 'MemoryAccessCouplings.h', 'perf.py', 'profile.sh'] [output.py at line 200] 
DEBUG: Entering PLUGIN_ProcessExporter.generate_subprocess_directory (create the directory) [output.py at line 209] 
DEBUG: type(subproc_group)=<class 'madgraph.core.helas_objects.HelasMatrixElement'> [output.py at line 210] 
DEBUG: type(fortran_model)=<class 'PLUGIN.CUDACPP_OUTPUT.model_handling.PLUGIN_GPUFOHelasCallWriter'> [output.py at line 211] 
DEBUG: type(me)=<class 'int'> me=0 [output.py at line 212] 
DEBUG: "need to link", self.to_link_in_P =  need to link ['nvtx.h', 'timer.h', 'timermap.h', 'ompnumthreads.h', 'GpuRuntime.h', 'GpuAbstraction.h', 'MemoryAccessHelpers.h', 'MemoryAccessVectors.h', 'MemoryAccessMatrixElements.h', 'MemoryAccessMomenta.h', 'MemoryAccessRandomNumbers.h', 'MemoryAccessWeights.h', 'MemoryAccessAmplitudes.h', 'MemoryAccessWavefunctions.h', 'MemoryAccessGs.h', 'MemoryAccessCouplingsFixed.h', 'MemoryAccessNumerators.h', 'MemoryAccessDenominators.h', 'EventStatistics.h', 'CommonRandomNumbers.h', 'CrossSectionKernels.cc', 'CrossSectionKernels.h', 'MatrixElementKernels.cc', 'MatrixElementKernels.h', 'RamboSamplingKernels.cc', 'RamboSamplingKernels.h', 'RandomNumberKernels.h', 'CommonRandomNumberKernel.cc', 'CurandRandomNumberKernel.cc', 'HiprandRandomNumberKernel.cc', 'Bridge.h', 'BridgeKernels.cc', 'BridgeKernels.h', 'fbridge.cc', 'fbridge.inc', 'fsampler.cc', 'fsampler.inc', 'MadgraphTest.h', 'runTest.cc', 'testmisc.cc', 'testxxx_cc_ref.txt', 'valgrind.h', 'cudacpp.mk', 'testxxx.cc', 'MemoryBuffers.h', 'MemoryAccessCouplings.h', 'perf.py', 'profile.sh'] [output.py at line 213] 
INFO: Creating files in directory /data/avalassi/GPU2023/madgraph4gpuX/MG5aMC/TMPOUT/CODEGEN_cudacpp_ee_mumu/SubProcesses/P1_Sigma_sm_epem_mupmum
FileWriter <class 'PLUGIN.CUDACPP_OUTPUT.model_handling.PLUGIN_CPPWriter'> for /data/avalassi/GPU2023/madgraph4gpuX/MG5aMC/TMPOUT/CODEGEN_cudacpp_ee_mumu/SubProcesses/P1_Sigma_sm_epem_mupmum/./CPPProcess.h
FileWriter <class 'PLUGIN.CUDACPP_OUTPUT.model_handling.PLUGIN_CPPWriter'> for /data/avalassi/GPU2023/madgraph4gpuX/MG5aMC/TMPOUT/CODEGEN_cudacpp_ee_mumu/SubProcesses/P1_Sigma_sm_epem_mupmum/./CPPProcess.cc
INFO: Created files CPPProcess.h and CPPProcess.cc in directory /data/avalassi/GPU2023/madgraph4gpuX/MG5aMC/TMPOUT/CODEGEN_cudacpp_ee_mumu/SubProcesses/P1_Sigma_sm_epem_mupmum/.
Generated helas calls for 1 subprocesses (2 diagrams) in 0.003 s
Generated helas calls for 1 subprocesses (2 diagrams) in 0.004 s
ALOHA: aloha starts to compute helicity amplitudes
ALOHA: aloha creates FFV1 routines
ALOHA: aloha creates FFV2 routines
ALOHA: aloha creates FFV4 routines
ALOHA: aloha creates FFV2_4 routines
ALOHA: aloha creates 4 routines in 0.264 s
ALOHA: aloha creates 4 routines in 0.273 s
<class 'aloha.create_aloha.AbstractRoutine'> FFV1
<class 'aloha.create_aloha.AbstractRoutine'> FFV1
<class 'aloha.create_aloha.AbstractRoutine'> FFV2
Expand All @@ -202,7 +202,7 @@ INFO: Created files Parameters_sm.h and Parameters_sm.cc in directory
INFO: /data/avalassi/GPU2023/madgraph4gpuX/MG5aMC/TMPOUT/CODEGEN_cudacpp_ee_mumu/src/. and /data/avalassi/GPU2023/madgraph4gpuX/MG5aMC/TMPOUT/CODEGEN_cudacpp_ee_mumu/src/.
quit

real 0m0.647s
user 0m0.592s
sys 0m0.048s
real 0m0.693s
user 0m0.599s
sys 0m0.058s
Code generation completed in 1 seconds
12 changes: 6 additions & 6 deletions epochX/cudacpp/gg_tt.mad/CODEGEN_mad_gg_tt_log.txt
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ generate g g > t t~
No model currently active, so we import the Standard Model
INFO: load particles
INFO: load vertices
DEBUG: model prefixing takes 0.005420207977294922 
DEBUG: model prefixing takes 0.005517721176147461 
INFO: Restrict model sm with file models/sm/restrict_default.dat .
DEBUG: Simplifying conditional expressions 
DEBUG: remove interactions: u s w+ at order: QED=1 
Expand Down Expand Up @@ -155,7 +155,7 @@ INFO: Please specify coupling orders to bypass this step.
INFO: Trying coupling order WEIGHTED<=2: WEIGTHED IS QCD+2*QED
INFO: Trying process: g g > t t~ WEIGHTED<=2 @1
INFO: Process has 3 diagrams
1 processes with 3 diagrams generated in 0.008 s
1 processes with 3 diagrams generated in 0.009 s
Total: 1 processes with 3 diagrams
output madevent_simd ../TMPOUT/CODEGEN_mad_gg_tt --hel_recycling=False --vector_size=32
Load PLUGIN.CUDACPP_OUTPUT
Expand Down Expand Up @@ -201,7 +201,7 @@ Wrote files for 10 helas calls in 0.109 s
ALOHA: aloha starts to compute helicity amplitudes
ALOHA: aloha creates VVV1 set of routines with options: P0
ALOHA: aloha creates FFV1 routines
ALOHA: aloha creates 2 routines in 0.147 s
ALOHA: aloha creates 2 routines in 0.145 s
ALOHA: aloha starts to compute helicity amplitudes
ALOHA: aloha creates VVV1 set of routines with options: P0
ALOHA: aloha creates FFV1 routines
Expand Down Expand Up @@ -239,9 +239,9 @@ Type "launch" to generate events from this process, or see
Run "open index.html" to see more information about this process.
quit

real 0m1.930s
user 0m1.674s
sys 0m0.247s
real 0m1.916s
user 0m1.645s
sys 0m0.273s
Code generation completed in 2 seconds
************************************************************
* *
Expand Down
Loading

0 comments on commit 807f481

Please sign in to comment.