Auxiliary program to convert raw CLB data to KM3NETDAQ::JDAQTimeslice data.
More...
Go to the source code of this file.
|
int | main (int argc, char **argv) |
|
Auxiliary program to convert raw CLB data to KM3NETDAQ::JDAQTimeslice data.
- Author
- mdejong
Definition in file JCLB.cc.
int main |
( |
int |
argc, |
|
|
char ** |
argv |
|
) |
| |
Definition at line 137 of file JCLB.cc.
141 using namespace KM3NETDAQ;
153 JParser<> zap(
"Auxiliary program to convert raw CLB data to KM3NETDAQ::JDAQTimeslice data.");
155 zap[
'f'] =
make_field(inputFile,
"input file).");
157 zap[
'n'] =
make_field(numberOfEvents) = numeric_limits<int>::max();
164 catch(
const exception& error) {
165 FATAL(error.what() << endl);
179 uint32_t run = numeric_limits<uint32_t>::max();
182 ifstream
in(inputFile.c_str(), ios::binary);
184 for (
int count = 0;
count != numberOfEvents &&
in.read((
char*) &size,
sizeof(uint32_t)); ++
count) {
188 buffer_type buffer(size);
190 if (
in.read(buffer.data(), size)) {
196 if (run == numeric_limits<uint32_t>::max()) {
211 while (data.size() >
queue) {
217 WARNING(
"Run numbers differ " << run <<
' ' << header->
runNumber() <<
" -> skip data." << endl);
227 while (!data.empty()) {
Utility class to parse command line options.
then echo Submitting reweighting and histogram comparison jobs to nikhef stbc batch queue
#define make_field(A,...)
macro to convert parameter to JParserTemplateElement object
then usage $script< input_file >< detector_file > fi set_variable OUTPUT_DIR set_variable SELECTOR JDAQTimesliceL1 set_variable DEBUG case set_variable DEBUG
do set_variable DETECTOR_TXT $WORKDIR detector
then fatal Wrong number of arguments fi set_variable DETECTOR $argv[1] set_variable INPUT_FILE $argv[2] eval JPrintDetector a $DETECTOR O IDENTIFIER eval JPrintDetector a $DETECTOR O SUMMARY source JAcoustics sh $DETECTOR_ID CHECK_EXIT_CODE typeset A TRIPODS get_tripods $WORKDIR tripod txt TRIPODS for EMITTER in
uint64_t inMilliSeconds() const