Project
Loading...
Searching...
No Matches
o2sim_mergeg4scoring.cxx
Go to the documentation of this file.
1
// Copyright 2019-2026 CERN and copyright holders of ALICE O2.
2
// See https://alice-o2.web.cern.ch/copyright for details of the copyright holders.
3
// All rights not expressly granted are reserved.
4
//
5
// This software is distributed under the terms of the GNU General Public
6
// License v3 (GPL Version 3), copied verbatim in the file "COPYING".
7
//
8
// In applying this license CERN does not waive the privileges and immunities
9
// granted to it by virtue of its status as an Intergovernmental Organization
10
// or submit itself to any jurisdiction.
11
12
// Sum the per-worker Geant4 scoring dumps of an o2-sim run into one file per mesh
13
14
#include "
SimConfig/G4ScoringMerger.h
"
15
#include <cstdlib>
16
#include <iostream>
17
18
int
main
(
int
argc,
char
* argv[])
19
{
20
const
std::string directory = argc > 1 ? argv[1] :
"."
;
21
const
int
expectedWorkers = argc > 2 ? std::atoi(argv[2]) : 0;
22
const
int
merged =
o2::conf::mergeG4ScoringDumps
(directory, expectedWorkers);
23
if
(merged < 0) {
24
return
1;
25
}
26
std::cout <<
"merged "
<< merged <<
" scoring mesh(es) in "
<< directory <<
"\n"
;
27
return
0;
28
}
G4ScoringMerger.h
o2::conf::mergeG4ScoringDumps
int mergeG4ScoringDumps(const std::string &directory, int expectedWorkers=0)
Definition
G4ScoringMerger.cxx:86
main
#define main
Definition
test_OverrideLabels.cxx:13
run
o2sim_mergeg4scoring.cxx
Generated on Sat Oct 3 2026 10:55:17 for Project by
1.9.8