N ATIONAL E NERGY R ESEARCH S CIENTIFIC C OMPUTING C ENTER 1 ACAT 2000, Fermilab Oct 19 2000Control States... Control States for the Atlas Software Framework.

Slides:



Advertisements
Similar presentations
Dual use tools: requirements and design David Adams BNL November 20, 2013 ASG tools working group.
Advertisements

15 March, 2000LHCb Computing1 Software Review Panel LHCb Answers to Architecture, Data Model and Program Infrastructure Pere Mato for the LHCb Collaboration.
1 Frameworks. 2 Framework Set of cooperating classes/interfaces –Structure essential mechanisms of a problem domain –Programmer can extend framework classes,
25/03/2003Simulation Application for the LHCb Experiment CHEP March 2003 Presented by: W. Pokorski / CERN Authors: I. Belyaev, Ph. Charpentier,
The Event as an Object-Relational Database: Avoiding the Dependency Nightmare Christopher D. Jones Cornell University, USA.
1 An introduction to design patterns Based on material produced by John Vlissides and Douglas C. Schmidt.
Application Use Cases NIKHEF, Amsterdam, December 12, 13.
Struts 2.0 an Overview ( )
The SAM-Grid Fabric Services Gabriele Garzoglio (for the SAM-Grid team) Computing Division Fermilab.
CLEO’s User Centric Data Access System Christopher D. Jones Cornell University.
The Design Discipline.
Framework for Automated Builds Natalia Ratnikova CHEP’03.
Gaudi Framework Tutorial, April Introduction.
© 2007 Pearson Education, Inc. Publishing as Pearson Addison-Wesley 1 Architectural Styles.
Nick Brook Current status Future Collaboration Plans Future UK plans.
N ATIONAL E NERGY R ESEARCH S CIENTIFIC C OMPUTING C ENTER Charles Leggett The Athena Control Framework in Production, New Developments and Lessons Learned.
Event Data History David Adams BNL Atlas Software Week December 2001.
Requirements as Usecases Capturing the REQUIREMENT ANALYSIS DESIGN IMPLEMENTATION TEST.
Introduction to Gaudi LHCb software tutorial - September
N ATIONAL E NERGY R ESEARCH S CIENTIFIC C OMPUTING C ENTER Charles Leggett Updates to Interval of Validity Service (IOVSvc) ATLAS Software Week Dec
A Technical Validation Module for the offline Auger-Lecce, 17 September 2009  Design  The SValidStore Module  Example  Scripting  Status.
Framework for MDO Studies Amitay Isaacs Center for Aerospace System Design and Engineering IIT Bombay.
N ATIONAL E NERGY R ESEARCH S CIENTIFIC C OMPUTING C ENTER Charles Leggett Interval of Validity Service IOVSvc ATLAS Software Week May Architecture.
N ATIONAL E NERGY R ESEARCH S CIENTIFIC C OMPUTING C ENTER Charles Leggett Interval of Validity Service IOVSvc EDM Workshop Detector Description Session.
Model View Controller MVC Web Software Architecture.
Apr. 8, 2002Calibration Database Browser Workshop1 Database Access Using D0OM H. Greenlee Calibration Database Browser Workshop Apr. 8, 2002.
GDB Meeting - 10 June 2003 ATLAS Offline Software David R. Quarrie Lawrence Berkeley National Laboratory
- Early Adopters (09mar00) May 2000 Prototype Framework Early Adopters Craig E. Tull HCG/NERSC/LBNL ATLAS Arch CERN March 9, 2000.
David Adams ATLAS DIAL: Distributed Interactive Analysis of Large datasets David Adams BNL August 5, 2002 BNL OMEGA talk.
GLAST LAT Offline SoftwareCore review, Jan. 17, 2001 Review of the “Core” software: Introduction Environment: THB, Thomas, Ian, Heather Geometry: Joanne.
23/2/2000Status of GAUDI 1 P. Mato / CERN Computing meeting, LHCb Week 23 February 2000.
DØ Offline Reconstruction and Analysis Control Framework J.Kowalkowski, H.Greenlee, Q.Li, S.Protopopescu, G.Watts, V.White, J.Yu.
CPSC 871 John D. McGregor Module 8 Session 1 Testing.
N ATIONAL E NERGY R ESEARCH S CIENTIFIC C OMPUTING C ENTER Charles Leggett Colors in the Message Service ATLAS software workshop March Architecture.
 An essential supporting structure of any thing  A Software Framework  Has layered structure ▪ What kind of functions and how they interrelate  Has.
N ATIONAL E NERGY R ESEARCH S CIENTIFIC C OMPUTING C ENTER Charles Leggett Interval of Validity Service IOVSvc ATLAS Software Week Architecture Session.
- LCG Blueprint (19dec02 - Caltech Pasadena, CA) LCG BluePrint: PI and SEAL Craig E. Tull Trillium Analysis Environment for the.
General requirements for BES III offline & EF selection software Weidong Li.
Hyperion Artifact Life Cycle Management Agenda  Overview  Demo  Tips & Tricks  Takeaways  Queries.
Lecture VIII: Software Architecture
Source Level Debugging of Parallel Programs Roland Wismüller LRR-TUM, TU München Germany.
CERN Tutorial, February Introduction to Gaudi.
- GMA Athena (24mar03 - CHEP La Jolla, CA) GMA Instrumentation of the Athena Framework using NetLogger Dan Gunter, Wim Lavrijsen,
INFSO-RI Enabling Grids for E-sciencE Using of GANGA interface for Athena applications A. Zalite / PNPI.
THE EYESWEB PLATFORM - GDE The EyesWeb XMI multimodal platform GDE 5 March 2015.
N ATIONAL E NERGY R ESEARCH S CIENTIFIC C OMPUTING C ENTER Charles Leggett Prototype GEANT4 Service for ATHENA framework ATLAS Software Workshop Dec 3.
David Adams ATLAS ATLAS Distributed Analysis and proposal for ATLAS-LHCb system David Adams BNL March 22, 2004 ATLAS-LHCb-GANGA Meeting.
Expense Tracking System Developed by: Ardhita Maharindra Muskan Regmi Nir Gurung Sudeep Karki Tikaprem Gurung Date: December 05 th, 2008.
Peter ClarkeATLAS software week / Berkley 9-13 May 2000ATLFAST status report Status of ATLFAST integration into Gaudi P.Clarke H.Phillips E. Richter-Was.
Active-HDL Server Farm Course 11. All materials updated on: September 30, 2004 Outline 1.Introduction 2.Advantages 3.Requirements 4.Installation 5.Architecture.
VI/ CERN Dec 4 CMS Software Architecture vs Hybrid Store Vincenzo Innocente CMS Week CERN, Dec
David Adams ATLAS Hybrid Event Store Integration with Athena/StoreGate David Adams BNL March 5, 2002 ATLAS Software Week Event Data Model and Detector.
N ATIONAL E NERGY R ESEARCH S CIENTIFIC C OMPUTING C ENTER Charles Leggett Transient Conditions/Detector Store using StoreGate ATLAS Software Workshop.
Software Design Refinement Using Design Patterns
Architecture Concept Documents
Migration of reconstruction and analysis software to C++
Software Design and Architecture
Introduction to Gaudi LHCb software tutorial - December 2010.
John D. McGregor Session 9 Testing Vocabulary
John D. McGregor Session 9 Testing Vocabulary
SW Architecture SG meeting 22 July 1999 P. Mato, CERN
Object Networks—ATLAS' Future Control Framework For Offline?
Raw Event Conversion Service in BOSS framework
What’s new in version 4 of GAUDI
CMS Software Architecture
Introduction to Gaudi Schedule: Timing Topic 20 minutes Lecture
Use Of GAUDI framework in Online Environment
Planning next release of GAUDI
Modifications in Gaudi v5 release:
Presentation transcript:

N ATIONAL E NERGY R ESEARCH S CIENTIFIC C OMPUTING C ENTER 1 ACAT 2000, Fermilab Oct Control States... Control States for the Atlas Software Framework Paolo Calafiura, LBL ACAT 2000 Fermi Lab, October

N ATIONAL E NERGY R ESEARCH S CIENTIFIC C OMPUTING C ENTER 2 ACAT 2000, Fermilab Oct Control States... The Atlas Software Architecture  Overall design principles specified Dec 99 by the Architecture Task Force –data and algorithm object separation –proxy data access using a “Transient Data Store” –no direct module-to-module communication –traditional control flow –technology-independent database access layer  Athena Framework prototype implementation –based on the existing Gaudi architecture effort (initiated by LHCb)

N ATIONAL E NERGY R ESEARCH S CIENTIFIC C OMPUTING C ENTER 3 ACAT 2000, Fermilab Oct Control States... Control Framework The control framework is the part of an infrastructure that makes sure that –The right piece of software –Runs –At the right time –With the right inputs and –The outputs go to the right place (Lassi Tuura)

N ATIONAL E NERGY R ESEARCH S CIENTIFIC C OMPUTING C ENTER 4 ACAT 2000, Fermilab Oct Control States... GAUDI Architecture Converter Algorithm Event Data Service Persistency Service Data Files Algorithm Transient Event Store Detec. Data Service Persistency Service Data Files Transient Detector Store Message Service JobOptions Service Particle Prop. Service Other Services Histogram Service Persistency Service Data Files Transient Histogram Store Application Manager Converter

N ATIONAL E NERGY R ESEARCH S CIENTIFIC C OMPUTING C ENTER 5 ACAT 2000, Fermilab Oct Control States... Definitions  Algorithm (Module) –Atomic unit (visible & controlled by framework) of calculation and/or processing.  ApplicationMgr –creates and initializes Services and Algos. Drives the Algorithms processing  Data Object (Collection) –Atomic unit (visible & managed by transient data store) of data. NOT necessarily a dumb data object.  Transient Event (Data) Store –Central service and repository for data objects. Provides data location, data object life cycle management, transparent smart pointer/data converter interaction. –Also Transient Histogram & Detector Stores  Data Converter –Provides explicit (some implicit soon) conversion from “arbitrary” persistent data format (ie. ZEBRA, Objectivity, etc.) to transient data object.  Services –Globally available software components providing framework functionality.  Properties –Control and data parameters for Algorithms and Services.  Job Options File –Text file defining configuration and properties. (from Craig Tull’s Gaudi Tutorial Introduction)

N ATIONAL E NERGY R ESEARCH S CIENTIFIC C OMPUTING C ENTER 6 ACAT 2000, Fermilab Oct Control States...

N ATIONAL E NERGY R ESEARCH S CIENTIFIC C OMPUTING C ENTER 7 ACAT 2000, Fermilab Oct Control States... The Application Manager AppMgr Input Algorithms State Methods HitFinderTracker Initialize ExecuteFinalize Initialize ExecuteFinalize

N ATIONAL E NERGY R ESEARCH S CIENTIFIC C OMPUTING C ENTER 8 ACAT 2000, Fermilab Oct Control States... What’s wrong?  For most use cases, nothing really...  Too much coupling among Algos and the ApplicationMgr: –each and every algo must implement 3 and only 3 transitions: initialize, execute and finalize  Use cases not easily covered by this approach –Event filtering: I/O modules must handle disk file open/close actions –Calibration: must handle stepping of input signal –Simulation: pile-up of events coming from multiple streams  Don’t want to require each algorithm to handle a “file opened” action

N ATIONAL E NERGY R ESEARCH S CIENTIFIC C OMPUTING C ENTER 9 ACAT 2000, Fermilab Oct Control States... The Control States Framework InitNewRecordFinalize Sources States Modules State Methods HitFinder Tracker

N ATIONAL E NERGY R ESEARCH S CIENTIFIC C OMPUTING C ENTER 10 ACAT 2000, Fermilab Oct Control States... The Core Classes  State Source –drive the framework generating actions  State (and Concrete States) –observe sources for matching actions, run module methods  Modules –handle state transitions, adding matching state methods to their queues

N ATIONAL E NERGY R ESEARCH S CIENTIFIC C OMPUTING C ENTER 11 ACAT 2000, Fermilab Oct Control States... Features  Support multiple event sources (e.g. for pile-up studies)  Notify modules only about the transitions they may be interested into –Notification is type-safe: only modules implementing the “right” state transition interface can be notified.  Control (or, optionally, suggest) the order in which the modules handle transitions (ATF requirement)  Define the states, the order of modules and the state sources, dynamically via the User Interface  No physical coupling between the ApplicationMgr and the modules: –states can be added or removed without triggering massive recompilations

N ATIONAL E NERGY R ESEARCH S CIENTIFIC C OMPUTING C ENTER 12 ACAT 2000, Fermilab Oct Control States... Implementation  As usual we added a level of indirection (actually two): –each source is an Observable generating actions (=states) –each state is a typed Observable that notifies its registered modules when it observes the corresponding action (in a sense each state is a separate control framework)  A Module implements a separate interface for each action he can handle  It looks very much like the Typed Message/MultiCast pattern (J. Vlissides, “Pattern Hatching”, great book)

N ATIONAL E NERGY R ESEARCH S CIENTIFIC C OMPUTING C ENTER 13 ACAT 2000, Fermilab Oct Control States... Scenario: Running a State  The source notifies all registered states that he has a newRecord action StateSource::notify DEBUG: notifying newRecord  newRecord state catches the action and notifies its observers, the managers State::update DEBUG: newRecord[instanceof NewRecordState] got message newRecord  Each manager add the matching method to the state queue  Now newRecord runs the scheduled methods State::run DEBUG: newRecord[instanceof NewRecordState] starts Hitfinder::newRecord DEBUG: running State::run WARNING: newRecord[instanceofHitFinder::__newRecord] was not ready and had to be rescheduled Histogrammer::newRecord DEBUG: running Hitfinder::newRecord DEBUG: running

N ATIONAL E NERGY R ESEARCH S CIENTIFIC C OMPUTING C ENTER 14 ACAT 2000, Fermilab Oct Control States... Where do we stand?  We have a web page  We have a prototype –Integrated in Atlas SRT can get a stand alone version from URL above –Integration with the ApplicationMgr (being rewritten) in progress  Use it to explore interactions with other new domains –Scripting/User Interface –Event Data Model (next talk, VLSC305)

N ATIONAL E NERGY R ESEARCH S CIENTIFIC C OMPUTING C ENTER 15 ACAT 2000, Fermilab Oct Control States... Thanks to  So many people that I’ll sure forget some: –Vincenzo Innocente –Jim Kowalkowski –Charles Leggett –Pere Mato –John Milford –Dave Quarrie –Marjorie Shapiro –Lassi Tuura –Craig Tull –Laurent Vacavant

N ATIONAL E NERGY R ESEARCH S CIENTIFIC C OMPUTING C ENTER 16 ACAT 2000, Fermilab Oct Control States... Lassi’s Object Networks  Colors = data types  Modules = behavior  Whole network = component  Input-output dependency

N ATIONAL E NERGY R ESEARCH S CIENTIFIC C OMPUTING C ENTER 17 ACAT 2000, Fermilab Oct Control States...

N ATIONAL E NERGY R ESEARCH S CIENTIFIC C OMPUTING C ENTER 18 ACAT 2000, Fermilab Oct Control States... The Module class  Define a Module class that provides access to the core services: class Module : virtual public IModule, virtual public IProperty, virtual public TEventHandler { public: IMessageSvc* msgSvc(); template StatusCode service(const std::string& name, T*& svc); … }

N ATIONAL E NERGY R ESEARCH S CIENTIFIC C OMPUTING C ENTER 19 ACAT 2000, Fermilab Oct Control States... Setting up - a sample script  associate States and StateSources StateSource rawFile(inputFile) next_Record.attach(rawFile)  define Sequences of components to be executed sequence all = { "hitFinder", "tracker", "myanal" } sequence reco = { "tracker", "myanal"}  define State transitions, with usual flow-control constructs next_run.run("all") while (next_Record.run("all")) { fill_histos.run("reco") fill_Bhistos.run("paolo") }

N ATIONAL E NERGY R ESEARCH S CIENTIFIC C OMPUTING C ENTER 20 ACAT 2000, Fermilab Oct Control States... Running  The framework runs States following the script order.  Control returns to the framework after each state completes  The State tries to run each registered module in order  The module determines the status of its associated method, run it if ready, and report to the State.  The Object Network (or a Data Manager) notifies modules when their Parameters are ready or change.  The State may re-queue a module which is NotReady.

N ATIONAL E NERGY R ESEARCH S CIENTIFIC C OMPUTING C ENTER 21 ACAT 2000, Fermilab Oct Control States... Scenario: Running a State

N ATIONAL E NERGY R ESEARCH S CIENTIFIC C OMPUTING C ENTER 22 ACAT 2000, Fermilab Oct Control States... Scenario: Setting Up  First we define the state classes DEFINE_CTRL_STATE(NewJobStateS) DEFINE_CTRL_STATE(NewRunState) DEFINE_CTRL_STATE(NewRecordState)  Then we create the module managers HitFinderMgr hitFinder; HistogrammerMgr myHistos;  We create the states instances and we register the module with them. NewJobState newJob("newJob"); newJob.addIObserver(&myHistos); newJob.addIObserver(&hitFinder);  Finally we create the state source and register the states with it. StateSource testSource("testSource"); testSource.addIObserver(&newJob); testSource.addIObserver(&newRun); testSource.addIObserver(&newRecord);

N ATIONAL E NERGY R ESEARCH S CIENTIFIC C OMPUTING C ENTER 23 ACAT 2000, Fermilab Oct Control States...