ROME Root based Object oriented Midas Extension

Slides:



Advertisements
Similar presentations
User-Defined Functions Like short programs Can operate on their own data Can receive data from callers and return data to callers.
Advertisements

H.G.Essel: Go4 - J. Adamczewski, M. Al-Turany, D. Bertini, H.G.Essel, S.Linev CHEP 2004 Go4 v2.8 Analysis Design.
Section 6.1 Explain the development of operating systems Differentiate between operating systems Section 6.2 Demonstrate knowledge of basic GUI components.
CLEO’s User Centric Data Access System Christopher D. Jones Cornell University.
Software All parts of the computer people can NOT touch, such as programs, files, documents and any other data.
Talk. Paul Scherrer Institut 5232 Villigen PSI ROME / / Matthias Schneebeli ROME Root based Object oriented Midas Extension Presented by Matthias.
Shuei MEG review meeting, 2 July MEG Software Status MEG Software Group Framework Large Prototype software updates Database ROME Monte Carlo.
Paul Scherrer Institut 5232 Villigen PSI ROME / / Matthias Schneebeli ROME Root based Object oriented Midas Extension Presented by Matthias.
DBSQL 14-1 Copyright © Genetic Computer School 2009 Chapter 14 Microsoft SQL Server.
Storage Manager Overview L3 Review of SM Software, 28 Oct Storage Manager Functions Event data Filter Farm StorageManager DQM data Event data DQM.
Talk. Paul Scherrer Institut 5232 Villigen PSI ROME / / Matthias Schneebeli ROME Softies Meeting Presented by Matthias Schneebeli.
Guide to Linux Installation and Administration, 2e1 Chapter 7 The Role of the System Administrator.
Update on the new reconstruction software F. Noferini E. Fermi center INFN CNAF EEE Analysis Meeting - 14/09/20151.
Talk. Paul Scherrer Institut 5232 Villigen PSI ROME / / Matthias Schneebeli ROME CHEP 2006 Presented by Matthias Schneebeli a universally applicable.
1 Control Software (CAT) Introduction USB Interface implementation Calorimeter Electronics Upgrade Meeting Frédéric Machefert Wednesday 5 th May, 2010.
DANA uses a factory model to deliver data “just in time”
Update on the new reconstruction software F. Noferini E. Fermi center INFN CNAF EEE Analysis Meeting - 15/06/20151.
CMS pixel data quality monitoring Petra Merkel, Purdue University For the CMS Pixel DQM Group Vertex 2008, Sweden.
Introduction CMS database workshop 23 rd to 25 th of February 2004 Frank Glege.
H.G.Essel: Go4 - J. Adamczewski, M. Al-Turany, D. Bertini, H.G.Essel, S.Linev CHEP 2003 GSI Online Offline Object Oriented Go4.
Tracker Visualization Tool: integration in ORCA Maria S. Mennea, Giuseppe Zito University & INFN Bari, Italy Tracker b-tau Cosmic Challenge preparation.
Talk. Paul Scherrer Institut 5232 Villigen PSI ROME / / Matthias Schneebeli ROME CHEP 2006 Presented by Matthias Schneebeli a universally applicable.
David Adams ATLAS DIAL: Distributed Interactive Analysis of Large datasets David Adams BNL August 5, 2002 BNL OMEGA talk.
Paul Scherrer Institut 5232 Villigen PSI CHEP 2006 in Mumbay / / Matthias Schneebeli ROME CHEP 2006 Presented by Matthias Schneebeli a universally.
Talk. Paul Scherrer Institut 5232 Villigen PSI CHEP 2006 in Mumbay / / Matthias Schneebeli ROME CHEP 2006 Presented by Matthias Schneebeli a.
Talk. Paul Scherrer Institut 5232 Villigen PSI ROME / / Matthias Schneebeli ROME Root based Object oriented Midas Extension Presented by Matthias.
SoLID simulation with GEMC Zhiwen Zhao 2015/03/26.
H.G.Essel: Go4 - J. Adamczewski, M. Al-Turany, D. Bertini, H.G.Essel, S.Linev ROOT 2002 GSI Online Offline Object Oriented Go4.
Paul Scherrer Institut 5232 Villigen PSI ROME / / Matthias Schneebeli ROME Collaboration Meeting in Pisa Presented by Matthias Schneebeli.
GO4GO4GO4GO4GO4GO4GO4GO4GO4GO4GO4GO4GO4GO4GO4GO4GO4GO4GO4GO4GO4GO4GO4GO4GO4GO4GO4GO4GO4GO4GO4GO4GO4GO4GO4GO4GO4GO4GO4GO4GO4GGO4GO4GO4GO4GO4GO4GO4GO4GO4GO4GO4GO4GO4GO4GO4GO4GO4GO4GO4GO4GO4GO4GO4GO4GO4GO4GO4GO4GO4GO4GO4GO4GO4GO4GO4GO4GO4GO4GO4GO4GO4G.
Talk. Paul Scherrer Institut 5232 Villigen PSI ROME / / Matthias Schneebeli ROME Wednesday Seminar Presented by Matthias Schneebeli a universally.
Online Monitoring System at KLOE Alessandra Doria INFN - Napoli for the KLOE collaboration CHEP 2000 Padova, 7-11 February 2000 NAPOLI.
Paul Scherrer Institut 5232 Villigen PSI ROME / / Matthias Schneebeli ROME Root based Object oriented Midas Extension Presented by Matthias.
TDAQ Experience in the BNL Liquid Argon Calorimeter Test Facility Denis Oliveira Damazio (BNL), George Redlinger (BNL).
M. Oldenburg GridPP Metadata Workshop — July 4–7 2006, Oxford University 1 Markus Oldenburg GridPP Metadata Workshop July 4–7 2006, Oxford University ALICE.
October Test Beam DAQ. Framework sketch Only DAQs subprograms works during spills Each subprogram produces an output each spill Each dependant subprogram.
THE WINDOWS OPERATING SYSTEM Computer Basics 1.2.
LHCb Configuration Database Lana Abadie, PhD student (CERN & University of Pierre et Marie Curie (Paris VI), LIP6.
The MEG Offline Project General Architecture Offline Organization Responsibilities Milestones PSI 2/7/2004Corrado Gatto INFN.
Copyright 2007, Information Builders. Slide 1 iWay Web Services and WebFOCUS Consumption Michael Florkowski Information Builders.
MINIX Presented by: Clinton Morse, Joseph Paetz, Theresa Sullivan, and Angela Volk.
Go4 Workshop J.Adamczewski-Musch, S.Linev Go4 advanced features.
Talk. Paul Scherrer Institut 5232 Villigen PSI ROME / / Matthias Schneebeli ROME Softies Meeting Presented by Matthias Schneebeli.
AliRoot Classes for access to Calibration and Alignment objects Magali Gruwé CERN PH/AIP ALICE Offline Meeting February 17 th 2005 To be presented to detector.
XML scheme for configuration data V.Černý on behalf of the Bratislava group Initiated by Marco’s call:...a software layer for implementing the handling.
Troubleshooting Workflow 8 Raymond Cruz, Software Support Engineer.
LonWorks Introduction Hwayoung Chae.
The Database Project a starting work by Arnauld Albert, Cristiano Bozza.
Talk. Paul Scherrer Institut 5232 Villigen PSI ROME / / Matthias Schneebeli ROME Wednesday Seminar Presented by Matthias Schneebeli a universally.
Paul Scherrer Institut 5232 Villigen PSI ROME / / Matthias Schneebeli ROME Root based Object oriented Midas Extension Presented by Matthias.
1 Copyright © 2008, Oracle. All rights reserved. Repository Basics.
Xxx Presentation, No 1 Copyright © TAC AB Engineering Classic Networks1.
David Lawrence JLab May 11, /11/101Reconstruction Framework -- GlueX Collab. meeting -- D. Lawrence.
HYDRA Framework. Setup of software environment Setup of software environment Using the documentation Using the documentation How to compile a program.
L1Calo DBs: Status and Plans ● Overview of L1Calo databases ● Present status ● Plans Murrough Landon 20 November 2006.
MIKADO – Generation of ISO – SeaDataNet metadata files
Go4 v2.2 Status & Overview CHEP 2003
Architecture Review 10/11/2004
CSC 222: Object-Oriented Programming
Integration Framework of SAP Business One as Platform for Scenario Development January 2016 Public.
Operating System.
Presented by Matthias Schneebeli
CMS High Level Trigger Configuration Management
Talk.
Chapter 8: Introduction to High-Level Language Programming
Database Design Hacettepe University
F II 1. Background Objectives
ACTIVE DIRECTORY An Overview.. By Karan Oberoi.
Let’s start from the beginning
Calibration Infrastructure Design
Presentation transcript:

ROME Root based Object oriented Midas Extension Presented by Matthias Schneebeli

Index Introduction to the ROME Environment Objects inside ROME Projects ROMEBuilder Data Stream Installation

Introduction to ROME

Features Tool for Event based Data Analysis Fully Object Oriented Root based Full connection to the Midas Environment Online and Offline Based on Tasks and Folders for an easy Data and Program Structure Experiment independent Base Classes Experiment dependent Classes are generated out of simple XML-Files The Users write only experiment specific code (physics) Administrative code is implemented in the generated code Self Documenting Code Self Linking Project

Objects Folders Tasks Objects, where data is stored in Stores the data of one detector (or sub detector) component Hierarchically arranged Data inside of Folders is structured Tasks Tasks are objects, which provides actions They make calculations Store and read data in folders Fill trees and histograms Hierarchically arranged. Task also own histograms Trees Data Objects : only written, never read Used to write data on files Histograms Graphical Data Objects : only written Belong to one Task Steering Parameters Task steering Framework steering

Interconnections Disk Histograms Tasks Histograms Folders Histograms (Input) Read (any Format) Histograms Read Fill Tasks Folders Histograms Fill Fill Histograms Flag Read Trees Disk (Output) Write (ROOT)

The ROME Environment ROME classes ROMEBuilder Exp. classes Executable Experiment independent ‘ROME’-Classes Base classes for the generated, experiment dependent classes. ROMEBuilder Builds all experiment dependent classes out of simple XML Files. XML files describe Tasks, Folders, Trees, Histos, Steering Parameters and Midas Banks. Links the generated project. Documents the generated project. ROME classes XML File Exp. classes ROMEBuilder Executable Documentation Project ROME Environment

Classes in the Generated Project The generated classes are : Task classes Implement 5 user methods : Init(), BeginOfRun(), Event(), EndOfRun(), Terminate(). Folder classes Define how the data is stored. Analyzer class Main class. The Analyzer provides all user-methods. IO class The IO handles all input and output. IO Trees Data base Analyzer Folders Steering ROME classes Tasks Folders fAnalyzer ROMEEventLoop

XML Project Definition File <Experiment Shortcut> <Author Name=“Author”/> <Programname Name=“Program Name”/> <Folder> Folder definitions… </Folder> <Task> Task definitions… </Task> <Trees> Tree definitions… </Trees> <GeneralSteeringParameters> Steering Parameters definitions… </GeneralSteeringParameters> <MidasBanks> Midas Bank definitions… </MidasBanks> </Experiment Shortcut> Folder Classes Task Classes Analyzer and IO Class

Folders XML File <Experiment Shortcut> <Folder> <SubFolder FolderName=“Folder Name" FolderTitle="Folder Title“ Array=“yes/[no]” DataBase=“yes/[no]”> <Author Name=“Author”/> <Version Number=“Version Number”/> <ClassDescription Text=“Class Description”/> <Fields> <Field Name 1 Type=“Field Type 1” Init=“Init Value 1” Comment=“Comment 1” DataBasePath=“DB-Path”/> </Fields> </SubFolder> </Folder> </Experiment Shortcut> Code Object Arrays [Field Type 1] Get[Folder Name]ObjectAt(int index)->Get[Field 1](); void Get[Folder Name]ObjectAt(int index)->Set[Field 1]([Field Type 1] value); Single Objects [Field Type 1] Get[Folder Name]Object()->Get[Field 1](); void Get[Folder Name]Object()->Set[Field 1]([Field Type 1] value);

Tasks XML File Code <Experiment Shortcut> <Task> <SubTask Name=“Task Name”> <Histos> <Histo Name Type=“Variable Type” ArraySize=“Array Size” Title=“Title” FolderName=”Histo Folder Name” FolderTitle=”Histo Folder Title” NumberOfBinsX=“# of X bins” XMin=“X min” XMax=“X max”/> </Histos> </SubTask> </Task> </Experiment Shortcut> XML File void [Experiment Shortcut]T[Task Name]::Init() { } void [Experiment Shortcut]T[Task Name]::BeginOfRun() { } void [Experiment Shortcut]T[Task Name]::Event() { } void [Experiment Shortcut]T[Task Name]::EndOfRun() { } void [Experiment Shortcut]T[Task Name]::Terminate() { } Fill[Histo Name](double value,double weight) Draw[Histo Name]() Get[Histo Name]Handle() Fill[Histo Name]At(int index,double value,double weight) Draw[Histo Name]At() Get[Histo Name]HandleAt(int index) Code Single Histograms Histogram Arrays

Trees XML File <Experiment Shortcut> <Trees> <Tree Name=“Tree Name” Title=“Title”> <Branch Name=“Branch Name” Folder=“Folder”/> </Tree> </Trees> </Experiment Shortcut> XML File Bool_t is[Tree Name]FillEvent() void Set[Tree Name]FillEvent(true/false) Code

General Steering Parameters <Experiment Shortcut> <GeneralSteeringParameters> <Field 1 Type=“Type 1” Init=“Init 1” Comment=“Comment 1”/> <SubClass> <Field 2 Type=“Type 2” Init=“Init 2” Comment=“Comment 2”/> </SubClass> </GeneralSteeringParameters> </Experiment Shortcut> XML File [Type 1] GetGSP()->Get[Field 1]() [Type 2] GetGSP()->Get[SubClass]()->Get[Field 2]() Code <SubTask Name=“Task Name”> <SteeringParameters> <…/> </SteeringParameters> </SubTask> XML File

Midas Banks XML File <Experiment Shortcut> <MidasBanks> <Bank 1 Type=“Type 1”/> <Bank 2 Type=“struct” StructName=“Structure Name”> <Field 2 Type=“Type 2” PackedSize=“PackSize 2”/> </Bank 2> </MidasBanks> </Experiment Shortcut> XML File [Type 1] Get[Bank 1]BankAt(int index) Int Get[Bank 1]BankEntries() [Structure Name]* Get[Bank 2]BankAt(int index) Int Get[Bank 2]BankEntries() e.g. : [Type 2] Get[Bank 2]BankAt(int index).[Field 2] Code Simple Banks Structured Banks

XML Editors XMLSpy Table Format Commercial Software (50 Euro) Only for Windows EditiX Nice Tree Format Commercial Software (30 Euro) Windows, Linux, Mac ROME works with any Editor

Benefit of a generated Framework Consistent Program Structure All classes look the same Better readability Less Handwritten Code Code of a class is written once (in the builder) and reproduced many times Easier Maintenance Modification are done once (in the builder) and then available in the whole framework

Generated Code XML File <SubFolder FolderName=“Folder Name“> <Fields> <Field Name 1 Type=“Field Type 1” Init=“Init Value 1” Comment=“Comment 1”/> </Fields> </SubFolder> XML File class [Experiment Shortcut][Folder Name] : public TObject { protected: [Field Type 1] f[Field Name 1]; // [Comment 1] public: [Experiment Shortcut][Folder Name]([Field Type 1] value1=[Init Value 1] ) { f[Field Name 1] = value1; }; [Field Type 1] Get[Field Name 1]() { return f[Field Name 1]; }; void Set[Field Name 1]([Field Type 1] value1) { f[Field Name 1] = value1; }; ClassDef([Experiment Shortcut][Folder Name],[Version Number]) }; Code

Data base SQL Data base see Ryu’s presentation XML data base If no network connection available

Read and Write Data Input Data Root files Midas files Online buffer Data base Output Data Database Read and filled to the Folder by the Framework Read by the Framework. Data accessed via Midas Bank access methods. Read and filled to the Folder by the Framework Written by the Framework, can be flagged Written with : fAnalyzer->Write[Folder]DataBase(this);

Installation Installation of Cygwin (only Windows) Installation of ROOT Installation of LIBXML2 (only Linux) Installation of MIDAS (only online, Linux) CVS checkout of ROME Define environment variable ROMESYS Define environment variable ‘Path’ C:\> set ROMESYS=C:/ROME C:\> set Path=%Path%;%ROMESYS%/bin C:\> cvs checkout ROME C:\ROME> nmake –f Makefile.win C:\MyExp> ROMEBuilder.exe myExp.xml –v [–o Output Path] C:\MyExp> progname Windows [~]$ setenv ROMESYS ~/ROME [~]$ setenv PATH $ROMESYS/bin:$PATH [~]$ cvs checkout ROME [~/ROME]$ make [../MyExp]$ romebuilder myExp.xml –v [-o Output Path] [~/MyExp]$ progname Linux

Configuration File XML-File for steering the program XML File <Modes AnalyzingMode=“online” InputDataFormat=“root”/> <RunNumbers=“1001,1002”/> <Tasks> <Task1 Active=“yes”/> <Task2 Active=“no”/> <\Tasks> <Trees> <Tree1 Read=“yes” Write=“no” /> <Tree2 Read=“no” Write=“yes” /> <\Trees> </Configuration> XML File

Summary Structure of the framework is defined in XML-files All code is generated, except the physical calculations The framework provides access functions for the user SQL Data base XML Configuration file

Sample Experiment

Sample Overview 2 Tasks ReadMidas ADCCalib 4 Folders CMPMTData CMCalib (Data base) CMPMTInfo (Data base) Trigger 1 Tree Data

XML Configuration File I sample.xml <Folder> <SubFolder FolderName="CMPMTData" Array="257"> <Fields> <ADC Type="Float_t" Initialisation="0" Comment="// ADC Data"/> </Fields> </SubFolder> <SubFolder FolderName="CMCalib" Array="257" DataBase="yes"> <ADCPedestal Type="Float_t" Initialisation="0" Comment="// ADC Pedestal"/> <SubFolder FolderName="CMPMTInfo" Array="257" DataBase="yes"> <PMID Type="Int_t" Initialisation="0" Comment="// Photo Multiplier ID"/> <ADCID Type="Int_t" Initialisation="0" Comment="// ADC Number"/> <SubFolder FolderName="Trigger"> <ID Type="Int_t" Initialisation="0" Comment="// event ID"/> <Eventnumber Type="Int_t" Initialisation="0" Comment="// Event Number"/> </Folder>

XML Configuration File II <Task> <SubTask Name="ReadMidas“/> <SubTask Name="ADCCalib"> <Histos> <ADCHisto Type="TH1F" ArraySize="257" FolderName="adc" Title="ADC" NumberOfBinsX=“500" XMin="0" XMax=“500"/> </Histos> </SubTask> </Task> <Trees> <Tree Name="Data" Title="Calorimeter PMT Data"> <Branch Name="PMTData" Folder="CMPMTData"/> </Tree> </Trees> <MidasBanks> <ADC0 Type="unsigned short“/> </MidasBanks> sample.xml

Read Midas Task XYZTReadMidas.cpp void XYZTReadMidas::Event() { for (int i=0;i<gNumberOfPMT;i++) { int iadc = fAnalyzer->GetCMPMTInfoAt(i)->GetADCID(); Float_t adcValue = fAnalyzer->GetADC0BankAt(iadc); fAnalyzer->GetCMPMTDataAt(i)->SetADC(adcValue); }

ADC Calibration Task XYZTADCCalib.cpp void XYZTADCCalib::Event() { for (int i=0;i<gNumberOfPMT;i++) { float pmtData = fAnalyzer->GetCMPMTDataAt(i)->GetADC(); float pedestal = fAnalyzer->GetCMCalibAt(i)->GetADCPedestal(); FillADCHistoAt(i,pmtData - pedestal); } void XYZTADCCalib::EndOfRun() DrawADCHistoAt(i);

Run Program C:\Sample> ROMEBuilder.exe sample.xml –v link messages C:\Sample> XYZSample 12005 events processed Task 'ReadMidas' : run time = 00:00:00 Task 'ADCCalib' : run time = 00:00:02 Windows

The MEG Experiment

MEG Experiment CMRef CMPMTData Ref PMT Data Tree PMT Data CMHit Hit Hit Tree CMPMTInfo Info Data base CMCalib Calib Data base CMScaler Scaler CMHV HV Environment Env Trigger DC CM TC MEG

Referencies CMHit Hit CMPMTInfo Info CMCalib Calib CMScaler Scaler CMHV HV Environment Env Trigger MEG PMT Data CMPMTData ADC0 ADC1 TDC CMRef

Detailed Introduction to ROME

ROME Classes ROMEAnalyzer Main Class Provides general steering methods ROMEEventLoop Implements the event loop ROMETask ROMETree ROMERunTable