Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
29 commits
Select commit Hold shift + click to select a range
d49bef6
add histo structure
jackaraz Oct 29, 2025
76f44a4
initialise multiweight
jackaraz Oct 29, 2025
678a657
tmp bugfix
jackaraz Oct 29, 2025
760a359
bugfix
jackaraz Oct 29, 2025
95a85e7
update
jackaraz Oct 29, 2025
80a308e
update setup
jackaraz Oct 30, 2025
754d4e4
bugfix
jackaraz Oct 30, 2025
8d95e0f
Merge branch 'multiweight-light' of https://github.com/MadAnalysis/ma…
jackaraz Oct 30, 2025
6fe7d46
Merge branch 'substructure' into multiweight-light
jackaraz Nov 5, 2025
b511c0a
Merge branch 'substructure' into multiweight-light
jackaraz Nov 10, 2025
0a12237
update delphes recast
jackaraz Nov 17, 2025
34b093d
Merge branch 'substructure' into multiweight-light
jackaraz Nov 17, 2025
ba4b147
improve formatting
jackaraz Nov 17, 2025
dbdae6e
minor bugfixes
jackaraz Nov 17, 2025
6f61970
add a tester
jackaraz Nov 17, 2025
a19ba06
add documentation
jackaraz Nov 18, 2025
9ec94d8
extend tests
jackaraz Nov 18, 2025
996a695
convert weight datastructure from map to vector
jackaraz Nov 19, 2025
02f730e
additional operators
jackaraz Nov 19, 2025
e140bed
update
jackaraz Nov 19, 2025
97884cf
update
jackaraz Nov 19, 2025
b7984a2
Merge branch 'substructure' into multiweight-light
jackaraz Nov 21, 2025
499a292
fix delphes exe in linux
jackaraz Nov 21, 2025
9144900
dont check size if not included
jackaraz Nov 28, 2025
9dfdf0b
simplify
jackaraz Nov 28, 2025
bb20ea5
warning -> debug
jackaraz Nov 28, 2025
e10ce21
modify the pad installation
jackaraz Dec 4, 2025
fbecc27
output fix
jackaraz Dec 4, 2025
76af3f8
fix histo freq initialisation
jackaraz Dec 12, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 4 additions & 2 deletions madanalysis/IOinterface/job_writer.py
Original file line number Diff line number Diff line change
Expand Up @@ -676,8 +676,9 @@ def CreateMainFct(self, file, analysisName, outputName):
file.write("\n\n /// Setting the random seed\n")
file.write(f" RANDOM->SetSeed({self.main.random_seed});\n\n")

# Add default hadrons and invisible particles for Reco mode
if self.main.mode == MA5RunningType.RECO:
# Add default hadrons and invisible particles for RECO and HADRON mode
# The invisible container may also be changed when runnign the code in HADRON mode.
if self.main.mode in [MA5RunningType.RECO, MA5RunningType.HADRON]:
file.write("\n // Initializing PhysicsService for MC\n")
file.write(" PHYSICS->mcConfig().Reset();\n")
file.write(' // definition of the multiparticle "hadronic"\n')
Expand Down Expand Up @@ -735,6 +736,7 @@ def CreateMainFct(self, file, analysisName, outputName):
file.write(" fastsim1->Execute(mySample,myEvent);\n")
elif self.main.fastsim.package == "delphesMA5tune":
file.write(" fastsim1->Execute(mySample,myEvent);\n")
file.write(" manager.PrepareForExecution(mySample, myEvent);\n")
file.write(" if (!analyzer1->Execute(mySample,myEvent)) continue;\n")
if self.output != "" and not self.output.lower().endswith("root"):
file.write(" writer1->WriteEvent(myEvent,mySample);\n")
Expand Down
64 changes: 25 additions & 39 deletions madanalysis/install/install_fastjet.py
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,8 @@

from madanalysis.install.install_service import InstallService

log = logging.getLogger("MA5")


class InstallFastjet:
def __init__(self, main):
Expand All @@ -47,14 +49,10 @@ def __init__(self, main):

def Detect(self):
if not os.path.isdir(self.toolsdir):
logging.getLogger("MA5").debug(
"The folder '" + self.toolsdir + "' is not found"
)
log.debug("The folder '" + self.toolsdir + "' is not found")
return False
if not os.path.isdir(self.installdir):
logging.getLogger("MA5").debug(
"The folder " + self.installdir + "' is not found"
)
log.debug("The folder " + self.installdir + "' is not found")
return False
return True

Expand Down Expand Up @@ -124,9 +122,11 @@ def Configure(self):
"--prefix=" + self.installdir,
"--enable-allplugins",
]
log.debug("Configuring fastjet with prefix %s", self.installdir)
log.debug("Configuring fastjet with CXXFLAGS %s", os.environ["CXXFLAGS"])
logname = os.path.normpath(self.installdir + "/configuration.log")
# Execute
logging.getLogger("MA5").debug("shell command: " + " ".join(theCommands))
log.debug("shell command: " + " ".join(theCommands))
ok, out = ShellCommand.ExecuteWithLog(
theCommands, logname, self.tmpdir, silent=False
)
Expand All @@ -137,44 +137,44 @@ def Configure(self):
os.environ["CXXFLAGS"] = initial_env
# return result
if not ok:
logging.getLogger("MA5").error(
log.error(
"impossible to configure the project. For more details, see the log file:"
)
logging.getLogger("MA5").error(logname)
log.error(logname)
return ok

def Build(self):
# Input
theCommands = ["make", "-j" + str(self.ncores)]
logname = os.path.normpath(self.installdir + "/compilation.log")
# Execute
logging.getLogger("MA5").debug("shell command: " + " ".join(theCommands))
log.debug("shell command: " + " ".join(theCommands))
ok, out = ShellCommand.ExecuteWithLog(
theCommands, logname, self.tmpdir, silent=False
)
# return result
if not ok:
logging.getLogger("MA5").error(
log.error(
"impossible to build the project. For more details, see the log file:"
)
logging.getLogger("MA5").error(logname)
log.error(logname)
return ok

def Install(self):
# Input
theCommands = ["make", "install"]
logname = os.path.normpath(self.installdir + "/installation.log")
# Execute
logging.getLogger("MA5").debug("shell command: " + " ".join(theCommands))
log.debug("shell command: " + " ".join(theCommands))
ok, out = ShellCommand.ExecuteWithLog(
theCommands, logname, self.tmpdir, silent=False
)
# return result
if not ok:
logging.getLogger("MA5").error(
log.error(
"impossible to build the project. For more details, see the log file:"
)
logging.getLogger("MA5").error(logname)
log.error(logname)
return ok

def Check(self):
Expand All @@ -186,52 +186,38 @@ def Check(self):
]
for dir in dirs:
if not os.path.isdir(dir):
logging.getLogger("MA5").error("folder " + dir + " is missing.")
log.error("folder " + dir + " is missing.")
self.display_log()
return False

# Check fastjet executable
if not os.path.isfile(self.installdir + "/bin/fastjet-config"):
logging.getLogger("MA5").error("binary labeled 'fastjet-config' is missing.")
log.error("binary labeled 'fastjet-config' is missing.")
self.display_log()
return False

# Check one header file
if not os.path.isfile(self.installdir + "/include/fastjet/PseudoJet.hh"):
logging.getLogger("MA5").error(
"header labeled 'include/fastjet/PseudoJet.hh' is missing."
)
log.error("header labeled 'include/fastjet/PseudoJet.hh' is missing.")
self.display_log()
return False

if (not os.path.isfile(self.installdir + "/lib/libfastjet.so")) and (
not os.path.isfile(self.installdir + "/lib/libfastjet.a")
):
logging.getLogger("MA5").error(
"library labeled 'libfastjet.so' or 'libfastjet.a' is missing."
)
log.error("library labeled 'libfastjet.so' or 'libfastjet.a' is missing.")
self.display_log()
return False

return True

def display_log(self):
logging.getLogger("MA5").error("More details can be found into the log files:")
logging.getLogger("MA5").error(
" - " + os.path.normpath(self.installdir + "/wget.log")
)
logging.getLogger("MA5").error(
" - " + os.path.normpath(self.installdir + "/unpack.log")
)
logging.getLogger("MA5").error(
" - " + os.path.normpath(self.installdir + "/configuration.log")
)
logging.getLogger("MA5").error(
" - " + os.path.normpath(self.installdir + "/compilation.log")
)
logging.getLogger("MA5").error(
" - " + os.path.normpath(self.installdir + "/installation.log")
)
log.error("More details can be found into the log files:")
log.error(" - " + os.path.normpath(self.installdir + "/wget.log"))
log.error(" - " + os.path.normpath(self.installdir + "/unpack.log"))
log.error(" - " + os.path.normpath(self.installdir + "/configuration.log"))
log.error(" - " + os.path.normpath(self.installdir + "/compilation.log"))
log.error(" - " + os.path.normpath(self.installdir + "/installation.log"))

def NeedToRestart(self):
return True
Loading