improve docstring and fix typo
@@ -258,8 +258,8 @@ class DataStore:
----------
obs_id : int
Observation ID.
- required_irf : list of str
- The list can inlcude the following options:
+ required_irf : list of str or str
+ The list can include the following options:
* `events` : Events
* `gti` : Good time intervals
* `aeff` : Effective area
@@ -267,6 +267,9 @@ class DataStore:
* `edisp`: Energy dispersion
* `psf` : Point Spread Function
* `rad_max` : Maximal radius
+ Alternatively single string can be used as shortcut:
+ * `full-enclosure` : ["events", "gti", "aeff", "edisp", "psf", "bkg"]
+ * `point-like` : ["events", "gti", "aeff", "edisp"]
Returns
-------
@@ -303,7 +306,7 @@ class DataStore:
required_irf : list of str or str
Runs will be added to the list of observations only if the
required HDUs are present. Otherwise, the given run will be skipped
- The list can inlcude the following options:
+ The list can include the following options:
* `events` : Events
* `gti` : Good time intervals
* `aeff` : Effective area
@@ -324,7 +327,7 @@ class DataStore:
"""
all_hdu = REQUIRED_IRFS["all-optional"]
- is_all_optinal = required_irf == "all-optional"
+ is_all_optional = required_irf == "all-optional"
if isinstance(required_irf, str) and required_irf in REQUIRED_IRFS.keys():
required_irf = REQUIRED_IRFS[required_irf]
@@ -350,7 +353,7 @@ class DataStore:
else:
raise err
- if is_all_optinal or set(required_irf).issubset(obs.available_hdus):
+ if is_all_optional or set(required_irf).issubset(obs.available_hdus):
obs_list.append(obs)
else:
log.warning(f"Skipping run with missing HDUs; obs_id: {_!r}")
