Presentation is loading. Please wait.

Presentation is loading. Please wait.

1 Persistency – Update and Plans Malcolm Ellis Software Phone Meeting 25 th August 2005.

Similar presentations


Presentation on theme: "1 Persistency – Update and Plans Malcolm Ellis Software Phone Meeting 25 th August 2005."— Presentation transcript:

1 1 Persistency – Update and Plans Malcolm Ellis Software Phone Meeting 25 th August 2005

2 2 Status First version is working with four classes made persistent through a gzipped text file. Classes are SciFi truth hit, digitised hit, reconstructed doublet cluster and raw data hit. Code to allow user control over what classes to read/write works and sample applications exercising common schemes have been written using the new Applications facility.

3 3 Example data flow - Simulation Simulation executable reads DataCards. Each event results in the creation of some SciFiHits which are stored in the MICEEvent. All SciFiHits in the MICEEvent are written to an output file (Sim.out.gz)

4 4 Example data flow - Digitisation Digitisation executable reads DataCards SciFiHits restored into memory (MICEEvent) Digitisation code loops over SciFiHits and make SciFiDigits (stored in MICEEvent). SciFiHits and SciFiDigits are then stored in a new output file (Digits.out.gz)

5 5 Example data flow - Reconstruction Reconstruction executable reads DataCards SciFiHits and SciFiDigits are restored into Memory Reconstruction code creates SciFiDoubletClusters, etc... SciFiHits, ScifiDigits and SciFiDoubletClusters are stored in a new output file (Rec.out.gz)

6 6 Example data flow - Histograms Executable restores SciFiHits, SciFiDigits and SciFiDoubletClusters into memory. Relevant values (e.g. true hit position, digitised ADC counts, reconstructed number of PE, etc) are histogrammed. Histograms are written to an hbook file.

7 7 Example data flow – Real Data Executable reads in real data (August 2005 cosmic ray test) using a special convertor. Convertor code produces VlpcHits (raw data format independant transient classes) which are stored in the MICEEvent VlpcHits are then made persistent

8 8 Example Data Flow - Calibration Executable restores VlpcHits into memory. Histograms are made of the ADC distribution channel by channel Histograms are written to an hbook file. PAW kumac is used to perform fits and write calibration file (this could also be done in C++ using calls to CERNLIB).

9 9 Example Code (Reconstruction) // setup persistency PersistClasses* pClassesRead = new PersistClasses( false ); pClassesRead->setClassProcessing( "SciFiHit", true ); pClassesRead->setClassProcessing( "SciFiDigit", true ); PersistClasses* pClassesWrite = new PersistClasses( false ); pClassesWrite->setClassProcessing( "SciFiHit", true ); pClassesWrite->setClassProcessing( "SciFiDigit", true ); pClassesWrite->setClassProcessing( "SciFiDoubletCluster", true ); TextFileReader* reader = new TextFileReader( MyDataCards.fetchValueString( "InputFile" ), theEvent, *pClassesRead ); TextFileWriter* writer = new TextFileWriter( MyDataCards.fetchValueString( "OutputFile" ), theEvent, *pClassesWrite );

10 10 Example Code (Reconstruction) while(!done) { done = ! reader->readEvent(); if( ! done ) { Event ev( manager, theEvent ); ev.Process(); writer->writeEvent(); clearEvent( theEvent ); } count++; if (!(count%10)) printf("Processed %d events\n", count); } reader->closeInputFile(); writer->closeOutputFile();

11 11 Example use of MICEEvent std::vector digits; for( unsigned int i = 0; i < event.sciFiHits.size(); ++i ) { SciFiHit* hit = event.sciFiHits[i]; >> digits.push_back( new SciFiDigit( event.sciFiHits[i], adcCounts, tdcCounts ) ); } // merge hits on the same channel // store the merged digits for( unsigned int i = 0; i < digits.size(); ++i ) event.sciFiDigits.push_back( digits[i] );

12 12 Data-Flow MICEEvent (transient classes) Persistent Storage (gzipped text file) SciFiHits Digitisation code SciFiHits SciFiDigits

13 13 Next Steps Minimum set of persistent classes for work in preparation for KEK test now exists. Focus will now turn to the applications needed for online and offline analysis of the KEK beam-test (SciFi) In parallel, need to work on the TOF and CKOV code so that G4MICE can be used for analysis of these detectors (Aron and Makoto).


Download ppt "1 Persistency – Update and Plans Malcolm Ellis Software Phone Meeting 25 th August 2005."

Similar presentations


Ads by Google