Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Code Block
languagenone
collapsetrue
==================
=== begin job ====
# first the epics aliases are printed during begin job.
Epics Aliases: total = 250240
  Be_xpos
  Be_ypos
  Be_zpos
  ... 
# next the epics pv, as they appear during beginJob.
# This corresponds to the xtc configure transition. 
# At this point, these are ctrl pvs. T
Epics PV
  pvName=HFXHX2:DVD:DG2GCC:MMS01:08.RBVPMON  pvid=117106 dbrtype=34 isCtrl=1 pvName=HX2:DVD:GCC:01:PMON numElements=1 status=0 severity=0 units=mmT upper_disp_limit=1.9500e+0000e-02 lower_disp_limit=-20.0500e0000e+0200 upper_alarm_limit=0.0000e+00 upper_warning_limit=0.0000e+00 lower_warning_limit=0.0000e+00 lower_alarm_limit=0.0000e+00 upper_ctrl_limit=1.9500e+0000e-02 lower_ctrl_limit=-20.0500e0000e+0200 data=4.2898e+015.0000e-09
  ...
# After epics, we get the content of the psana env configStore. 
# The dump module is getting all keys from the configStore(), 
# then retrieving each object. Objects that have a xtc type id, or are
# an numpy array will be printed.

# For each object, we first get a string describing the even key:

type=psana.ControlData.ConfigV2, src=ProcInfo(0.0.0.0, pid=7670)

  # then we get the data of the object. Each method is called
  # most all data for a Psana object is obtained through accessor methods.
  # methods that return unsigned ints print in hex. 
  # methods that return signed ints print in decimal.
  # methods that return floats print in scientific format with 4 decimals of precision.

  npvControls: 0x1      
  npvMonitors: 0x0    
  npvLabels: 0x0
  events: 0x1E0
  uses_duration: 0x0
  uses_events: 0x1

# methods that return a complexcompound type, like time, will get methods of the complex type indented duration() that returns the compound type time
# are printed as follows:
  duration:
    nanoseconds: 0x0
    seconds: 0x0

# some methods that return a python list. Each element in the list is printed separately:
  pvControls[0]:
    name: las_lensh
    index: 0xFFFFFFFF
    value: 0.0000e+00
    array: 0x0
  ...

# epics config is not dumped, assee itthe isEPICS redundantalias withlist whatfor ishow inPsana thestores epicsthis storedata
type=psana.Epics.ConfigV1, src=DetInfo(EpicsArch.0:NoDevice.0)
  epicsConfig not dumped

# cspad config is an example which has methods that return ndarrays
type=psana.CsPad.ConfigV4, src=DetInfo(XppGon.0:Cspad.0)
  ...
  numSect: 0x20
  # some methods return a list of simple types, these are printed in one line
  roiMask [0]=0xFF [1]=0xFF [2]=0xFF [3]=0xFF
  numAsicsStored [0]=0x10 [1]=0x10 [2]=0x10 [3]=0x10
  ...
  quads[0]:
    ...    
    dp:
      # for an ndarray, we print the type, dimensions, adler32 checksum, and quartile
      # statistics (min, 25th percentile, median, 75th percentile, and max):
      pots: ndarray_uint8_1: dim=[ 80 ] adler32=0x231B31F5 min=0x0 25th=0x3F median=0xB0 75th=0xFF max=0xFF
    gm:
      gainMap: ndarray_uint16_2: dim=[ 185 x 194 ] adler32=0x18730001 min=0x0 25th=0x0 median=0x0 75th=0x0 max=0x0
   ...

===============================================================
=== beginrun 0 ===            # typically, there is nothing new in beginrun
===============================================================
=== begincalibcycle run=0 step=0 ===

# having dumped the entire initial contents of epics and the config store, 
# the dump module will now only print changes to epics or the config.
# That is it remembers how each epics pv and config object printed the last 
# time it saw it. With each new transition, it looks at all the epics pv and
# config objects. If any change, they are dumped.

# The control data changed in the calib cycle:

type=psana.ControlData.ConfigV2, src=ProcInfo(0.0.0.0, pid=7670)
  npvControls: 0x1
  npvMonitors: 0x0
  npvLabels: 0x0
  events: 0x1E0
  uses_duration: 0x0
  uses_events: 0x1
  duration:
    nanoseconds: 0x0
    seconds: 0x0
  pvControls[0]:
    name: las_lensh
    index: 0xFFFFFFFF
    value: -4.9997e-01
    array: 0x0

# next we see event data, printing the following:
===============================================================
=== event: run=0 step=0 event=0 seconds= 1362889345 nanoseconds= 770371931 fiducials= 19593
# at this point, all epics pv's are replaced with TIME pv's, not the stamp.sec, stamp.nsec below:
Epics PV
  pvName=OTRSHX2:DVD:DMP1GCC:69501:FLT2_PNEUPMON  pvid=87106 dbrtype=1720 isTime=1 numElements=1 status=170 severity=30 stamp.sec=0731737344 stamp.nsec=0 data=0x0
  pvName=OTRS:DMP1:695:Image:ArrayData  pvid=81 dbrtype=19 isTime=1 numElements=1424 status=0 severity=0 stamp.sec=765084864 stamp.nsec=401243855 data=ndarray_int32_1: dim=[ 1424 ] adler32=0xA4FBE55A min=71 25th=117 median=132 75th=149 max=223134374000 data=5.2000e-09
  ...
# while most epics pv's have one value, there are some with more than one,. suchIf asa ArrayDataEPICS above. If it pv has less than 20 values, they are all printed, otherwise anthe typical arrayndarray summary of the data is printed, as above.

# now we get into regular event data
type=psana.EvrData.DataV3, src=DetInfo(NoDetector.0:Evr.0)
  numFifoEvents: 0x2
  fifoEvents[0]:
    timestampHigh: 0x4C89
    timestampLow: 0x32A6
    eventCode: 0x29
  fifoEvents[1]:
    timestampHigh: 0x4C89
    timestampLow: 0x2E4C
    eventCode: 0x8C
type=psana.CsPad.DataV2, src=DetInfo(XppGon.0:Cspad.0)
  quads[0]:
    seq_count: 0x1
    ticks: 0x329D
    fiducials: 0x4C89
    sb_temp: ndarray_uint16_1: dim=[ 4 ] adler32=0x4FC00AC min=0x7 25th=0x8 median=0x9 75th=0x291 max=0x291
    frame_type: 0x4
    data: ndarray_int16_3: dim=[ 8 x 185 x 388 ] adler32=0xAD5ACF7F min=0 25th=1281 median=1346 75th=1475 max=16383
    virtual_channel: 0x0
    lane: 0x0
    tid: 0x0
    acq_count: 0x85
    op_code: 0x85
    quad: 0x0
    sectionMask: 0xFF
  quads[1]:
    seq_count: 0x1
    ticks: 0x329D
    fiducials: 0x4C89
    sb_temp: ndarray_uint16_1: dim=[ 4 ] adler32=0x2DB006A min=0x7 25th=0xA median=0xA 75th=0x34B max=0x34B
    frame_type: 0x4
    data: ndarray_int16_3: dim=[ 8 x 185 x 388 ] adler32=0xD28441BE min=0 25th=1316 median=1374 75th=1504 max=16383
    virtual_channel: 0x0
    lane: 0x0
    tid: 0x0
    acq_count: 0x85
    op_code: 0x85
    quad: 0x1
    sectionMask: 0xFF

...

Other options one could set are:

epics = False       do not print epics
aliases = False do not print the EPICS alias list
dump_aliases=True follow EPICS aliases to print the EPICS pv's they point to
regress_dump=True do not print the DAQ assigned pvId when printing EPICS
config = False do not print the contents of the configStore, only regular event data
counter = False do not print the counter string that labels event numbers and calib cycle numbers
indent = 4 change the indent from the default of 2 to 4

Library Usage

Two functions are provided in the Python psana_test package that allow Python scripts to turn Psana objects into strings. A Python script could include the following function to build dictionaries describing the state of the event, configStore, and epicsStore:

...