obspy.core.utcdatetime.UTCDateTime.__float__

UTCDateTime.__float__()[source]

Returns UTC timestamp in seconds.

Return type:float
Returns:Timestamp in seconds.

Example

>>> dt = UTCDateTime(2008, 10, 1, 12, 30, 35, 123456)
>>> float(dt)
1222864235.123456