Take observation time from GTI table
@@ -248,6 +248,9 @@ class DataStoreObservation(object):
The wall time, including dead-time.
"""
+ try:
+ return self.gti.time_sum
+ except IndexError: # HDU index file does not contain the GTI table
return Quantity(self.obs_info["ONTIME"], "second")
@lazyproperty
@@ -259,6 +262,9 @@ class DataStoreObservation(object):
Computed as ``t_live = t_observation * (1 - f_dead)``
where ``f_dead`` is the dead-time fraction.
"""
+ try:
+ return self.gti.time_sum * (1 - self.observation_dead_time_fraction)
+ except IndexError: # HDU index file does not contain the GTI table
return Quantity(self.obs_info["LIVETIME"], "second")
@lazyproperty
