140 likes | 282 Views
DANA. David Lawrence Oct. 21, 2005. Outline. Requirements Philosophy Overview of Features Open Questions. Requirements. Modular Reconstruction Allow independent development of reconstruction code for independent detector systems
E N D
DANA David Lawrence Oct. 21, 2005
Outline • Requirements • Philosophy • Overview of Features • Open Questions D. Lawrence, JLab GlueX Software Workshop Oct. 2005
Requirements • Modular Reconstruction • Allow independent development of reconstruction code for independent detector systems • Easy to make customized programs that do only partial reconstruction • Consistency • Single mechanism for database access • Calibration constants • Parameters • Geometry Information • Interface for passing data between modules • Multi-threading • Shallow Learning Curve - Are we there? D. Lawrence, JLab GlueX Software Workshop Oct. 2005
Factory Paradigm D. Lawrence, JLab GlueX Software Workshop Oct. 2005
Event Loops and Threads D. Lawrence, JLab GlueX Software Workshop Oct. 2005
Event Sources and Sinks • The API for dealing with event sources is defined by the DEventSource base class • The API for dealing with event sinks (files) is defined by the DEventSink base class • New sources and sinks can be added at any time without affecting user code D. Lawrence, JLab GlueX Software Workshop Oct. 2005
Data Objects • All data objects inherit from DObject • DObject provides the object with an identifier that, unlike pointers, can be used outside the context of the program class DHit : public DObject { public: float x,y,z; HDCLASSDEF(DHit); } D. Lawrence, JLab GlueX Software Workshop Oct. 2005
DANA Features D. Lawrence, JLab GlueX Software Workshop Oct. 2005
DANA uses Templates • Templates add better type checking while relieving the programmer of some responsibility vector<const DTrack*> tracks; loop->Get(tracks); D. Lawrence, JLab GlueX Software Workshop Oct. 2005
Factory Tags Tags are free-form strings that allow more than one factory to produce the same class of data objects. Factory tags are specified as an optional 2nd argument to DEventLoop::Get() vector<const DTrack*> tracks; loop->Get(tracks, “LowResolution”); D. Lawrence, JLab GlueX Software Workshop Oct. 2005
Configuration Parameters • Parameters are simple key/value pairs. • Database of parameters built up from factories at run time: maxhits=10; // int dparms.SetDefaultParameter(“TRK:maxhits”, maxhits); • Parameters can be modified at program startup and the database can be recorded in output D. Lawrence, JLab GlueX Software Workshop Oct. 2005
Other DANA Features • Data on demand • Shared Objects • Universal treatment of DObjects • Uses STL vectors for passing const pointers • Optional filter routine argument D. Lawrence, JLab GlueX Software Workshop Oct. 2005
Open Questions • Are any major changes needed? • What do we put in DObject? (toString(), isA(), …) • How to implement identifiers • Introspection and I/O • 4-vector class? Histogram classes? • Move headers out of src/libraries/include e.g. #include “FDC/DFactory_DFDCHit.h” • Access to auxiliary information D. Lawrence, JLab GlueX Software Workshop Oct. 2005