need help with new file set stuff

From: Stephen J. Sanders (ssanders@ku.edu)
Date: Sun Jan 06 2002 - 05:27:14 EST

  • Next message: Stephen J. Sanders: "Re: need help with new file set stuff"

    Hi,
    I'm having trouble getting the new file set stuff working and hope someone
    can help.   Before the recent changes my bratmain file contained the
    following code:
    ==================================================
      BrIOModule* inputModule =
       new BrRawDataInput("rawInput", "Raw Data Input");
      if (nInputs == 1) {
          inputModule->SetIOMode(BrIOModule::kBrJobFile|
                  BrRawDataInput::kBrRawDiskFile);
         inputModule->AddFile(inputFile);
      }
      else {
       inputModule->SetIOMode(BrIOModule::kBrRunFile|
                  BrRawDataInput::kBrRawDiskFile);
       Char_t  baseName[128];
       for (Int_t i = 0; i < nInputs; i++) {
         sprintf(baseName, "data/run%06dseq%03d.dat", runNo, i);
         inputModule->AddFile(baseName);
       }
      }
    ==========================================================
    which worked great for both single sequences and multiple sequences in a 
    run.
    This code now fails for multiple sequences, with only the first sequence 
    being replayed if
    I have nInputs > 1.
    
    
    So...based on Christian's messages to dev-l, I tried the following 
    modification:
    
    =====================================================================================================
      BrIOModule* inputModule =
       new BrRawDataInput("rawInput", "Raw Data Input");
      if (nInputs == 1) {
          inputModule->SetIOMode(BrIOModule::kBrJobFile|
                  BrRawDataInput::kBrRawDiskFile);
         inputModule->AddFile(inputFile);
      }
      else {
       inputModule->SetIOMode(BrIOModule::kBrRunFile|
                  BrRawDataInput::kBrRawDiskFile);
        Char_t  baseName[128];
          sprintf(baseName, "run%06dseq00[0-%d]\\.dat", runNo, nInputs);
          inputModule->AddFileSet("data",baseName);
       }
      }
    ==========================================================
    
    With nInputs = 3, the file set is generated:
    File list:
      File set 1
       run004641seq000.dat
       run004641seq001.dat
       run004641seq002.dat
       run004641seq003.dat
    
    But then I get:
    
    Info in <BrRawDataInput::Event>: No more files in this set
    BrTriggerFilter statistics summary:
    Processed events: 0
    Accepted events:  0
    
    before ANY files are replayed.
    
    Any suggestions?
    
    Thanks
    ....steve
    



    This archive was generated by hypermail 2b30 : Sun Jan 06 2002 - 05:28:27 EST