Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: Migrated to Confluence 4.0
Table of Contents
maxLevel3

Package pyana

Module event

Class Event

Construction

Usage: evt = Event(dg)

Creates event object from the corresponding XTC datagram object.

Parameters:

  • dg – datagram object of type _pdsdata.xtc.Dgram

Method seq()

Usage: s = evt.seq()

Returns _pdsdata.xtc.Seq object, equivalent to dg.seq

Method getTime()

Usage: t = evt.getTime()

Returns _pdsdata.xtc.ClockTime object, equivalent to dg.seq.clock()

Method find()

Usage: objects = evt.find(...)

Returns possibly empty list of data objects contained in the event. This method accepts a number of arguments, but all arguments are optional. If no arguments are given then a list of all data objects is returned. If some arguments are given then only those objects that satisfy a particular criteria are returned. The list of possible keyword arguments:

  • typeId – accepts one of the xtc.TypeId.Type.<Xxx>, only return objects which have that TypeId
  • version – accepts number, only return objects whose type version number is equal to number
  • level – accepts one of xtc.Level.<Xxx> values, only returns objects originated at that level
  • detector – accepts one of xtc.DetInfo.Detector.<Xxx> values, only returns objects produced by this detector
  • detId – accepts number, only returns objects produced by this detector ID
  • device – accepts one of xtc.DetInfo.Device.<Xxx> values, only returns objects produced by this device
  • devId – accepts number, only returns objects produced by this device ID
  • addressxtc.DetInfo object or an address string (see User Manual)

The parameters address and any of the detector, detId, device, devId are incompatible, specify only one or another.

Method findFirst()

Usage: object = evt.findFirst(...)

Accepts the same set of arguments as find() methods but instead of list of objects returns fist object found. If no object is satisfying all selection criteria then None is returnedReference for pyana modules and classes is auto-generated from source code in every release. To see reference for current production release (ana-current) follow this link.