Skip to content

lstautorta.config.hdf5_data_check

Classes:

Name Description
HDFDataCheckConfiguration

Configures what/how to plot in a data level auto_check routines

HDFDataCheckConfiguration

Bases: BaseModel


              flowchart TD
              lstautorta.config.hdf5_data_check.HDFDataCheckConfiguration[HDFDataCheckConfiguration]

              

              click lstautorta.config.hdf5_data_check.HDFDataCheckConfiguration href "" "lstautorta.config.hdf5_data_check.HDFDataCheckConfiguration"
            

Configures what/how to plot in a data level auto_check routines

Source code in src/lstautorta/config/hdf5_data_check.py
class HDFDataCheckConfiguration(BaseModel):
    """Configures what/how to plot in a data level auto_check routines"""

    column_to_datetime: list[str] | None = Field(
        title="Timestamps columns",
        description="List of columns (before re-name!) to cast from timestamp to datetime (unit=s)",
        examples=["trigger_time"],
    )
    data_path_in_hdf5: str = Field(
        title="Data Key in HDF5",
        description="Full path to the pytables Table containing the data to plot in the hdf5 files",
        examples=["/dl1/event/telescope/parameters/LST_LSTCam"],
    )
    hdf5_open_nb_retries: Annotated[int, Gt(0)] = Field(
        title="Number of HDF5 reading tries",
        description="Number of times to try to read an HDF5 file that may be locked by another process",
        examples=[20],
    )
    hdf5_open_wait_time_s: Annotated[float, Gt(0)] = Field(
        title="HDF5 reading re-try wait time",
        description="Amount of time in second to wait before re-trying to read an HDF5 file.",
        examples=[0.5],
    )
    plots_config: dict[str, PlotConfiguration] = Field(
        title='Mapping of plots path ("name.png") to plot configuration',
        description="Mapping between a plot png path to a plot configuration",
        examples=[
            {
                "Event ID": {
                    "kind": "hist",
                    "kwargs": {"x": "total_intensity", "alpha": 0.5, "bins": 100, "log_scale": (True, True)},
                }
            }
        ],
    )
    plot_refresh_interval_s: float = Field(
        title="Plot Refresh Interval",
        description="Amount of time in seconds between 2 plot of the data",
        examples=[10.0],
    )
    size_storage_dataframe: Annotated[int, Gt(0)] = Field(
        title="Accumulation DataFrame Size",
        description="Number of rows to allocate to the DataFrame used to accumulate the files data. "
        "Should be large enough to easily be more than 1 run's number of events, eg 15 000 * 60*40 (15kHz for 40min)",
        examples=[36000000],
    )
    write_df_store_key: str = Field(
        title="Written DF key in hdf5",
        description="Path in the written HDF5 files of the DataFrames data.",
        examples=["auto_check_df"],
    )