EventListDatasetChecker

class gammapy.data.EventListDatasetChecker(event_list_dataset, logger=None)[source]

Bases: object

Event list dataset checker.

Data format specification: ref:iact-events

Having such a checker is useful at the moment because the CTA data formats are quickly evolving and there’s various sources of event list data, e.g. exporters are being written for the existing IACTs and simulators are being written for CTA.

Parameters:

event_list_dataset : EventListDataset

Event list dataset

logger : logging.Logger or None

Logger to use (use module-level Gammapy logger by default)

Attributes Summary

accuracy

Methods Summary

check_coordinates() Check if various event list coordinates are consistent.
check_misc() Check misc basic stuff.
check_times() Check if various times are consistent.
run([checks]) Run checks.

Attributes Documentation

accuracy = OrderedDict([('time', <Quantity 1.0 us>), ('angle', <Angle 1.0 arcsec>)])

Methods Documentation

check_coordinates()[source]

Check if various event list coordinates are consistent.

Parameters:

event_list_dataset : EventListDataset

Event list dataset

accuracy : Angle

Required accuracy.

Returns:

status : bool

All coordinates consistent?

check_misc()[source]

Check misc basic stuff.

check_times()[source]

Check if various times are consistent.

The headers and tables of the FITS EVENTS and GTI extension contain various observation and event time information.

run(checks='all')[source]

Run checks.

Available checks: {...}

Parameters:

checks : list of str or “all”

Which checks to run

Returns:

ok : bool

Everything ok?