Repository navigation
Add TimeGPS class to Time (=seconds since 1980-01-01 00:00:00 UTC = TAI -19 s - #1164
Conversation
|
Not sure why the travis build with sphinx failed. Suggestions? |
|
@mhvk - From what I understand (http://en.wikipedia.org/wiki/Global_Positioning_System#Timekeeping) GPS time is really a time scale, not a time format (which is what you implemented). It is defined by TAI - GPS = 19 sec. I suspect that your colleague would want to the following behavior: What you implemented will instead give a float number. In the case of Implementing a new time scale should not be too difficult, particularly in this case. |
|
@taldcroft - OK, I may have misunderstood what was requested; I've asked David to comment, and also pinged one of our local LIGO people, Kipp Cannon. |
|
@taldcroft - my colleague answered (I'll get him to contribute himself yet ;-):
Our local LIGO expert wrote
So, happily it seems I managed to get the use case right! |
There was a problem hiding this comment.
I was initially confused by the = 00:00:19 TAI part, so I would suggest removing that. The date of 1980-01-06 00:00:00 UTC is unique and corresponds to the definition that one sees everywhere.
It might be useful in the class docstring to include a reference to some fundamental page that defines GPS time, e.g. http://tycho.usno.navy.mil/gpstt.html. You should have the initial 'tagline' of GPS time: seconds ... and skip a line and then have more detailed explanation, which might include mentioning that this does include leap seconds.
|
OK, looks like this is mostly good, just some minor documentation comments. |
|
@taldcroft - OK, thanks, all good changes - now implemented. |
Add TimeGPS class to Time (seconds since 1980-01-06 00:00:00 UTC)
@taldcroft - I was asked by David Kaplan whether it would be possible to add a gps format for Time, since this is used a lot at MWA, apparently by LIGO as well, and seems generally useful. The pull request implements the
TimeGPSclass following theTimeCxcSecexample (aside: isn't that a bit Chandra-centric? What about poor XMM? ;-), and adds tests and documentation.