Skip to content

psana.psexp.null_ds

NullDataSource is returned by DataSource to MPI ranks that read no data: with shmem=, the first PS_SRV_NODES ranks; with exp= in MPI mode with more than one rank, every rank that is not an smd0, eb or bd rank (see psana.datasource). Its runs() yields one NullRun, which has no events and no steps. is_srv() returns True, and unique_user_rank() and is_bd() return False.

See MPI parallel analysis.

psana.psexp.null_ds

A data source and run that contain no data.

psana.DataSource returns NullDataSource to MPI ranks that do not read data (for example the smalldata server ranks).

NullRun

NullRun()

Bases: object

Run stand-in with no data.

expt and runnum are None, epicsinfo and detinfo are empty dicts, and the event and step iterators are empty.

Detector

Detector(*args)

Return None for any arguments.

events

events()

Return an empty iterator.

steps

steps()

Return an empty iterator.

close_shared_memory

close_shared_memory()

Do nothing; returns None.

NullDataSource

NullDataSource(*args, **kwargs)

Bases: DataSourceBase

Data source for ranks that read no data; runs() yields one NullRun.

The constructor passes the keyword arguments to DataSourceBase.__init__, creates a SmallData object from self.smalldata_kwargs, calls setup_psplot_live() on smalldata rank 0, and starts the Prometheus client with the MPI world rank. __del__ stops the Prometheus client.

runs

runs()

Yield a single NullRun.

is_mpi

is_mpi()

Return False.

unique_user_rank

unique_user_rank()

NullDataSource is used for srv nodes, therefore not a 'user'-unique rank.

is_srv

is_srv()

Return True.

is_bd

is_bd()

Return False.