duration_from_timeMethod¶
- lsst.utils.timer.duration_from_timeMethod(metadata: MutableMapping | None, method_name: str, clock: str = 'Cpu') float | None¶
- Parse the metadata entries from - timeMethodand return a duration.- Parameters:
- metadatacollections.abc.MutableMapping
- The Task metadata that timing metrics were added to. 
- method_namestr
- Name of the timed method to extract a duration for. 
- clockstr, optional
- Options are “Cpu”, “User”, “System”, or “Utc”. 
 
- metadata
- Returns:
- durationfloat
- The time elapsed between the start and end of the timed method. 
 
- duration