23.05.2014 Views

Athena Developer Guide

Athena Developer Guide

Athena Developer Guide

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

<strong>Athena</strong><br />

Chapter 8 StoreGate - the event data access model Version/Issue: 2.0.0<br />

8.7 Store Access Policy<br />

The current release (Release 1.3.2) has some of the tools to implement a flexible access policy to<br />

objects stored in the TDS. The TDS owns the DataObjects that have been recorded into it. A<br />

DataObject in the store may not be deleted by the client code. Client code is allowed to modify objects<br />

in the store but only until the DataObject is declared ``complete'' and “set constant” (locked) by its<br />

creator.<br />

Locking an object prevents the clients downstream of the creator to modify the reconstructed objects<br />

by mistake. For example, a tracking algorithm that retrieves a hit collection from the store does not own<br />

those hits and therefore may not modify them. Remember that these hits can be used later by another<br />

tracking algorithm for which your modifications may be meaningless or even plain wrong. We do not<br />

want the results of the second tracking algorithm to change when you run the second algorithm before<br />

or after the first! If we want to have reproducible results from several million lines of reconstruction<br />

code it is vital to preserve the state of every DataObject which has been reconstructed and ``published''<br />

in the TDS to be used by others. However, well controlled modifications are desirable. The access<br />

policy allows multiple algorithms to collaborate in reconstructing a DataObject. As an example,<br />

consider a Calorimeter Clustering package makes cluster objects and subsequently may make<br />

corrections, based on the Calorimeter information alone that are independent of any downstream<br />

analysis. Since cluster finding and corrections are more or less independent, it may be desirable to have<br />

the two decoupled: a cluster-finding sub-algorithm and a correction sub-algorithm executed in some<br />

Cluster-Maker Algorithm environment. In such a scenario:<br />

• The cluster-finding sub-algorithm will create the cluster object and record it in the TDS.<br />

• The correction sub-algorithm will retrieve the cluster object from the TDS and perform some<br />

correction (hence modifying the object in the TDS).<br />

• The main Cluster-Maker algorithm that coordinates the various factions of the calorimeter<br />

clustering will lock the object before returning control to the framework<br />

• A downstream electron-finding algorithm can use these cluster objects in a readonly mode and<br />

create a new electron object. Additional corrections may be determined and included in the<br />

calculation of quantities of the final electron object, but the data of the original cluster object<br />

cannot be changed. These additional correction, if necessary, must be preserved elsewhere.<br />

• Note that it may be necessary for downstream algorithms to redo the clustering based on new<br />

information that has become available only at a later stage. This is indeed possible - it may do<br />

so, by creating a new cluster collection in the TDS. Since cluster collections in TDS can be<br />

keyed (and later can also be associated with a history object), these are uniquely identifiable<br />

objects in the TDS.<br />

page 67

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!