diff --git a/examples/SimFitCoordinator.cc b/examples/SimFitCoordinator.cc index a43f3aa..c930c12 100644 --- a/examples/SimFitCoordinator.cc +++ b/examples/SimFitCoordinator.cc @@ -1,85 +1,91 @@ /* Copyright 2013 University of Warwick Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. */ /* Laura++ package authors: John Back Paul Harrison Thomas Latham */ #include #include #include #include "TFile.h" #include "TRandom.h" #include "TString.h" #include "TSystem.h" #include "LauSimFitCoordinator.hh" void usage( std::ostream& out, const TString& progName ) { out<<"Usage:\n"; out< [firstExpt = 0] [numTasks = 2] [port = 0] [refFitDir] \n"; } int main(const int argc, const char ** argv) { if ( argc < 3 ) { usage( std::cerr, argv[0] ); return EXIT_FAILURE; } UInt_t iFit = atoi( argv[1] ); UInt_t nExpt = atoi( argv[2] ); UInt_t firstExpt = 0; UInt_t nTasks = 2; UInt_t port = 0; TString refDirName = ""; Bool_t useAsymmErrors = kFALSE; Bool_t twoStageFit = kFALSE; TString ntupleName = ""; if ( argc > 3 ) { firstExpt = atoi( argv[3] ); if ( argc > 4 ) { nTasks = atoi( argv[4] ); if ( argc > 5 ) { port = atoi( argv[5] ); if ( argc > 6 ) { refDirName = argv[6]; ntupleName += refDirName; ntupleName += "/"; } } } } - ntupleName += "coordinator-ntuple-"; + UInt_t lastExpt = firstExpt + nExpt - 1; + + ntupleName += "coordinator-ntuple_expts"; + ntupleName += firstExpt; + ntupleName += "-"; + ntupleName += lastExpt; + ntupleName += "_fit"; ntupleName += iFit; ntupleName += ".root"; LauSimFitCoordinator coordinator( nTasks, port ); coordinator.runSimFit( ntupleName, nExpt, firstExpt, useAsymmErrors, twoStageFit ); return EXIT_SUCCESS; }