Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: discussed Python modules, reworded last section, mentioned users software repository

...

The central part of the framework is a regular pre-built application (psana) which can dynamically load one or more user analysis modules which are written in C++ or Python. The core application is responsible for the following tasks:

  • loading and initializing all user modules
  • loading one of the input modules to read data from XTC or HDF5
  • calling appropriate methods of user modules based on the data being processed
  • providing access to data as set of C++ classes and a set of Python classes
  • providing other services such as histogramming to user modules

...

  • user module – instance of the C++ or Python class which inherits pre-defined Module class and defines few special methods which are called by the framework
  • event – special object which transparently stores all event data
  • environment – special object which stores non-event data such as configuration objects or EPICS data

...

Typically psana will iterate through all transitions/events from the input files. User modules have a limited control over this event loop, module can request to skip particular event, stop iteration early or abort job using one of the methods described below.

User Modules

User module in psana is A user module provides an instance of a class that inherits from the Psana Module class. Below we discuss this for C++ class which inherits from the . The Psana Module class (is defined in the file pasanapsana/Module.h) and implements several methods. These methods are already mentioned above, here is more formal description of each method:

...

In addition to event() method every module class must provide a constructor which takes a string argument giving the name of the module. Additionally it has to provide a special factory function use used to instantiate the modules from the shared libraries, there is special macro defined for definition of this factory function.

...

We permanently work on algorithms implemented in continually develop algorithms for the standard set of the psana modules. If you find that the algorithm which you need is missing in our collection you have two options:

...

we would be interested in hearing about it (email pcds-help@slac.stanford.edu). We are interested in implementing algorithms that are useful to our users. Of course, following this document, you can develop a Psana modules that implements the algorithm. A resource for sharing the module is the Users' Software Repository.