Page MenuHomeHEPForge

No OneTemporary

diff --git a/CMakeLists.txt b/CMakeLists.txt
index 106e4a9..ceebbd6 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -1,259 +1,263 @@
cmake_minimum_required(VERSION 3.1 FATAL_ERROR)
set(CMAKE_LEGACY_CYGWIN_WIN32 0)
set(CMAKE_EXPORT_COMPILE_COMMANDS ON)
project("HEJ" VERSION 2.0.3 LANGUAGES C CXX)
# Set a default build type if none was specified
set(default_build_type "Release")
if(NOT CMAKE_BUILD_TYPE AND NOT CMAKE_CONFIGURATION_TYPES)
message(STATUS "Setting build type to '${default_build_type}' as none was specified.")
set(CMAKE_BUILD_TYPE "${default_build_type}" CACHE
STRING "Choose the type of build." FORCE)
# Set the possible values of build type for cmake-gui
set_property(CACHE CMAKE_BUILD_TYPE PROPERTY STRINGS
"Debug" "Release" "MinSizeRel" "RelWithDebInfo")
endif()
## Flags for the compiler. No warning allowed.
if (CMAKE_COMPILER_IS_GNUCC OR CMAKE_COMPILER_IS_GNUCXX)
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wall -Wextra")
elseif (MSVC)
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} /W4 /WX /EHsc")
endif()
set(CMAKE_CXX_STANDARD_REQUIRED ON)
set(CMAKE_CXX_STANDARD 14)
## Create Version
set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} "${CMAKE_SOURCE_DIR}/cmake/Modules/")
# Get the latest abbreviated commit hash of the working branch
execute_process(
COMMAND git rev-parse HEAD
WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}
OUTPUT_VARIABLE PROJECT_GIT_REVISION
OUTPUT_STRIP_TRAILING_WHITESPACE
)
# Get the current working branch
execute_process(
COMMAND git rev-parse --abbrev-ref HEAD
WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}
OUTPUT_VARIABLE PROJECT_GIT_BRANCH
OUTPUT_STRIP_TRAILING_WHITESPACE
)
## target directories for install
set(INSTALL_INCLUDE_DIR_BASE include)
set(INSTALL_INCLUDE_DIR ${INSTALL_INCLUDE_DIR_BASE}/HEJ)
set(INSTALL_BIN_DIR bin)
set(INSTALL_LIB_DIR lib)
set(INSTALL_CONFIG_DIR lib/cmake/HEJ)
## Template files
configure_file( ${CMAKE_CURRENT_SOURCE_DIR}/cmake/Templates/Version.hh.in
${PROJECT_BINARY_DIR}/include/HEJ/Version.hh @ONLY )
configure_file( ${CMAKE_CURRENT_SOURCE_DIR}/cmake/Templates/HEJ-config.cc.in
${PROJECT_BINARY_DIR}/src/bin/HEJ-config.cc @ONLY )
# Generate CMake config file
include(CMakePackageConfigHelpers)
configure_package_config_file(
cmake/Templates/hej-config.cmake.in
${CMAKE_CURRENT_BINARY_DIR}/${INSTALL_CONFIG_DIR}/hej-config.cmake
INSTALL_DESTINATION ${INSTALL_CONFIG_DIR}
PATH_VARS INSTALL_INCLUDE_DIR_BASE INSTALL_LIB_DIR
)
write_basic_package_version_file(
${CMAKE_CURRENT_BINARY_DIR}/${INSTALL_CONFIG_DIR}/hej-config-version.cmake
COMPATIBILITY SameMajorVersion
)
install(
FILES ${CMAKE_CURRENT_BINARY_DIR}/${INSTALL_CONFIG_DIR}/hej-config.cmake
${CMAKE_CURRENT_BINARY_DIR}/${INSTALL_CONFIG_DIR}/hej-config-version.cmake
DESTINATION ${INSTALL_CONFIG_DIR})
## Add directories and find dependences
include_directories(${CMAKE_CURRENT_SOURCE_DIR}/include ${PROJECT_BINARY_DIR}/include)
find_package(fastjet REQUIRED)
include_directories(${fastjet_INCLUDE_PATH})
find_package(clhep 2.3 REQUIRED)
include_directories(${CLHEP_INCLUDE_PATH})
find_package(lhapdf REQUIRED)
include_directories(${lhapdf_INCLUDE_PATH})
## Amend unintuitive behaviour of FindBoost.cmake
## Priority of BOOST_ROOT over BOOSTROOT matches FindBoost.cmake
## at least for cmake 3.12
if(DEFINED BOOST_ROOT)
message("BOOST_ROOT set - only looking for Boost in ${BOOST_ROOT}")
set(Boost_NO_BOOST_CMAKE ON)
elseif(DEFINED BOOSTROOT)
message("BOOSTROOT set - only looking for Boost in ${BOOSTROOT}")
set(Boost_NO_BOOST_CMAKE ON)
endif()
find_package(Boost REQUIRED COMPONENTS iostreams)
include_directories(${Boost_INCLUDE_DIRS})
find_package(yaml-cpp)
include_directories(${YAML_CPP_INCLUDE_DIR})
find_package(HepMC 2)
if(${HepMC_FOUND})
message (STATUS "HepMC installation found: ${HepMC_INCLUDE_DIRS}")
set(
CMAKE_CXX_FLAGS
"${CMAKE_CXX_FLAGS} -DHEJ_BUILD_WITH_HepMC_VERSION=${HepMC_VERSION_MAJOR}"
)
include_directories(${HepMC_INCLUDE_DIRS})
find_package(rivet)
if(${rivet_FOUND})
include_directories(${rivet_INCLUDE_PATH})
set(
CMAKE_CXX_FLAGS
"${CMAKE_CXX_FLAGS} -DHEJ_BUILD_WITH_RIVET"
)
endif()
endif()
find_package(QCDloop 2)
if(${QCDloop_FOUND})
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -DHEJ_BUILD_WITH_QCDLOOP")
include_directories(SYSTEM ${QCDloop_INCLUDE_DIRS})
endif()
add_subdirectory(src)
## define executable
add_executable(HEJ src/bin/HEJ.cc)
## link libraries
target_link_libraries(HEJ hejlib)
add_executable(HEJ-config src/bin/HEJ-config.cc)
file(GLOB hej_headers ${CMAKE_CURRENT_SOURCE_DIR}/include/HEJ/*.hh ${PROJECT_BINARY_DIR}/include/HEJ/*.hh)
file(GLOB lhef_headers ${CMAKE_CURRENT_SOURCE_DIR}/include/LHEF/*.h)
install(FILES ${hej_headers} DESTINATION ${INSTALL_INCLUDE_DIR})
install(FILES ${lhef_headers} DESTINATION include/LHEF/)
install(TARGETS HEJ HEJ-config DESTINATION ${INSTALL_BIN_DIR})
## tests
enable_testing()
set(tst_dir "${CMAKE_CURRENT_SOURCE_DIR}/t")
add_executable(test_classify ${tst_dir}/test_classify.cc)
add_executable(test_psp ${tst_dir}/test_psp.cc)
add_executable(test_ME_generic ${tst_dir}/test_ME_generic.cc)
add_executable(check_res ${tst_dir}/check_res.cc)
add_executable(check_lhe ${tst_dir}/check_lhe.cc)
add_library(scales SHARED ${tst_dir}/scales.cc)
add_executable(test_scale_import ${tst_dir}/test_scale_import)
add_executable(test_descriptions ${tst_dir}/test_descriptions)
add_executable(test_scale_arithmetics ${tst_dir}/test_scale_arithmetics)
target_link_libraries(test_classify hejlib)
target_link_libraries(test_psp hejlib)
target_link_libraries(test_ME_generic hejlib)
target_link_libraries(check_res hejlib)
target_link_libraries(check_lhe hejlib)
target_link_libraries(test_scale_import hejlib)
target_link_libraries(test_descriptions hejlib)
target_link_libraries(test_scale_arithmetics hejlib)
## add tests
add_test(
NAME t_classify
COMMAND test_classify ${tst_dir}/classify.lhe.gz
)
add_test(
NAME t_psp
COMMAND test_psp ${tst_dir}/psp_gen.lhe.gz
)
set(tst_ME_data_dir "${tst_dir}/ME_data")
add_test(
NAME t_ME_j
COMMAND test_ME_generic ${tst_ME_data_dir}/config_mtinf.yml ${tst_ME_data_dir}/ME_jets.dat ${tst_ME_data_dir}/PSP_jets.lhe.gz
)
add_test(
NAME t_ME_h
COMMAND test_ME_generic ${tst_ME_data_dir}/config_mtinf.yml ${tst_ME_data_dir}/ME_h_mtinf.dat ${tst_ME_data_dir}/PSP_h.lhe.gz
)
# add_test(
# NAME t_ME_w
# COMMAND test_ME_generic ${tst_ME_data_dir}/config_w_ME.yml ${tst_ME_data_dir}/ME_w.dat ${tst_ME_data_dir}/PSP_w.lhe.gz
# )
+add_test(
+ NAME t_ME_w_FKL
+ COMMAND test_ME_generic ${tst_ME_data_dir}/config_w_ME.yml ${tst_ME_data_dir}/ME_w_FKL.dat ${tst_ME_data_dir}/PSP_w_FKL.lhe.gz
+ )
if(${QCDloop_FOUND})
add_test(
NAME t_ME_h_mt
COMMAND test_ME_generic ${tst_ME_data_dir}/config_mt.yml ${tst_ME_data_dir}/ME_h_mt.dat ${tst_ME_data_dir}/PSP_h.lhe.gz
)
add_test(
NAME t_ME_h_mtmb
COMMAND test_ME_generic ${tst_ME_data_dir}/config_mtmb.yml ${tst_ME_data_dir}/ME_h_mtmb.dat ${tst_ME_data_dir}/PSP_h.lhe.gz
)
endif()
add_test(
NAME t_2j
COMMAND check_res ${tst_dir}/2j.lhe.gz 3.49391e+07 419684
)
add_test(
NAME t_3j
COMMAND check_res ${tst_dir}/3j.lhe.gz 2.37902e+06 25746.6
)
add_test(
NAME t_4j
COMMAND check_res ${tst_dir}/4j.lhe.gz 603713 72822.6
)
add_test(
NAME t_h_3j
COMMAND check_res ${tst_dir}/h_3j.lhe.gz 0.821622 0.0220334
)
add_test(
NAME t_h_3j_uno
COMMAND check_res ${tst_dir}/h_3j_uno.lhe.gz 0.0261968 0.000341549 uno
)
if(${HepMC_FOUND})
file(READ "${tst_dir}/jet_config.yml" config)
file(WRITE "${tst_dir}/jet_config_withHepMC.yml" "${config} - tst.hepmc")
if(${rivet_FOUND})
file(READ "${tst_dir}/jet_config_withHepMC.yml" config)
file(WRITE "${tst_dir}/jet_config_withRivet.yml" "${config}\n\nanalysis:\n rivet: MC_XS\n output: tst")
add_test(
NAME t_main
COMMAND HEJ ${tst_dir}/jet_config_withRivet.yml ${tst_dir}/2j.lhe.gz
)
else()
add_test(
NAME t_main
COMMAND HEJ ${tst_dir}/jet_config_withHepMC.yml ${tst_dir}/2j.lhe.gz
)
endif()
if(${HepMC_VERSION_MAJOR} GREATER 2)
add_executable(check_hepmc ${tst_dir}/check_hepmc.cc)
target_link_libraries(check_hepmc hejlib)
add_test(
NAME t_hepmc
COMMAND check_hepmc tst.hepmc
)
endif()
else()
add_test(
NAME t_main
COMMAND HEJ ${tst_dir}/jet_config.yml ${tst_dir}/2j.lhe.gz
)
endif()
add_test(
NAME t_lhe
COMMAND check_lhe tst.lhe
)
add_test(
NAME t_scale_import
COMMAND test_scale_import ${tst_dir}/jet_config_with_import.yml
)
add_test(
NAME t_descriptions
COMMAND test_descriptions
)
add_test(
NAME t_scale_arithmetics
COMMAND test_scale_arithmetics ${tst_dir}/jet_config.yml ${tst_dir}/2j.lhe.gz
)
diff --git a/t/ME_data/ME_w_FKL.dat b/t/ME_data/ME_w_FKL.dat
new file mode 100644
index 0000000..3c21bd1
--- /dev/null
+++ b/t/ME_data/ME_w_FKL.dat
@@ -0,0 +1,556 @@
+1.66735e-10
+4.4041e-08
+5.92405e-10
+0.0366658
+3.02387e-05
+6.33019e-05
+1.3673e-05
+0.0181281
+0.0140049
+2.7364e-07
+1.42529e-06
+0.376058
+1.4039e-07
+0.000204353
+3.25009e-06
+0.0202204
+4.52458e-06
+0.577611
+0.00126865
+1.42403e-05
+5.69446e-05
+3.24538e-06
+6.95782e-06
+502.564
+0.5466
+5.6995e-08
+0.0172244
+4.88591e-06
+1.38707e-07
+3.05536e-07
+0.00398169
+1.53828e-09
+7.82136e-12
+0.000227506
+4.39617e-08
+0.00013258
+0.000308858
+1.19829e-09
+2.09184e-06
+4.61199e-10
+0.00033569
+444.624
+2.96405
+6.36854e-09
+4.08676e-07
+0.14296
+2.36192e-08
+0.000639599
+2.76895e-06
+0.00415682
+1.31852e-09
+0.0549343
+7.37083e-05
+1.55399
+1.27455e-07
+3.36237e-07
+3.20486e-10
+3.5427e-05
+3.09312e-08
+0.0143784
+4.62088e-07
+9.02783
+0.00219736
+1.57684e-09
+1.32025e-05
+1.21352e-09
+2.81855e-07
+0.000574464
+1.50161e-07
+0.00157949
+0.000365113
+1.00946e-05
+0.0132691
+1.66234e-07
+2.28424e-07
+0.000192614
+18453.2
+0.000166803
+2.09525e-06
+3.20392e-07
+2.31454e-05
+0.000354074
+0.037135
+0.000172935
+4543.48
+4.26989e-05
+462.744
+2.12671e-09
+0.000418861
+5.95467e-05
+109.695
+235.696
+5.95639e-10
+1.72486e-05
+2.91207e-08
+1.81559e-05
+0.000350347
+7.02993e-08
+0.0704984
+2.96942e-07
+7.6676e-11
+5.13603e-05
+2.97235e-06
+0.223145
+1.64837e-07
+2.89016e-13
+9.51596e-12
+0.00375317
+1.85032e-07
+2.34686e-05
+1.20398e-05
+7.04312e-06
+2.02827e-06
+0.00464863
+2.03636e-05
+1.04609
+0.00591302
+4.77803e-07
+2.01462e-06
+0.000182964
+0.0489411
+2.61445e-09
+0.000100035
+5148.58
+0.000216259
+0.000332495
+6.04945e-08
+8.57456e-05
+2.76748e-05
+1.25562e-12
+0.000422337
+0.00133835
+0.00744617
+1.14326
+1.43195e-08
+6.38635e-07
+0.00862448
+4.37711e-06
+0.212646
+4.61289e+06
+4.01648e-05
+1.0193e-10
+2.31501e-05
+1.15591e-08
+1.13292e-07
+6.22732e-06
+2.5339e-05
+5.253e-08
+0.0957011
+0.00346245
+0.00202415
+0.000809109
+9.25638e-08
+0.00377243
+0.0273365
+4.03002e-07
+3.29569e-08
+7.93097e-06
+3.40496e-08
+0.000230937
+1.81192e-11
+6.81293e-10
+3.40697e-05
+0.240183
+0.00378173
+109851
+6.14314e-07
+1.35922e-06
+3.41102e-11
+3.51399e-07
+0.000198309
+0.000188839
+6.76021e-08
+0.000284694
+1.43864e-08
+5.16049e-09
+5.62878e-05
+0.770015
+0.247726
+9.93266e-09
+3.18242e-07
+1.00451e-05
+3.30423e-05
+1.06448
+6.225e-07
+6.60516e-08
+1.17284e-05
+0.00509921
+1.99188e-06
+1.50062e-10
+2.80521e-07
+2.828e-06
+0.445898
+2.33741e-08
+0.0750609
+1.61982e-08
+2.38598e-06
+3.91605e-10
+0.00044492
+9.87935e-05
+6.33457e-06
+0.00212007
+1.7068e-05
+12800.8
+7.84114e-05
+3.56353e-06
+1.53868e-07
+0.000147522
+1.59291e-06
+0.0760704
+6.16233e-07
+0.0110517
+0.132904
+0.0208312
+2.65967e-08
+5.05612e-05
+0.00799967
+6.28914e-07
+3.67441e-07
+0.711692
+1.4769e-07
+0.00133689
+9.65703e-05
+0.000140625
+0.000165611
+1.4526e-10
+84.6939
+7.30804e-05
+4.34679e-05
+1.13212e-05
+9.76841e-07
+0.138946
+0.857284
+4.80432e-07
+159.45
+0.0037607
+0.000330063
+8.6496e-05
+0.969737
+0.0461401
+548.271
+3.43983e-07
+3.45997e-06
+1.404e-12
+1.60387e-05
+4.70059e-07
+4630.86
+8.43376e-05
+7.53079e-06
+1.23222e-12
+0.0482061
+7.35608
+3.0975e-05
+1.80607e-05
+6.0602e-06
+1.25394e-08
+1.04957e-06
+3.32049e-06
+5.35062e-07
+0.00359605
+7.3544e-08
+9.09049e-06
+1.36527e-10
+2.98454e-06
+2.66174e-05
+7395.92
+3.77381e-07
+1.82459e-07
+0.0035087
+3.15536e-07
+0.00029903
+4.47086e-08
+0.000322599
+3.19833e-05
+1.44715e-05
+2.91342e-07
+3.66301e-07
+4.57968e-05
+5.56722e-10
+6.5099e-07
+1.54889e-07
+0.000163301
+2.26083e-11
+0.00015639
+3.58445e-05
+4.53362e-07
+2.07853e-05
+0.000543815
+0.000193472
+5.55595e-05
+0.0003522
+2.36567e-05
+4.95004e-06
+5.22835
+1.45351e-05
+0.00108416
+0.00155746
+0.740537
+2.04926e-06
+6.74606e-07
+0.525897
+2.86106e-09
+0.00140433
+9.73885e-07
+7.87825e-07
+9.11382e-07
+1.03271e-05
+0.00819761
+9.34316e-07
+102.715
+3.12936e-06
+8.17265e-05
+0.793069
+0.0394783
+0.249998
+3.2951e-10
+3.14814e-05
+6.84633e-07
+4.12731e-08
+3.30826
+3.83301e-05
+5.17716e-11
+0.00863598
+4.86168e-13
+2.07733
+1.52121e-05
+0.00762508
+3.9995e-07
+1.20631e-07
+8.72061e-14
+0.167408
+0.0349983
+2.80134e-08
+0.000149104
+42.7578
+0.0174395
+0.000805168
+4.51894e-05
+1.13497e-08
+0.00223994
+0.327996
+2.51105e-06
+6.52328e-06
+0.00307739
+0.00010686
+0.0826528
+3.40586e-09
+4.443e-08
+3.13325e-09
+0.393115
+2.24245e-05
+0.514506
+0.012296
+2.91465e-08
+6.13021e-11
+0.0106812
+2.1283e-05
+0.219704
+0.000904437
+0.00613495
+4.52535e-07
+0.00248037
+0.00206347
+9.02615e-05
+1.5555e-07
+5.08439e-06
+8.87029e-05
+0.00398221
+6.00901e-08
+3.42807e-06
+6.36962e-06
+1.09107e-05
+5.67e-06
+1.39205
+4.60967e-06
+0.101108
+0.0930008
+4.45779e-09
+0.000216392
+8.08965e-13
+0.00669366
+0.31851
+1.95031e-09
+1.27845e-08
+1.75725
+6.02183e-06
+9.47245e-06
+2.73499e-09
+1.31829e-06
+2.70901e-06
+6541.91
+0.0432065
+3.53221e-07
+6.71928e-05
+0.787997
+0.000468341
+0.0260916
+8.38173e-07
+9.59311
+1.42948e-06
+3.57455e-07
+9.90402e-07
+3.97145
+0.0663521
+1.9818e-06
+0.000625738
+1.44948e-06
+1.71863e-06
+3.2594e-06
+0.413732
+5.49708e-09
+81359.3
+9.32927e-06
+9.07516e-08
+8.47019e-06
+529.796
+8.03296
+2.46034e-05
+4.02271e-05
+6.76255e-05
+1.28593
+0.000184522
+5.46581e-11
+0.0292004
+0.00286131
+2.53505e-05
+2.14022e-10
+0.0119781
+3.36826e-11
+2.26669e-07
+3.71746e-07
+1.63972e-09
+1.79883e-05
+1.12241e-06
+0.000786734
+3.75728e-11
+1.04631e-05
+1.83096e-06
+0.000908951
+1.19379e-08
+5.85447e-06
+1.6532e-08
+3.08531e-05
+5.15335e-09
+6.67385e-08
+0.000987984
+0.0218896
+0.000673661
+1.4376e-07
+0.00919708
+1.93858e-06
+3.72294e-05
+0.00374186
+81844.1
+2.98802e-06
+0.113867
+3.84423e-06
+7.78978e-06
+40.3067
+1.64835e-06
+3773.67
+4.4311e-12
+0.031312
+0.000274236
+5.74005e-10
+4.09009e-06
+0.00976802
+6.13682e-07
+1.89011e-06
+3.18096e-07
+6.37238e-06
+7.34926e-06
+1.05138e-11
+0.00014211
+0.435855
+1.14883e-06
+8.41324e-08
+1.65963e-07
+0.000258003
+0.000278053
+3.97598e-06
+0.00385072
+6.17263e-06
+4.28477e+09
+3.35054e-05
+5.38143e-05
+26.8569
+0.000212268
+4.56831e-07
+2.43236e-06
+0.00044186
+1.61801
+1.29384e-05
+7.09936e-05
+0.0632148
+2.28731e-06
+8.46878e-06
+3.02247e-06
+4.90988e-08
+1.56847e-11
+63.7539
+3.22618e-07
+7.88706e-05
+4.0831e-07
+2.56971e-05
+0.00368127
+3.40935e-05
+7.56007e-08
+5.57694e-09
+2.19208e-07
+0.241623
+1.2466e-07
+1.21792e-06
+2.99997e-06
+7.90484e-05
+44.0162
+7.27495e-11
+0.255535
+20.4483
+1.10093e-09
+0.799591
+2.4149e-05
+0.0275875
+0.523435
+1.05659e-06
+0.0372607
+2.63343e-08
+9.11403e-07
+0.000531948
+3.19487e-07
+1.22984e-11
+468.197
+1.06812e-09
+0.00768798
+1.39065e-05
+0.000886794
+1.76499e-10
+1.0843e-05
+0.00534105
+2.39915e-11
+4.19033e-05
+0.00318565
+8.05371
+5.87035e-10
+1.77471e-07
+78509.9
+15.3982
+6.79612e-07
+1.14968e-06
+0.0236821
+8.65278e-05
+0.317341
+0.0186315
+1.09832e-10
+5.45839e-10
+5.49319e-09
diff --git a/t/ME_data/PSP_w_FKL.lhe.gz b/t/ME_data/PSP_w_FKL.lhe.gz
new file mode 100644
index 0000000..52958d2
Binary files /dev/null and b/t/ME_data/PSP_w_FKL.lhe.gz differ

File Metadata

Mime Type
text/x-diff
Expires
Mon, Jan 20, 10:24 PM (1 d, 10 h)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
4242626
Default Alt Text
(15 KB)

Event Timeline