It occurs to me that I should have given you the rendered pages as well.

Tom

On Sunday, November 10, 2019 at 11:12:39 AM UTC-8, Tom Kuiper wrote:
>
> In summary, when I do 'build html' the new index.html does not show 
> changes made in README.rst.
>
> The first time I ran 'make html' I just renamed README.md to be README.rst 
> and the build of course complained. I edited README.rst to use proper 
> restructured text mark up and did another build.  However, I did not catch 
> everything.  In particular, in one section had a one-line code section with
>  
> Jhhmm+ddmm, Bhhmm+ddmm and Gddd.d+dd.d
>   
> The "and" was rendered in green and everything following was not 
> rendered.  Instead, the unrendered restructured text is shown.  Fixing the 
> source file and rebuilding did not change the rendered version, even though 
> the time of the resulting index.html shows that it was newly generated.  
> The extra weird thing is that includeme.html is correct when I view it in 
> Chrome. I then did
>
> make clean
> Removing everything under '../../DatesTimes-docs'...
> make html
> Running Sphinx v1.8.0
> ...
> but still index.html was the incorrect version.  
>
> It must be that there is something intermediate between the file  
> README.rst and the generated index.html but it can't be includeme.html.  
> Could it be that 'make html' is doing something weird?  Makefile is very 
> simple.  Whatever is going wrong is in Sphinx itself.  Could it be a bug?
>
> Thanks and best regards.
>

-- 
You received this message because you are subscribed to the Google Groups 
"sphinx-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sphinx-users/263282b4-59ac-47c2-81bb-c92d0fbb0ed9%40googlegroups.com.
Title: DatesTimes — DatesTimes 0.9 documentation

DatesTimes

Conversions between various date and time formats

Date and Time Formats

VSR time tuples

The are of the form:

(YYYY,DDD,sssss)

where the latter is seconds since midnight.

VSR filename time strings

Used in the output files, these are text strings of the form:

YYYY DDD ssssss

where the latter is seconds since midnight.

VSR script time stamps

used in filenames are of the form:

DDD/HH:MM:SS

ISO timestamps

These are of the form:

YYYYMMDDTHHMMSS    or
YYYY-MM-DDTHH:MM:SS

Python times

take these forms:

*  ``time.time`` float::

   In [29]: time.time()
   Out[29]: 1501361397.04814

*  ``time.struct_time``::

   In [15]: time.gmtime(0)
   Out[15]: time.struct_time(tm_year=1970, tm_mon=1, tm_mday=1,
                             tm_hour=0,    tm_min=0, tm_sec=0,
                             tm_wday=3,    tm_yday=1, tm_isdst=0)

*  ``datetime.datetime`` object::

   In [16]: datetime.datetime.now()
   Out[16]: datetime.datetime(2017, 7, 29, 13, 31, 54, 963632)

*  ``datetime`` timetuple::

   In [32]: datetime.datetime(2, 1, 1, 0, 0, 0, 0).timetuple()
   Out[32]: time.struct_time(tm_year=2, tm_mon=1, tm_mday=1,
                             tm_hour=0, tm_min=0, tm_sec=0,
                             tm_wday=1, tm_yday=1, tm_isdst=-1)

*  ``datetime`` ordinal::

   In [24]: datetime.datetime.toordinal(datetime.datetime(1, 1, 31, 0, 0, 0, 0))
   Out[24]: 31

*  ``matplotlib datenum`` float::

   In [36]: matplotlib.dates.num2date(1)
   Out[36]: datetime.datetime(1, 1, 1, 0, 0,
                      tzinfo=<matplotlib.dates._UTC object at 0x7f66371f6550>)

   In converting strings, this module converts a 2-digit year as nearest 4-digit
   year::

   In [55]: num2date(matplotlib.dates.datestr2num("Jan 1 99 00:00:00"))
   Out[55]: datetime.datetime(1999, 1, 1, 0, 0,
                      tzinfo=<matplotlib.dates._UTC object at 0x7f66371f6550>)

UNIX (System) Time

Number of seconds since 1970/01/01 00:00:00 UT. Example:

In [10]: time.gmtime(0)
Out[10]: time.struct_time(tm_year=1970, tm_mon=1, tm_mday=1,
                         tm_hour=0, tm_min=0, tm_sec=0,
                         tm_wday=3, tm_yday=1, tm_isdst=0)

Julian Date and Modified Julian Date

Julian Date is number of days since -4713:11:24 12:00:00 UT:

In [11]: julian_date(-4713,328.5) Out[11]: 0.0 In [12]: calendar_date(-4713,328) Out[12]: (-4713, 11, 24)

Modified Julian Date is

  • Julian date - 2400000.5
  • number of days since 1858/11/17 00:00:00 UT.
  • 40587 + unixtime/(24*60*60)

Example:

In [13]: julian_date(1858,day_of_year(1858,11,17))
Out[13]: 2400000.5
In [14]: MJD(1858,11,17)
Out[14]: 0
In [15]: MJD(1970,1,1)
Out[15]: 40587

IAU position based names

These take the forms:

Jhhmm+ddmm
Bhhmm+ddmm
Gddd.d+dd.d

Classes

Subclass UTC(datetime.tzinfo) defines UTC.

Functions

ISO times

Functions to convert to and from ISO times:

format_ISO_time(year,doy,timestr)
ISOtime2datetime(ISOtime)

UNIX Timestamp

Functions for UNIX times:

datetime_to_UnixTime(t)
macro_log_time_to_UnixTime(year,timestr)
UnixTime_to_datetime(UnixTimeStamp)
UnixTime_to_MPL(UnixTimeStamp)
MPLtime_to_UnixTime(MPLtime)
timestamp_to_str_with_ms(TS)

VSR Times

To and from various VSR time formats:

incr_VSR_timestamp(timestr)  incr_VSR_timestring(timestr)
make_VSR_timestring()
VSR_to_datetime(VSR_time_tuple)
VSR_to_timetuple(VSR_tuple)
VSR_timestring_to_ISOtime(timestr)
VSR_script_time(doy,h,m,s)
VSR_script_time_to_timestamp(year,string)
VSR_tuple_to_MPL(year,doy,seconds)
VSR_tuple_to_datetime(year,doy,start_sec)
VSR_tuple_to_timestamp(year,doy,start_sec)
VSR_timestamp()

Time strings

Various functions to convert to and from time strings:

DDDMM_to_dec_deg(DDDMM)
HHMM_to_timetuple(time_string)
HHMM_to_dec_deg(HHMM)
HHMMSS_to_seconds(string)
make_date_string(date_tuple)
timetuple_to_HHMM(time)
YYYYDDD_datecode(year, midfix, doy)

Date Conversions

Functions:

calendar_date(year, doy)
julian_date (year, doy)
MJD_to_UnixTime(MJD)
day_of_year (year, month, day)

Miscellaneous

Various useful functions:

day_of_week(doy, year)
leap_year (year)
deg_to_IAU_str(position,format="h")
week_number(year,doy)
format_now()
now_string()
get_current_week()
get_date()

logtime_to_timetuple(time_string)
mpldate2doy(mpldate)
parse_date(ses_date)
time_int_to_decimal(time)
timetuple_to_datetime(timetuple)
Title: DatesTimes — DatesTimes 0.9 documentation

DatesTimes

DatesTimes Package

Supporting functions for Date and Time

Date and Time Formats

VSR time tuples

The are of the form:

(YYYY,DDD,sssss)

where the latter is seconds since midnight.

VSR filename time strings

Used in the output files, these are text strings of the form:

'YYYY DDD ssssss'

where the latter is seconds since midnight.

VSR script time stamps

used in filenames are of the form:

DDD/HH:MM:SS

ISO timestamps

These are of the form:

YYYYMMDDTHHMMSS      or
YYYY-MM-DDTHH:MM:SS.

We’ve extended this to include:

YYYY-DDDTHH:MM(:SS) and
YYYYDDDTHHMM.

Python times

take these forms:

datetime.datetime object
   datetime.datetime(2015, 12, 19, 10, 29, 29, 198776)
time.time (float)
   1450729528.987735
time.struct_time
   time.struct_time(tm_year=2015, tm_mon=12, tm_mday=21,
                    tm_hour=20, m_min=23, tm_sec=18,
                    tm_wday=0, tm_yday=355, tm_isdst=0)
datetime ordinal (int)
   735951
matplotlib datetime (float)
   735953.5172106482

UNIX (System) Time

Number of seconds since 1970/01/01 00:00:00 UT. Example:

In [10]: time.gmtime(0)
Out[10]: time.struct_time(tm_year=1970, tm_mon=1, tm_mday=1,
                         tm_hour=0, tm_min=0, tm_sec=0,
                         tm_wday=3, tm_yday=1, tm_isdst=0)

Julian Date and Modified Julian Date

Julian Date is number of days since -4713:11:24 DSN/WVSR/collector.py12:00:00 UT Example:

In [11]: julian_date(-4713,328.5)
Out[11]: 0.0
In [12]: calendar_date(-4713,328)
Out[12]: (-4713, 11, 24)
Modified Julian Date is::
  • Julian date - 2400000.5
  • number of days since 1858/11/17 00:00:00 UT.
  • 40587 + unixtime/(24*60*60)

Example:

In [13]: julian_date(1858,day_of_year(1858,11,17))
Out[13]: 2400000.5
In [14]: MJD(1858,11,17)
Out[14]: 0
In [15]: MJD(1970,1,1)
Out[15]: 40587

IAU position based names

These take the forms:

Jhhmm+ddmm, Bhhmm+ddmm and Gddd.d+dd.d
ISO times
---------
Methods to convert to and from ISO times::

format_ISO_time(year,doy,timestr) ISOtime2datetime(ISOtime):

VSR Times
---------
To and from various VSR time formats::

incr_VSR_timestamp(timestr) incr_VSR_timestring(timestr) make_VSR_timestring() VSR_to_datetime(VSR_time_tuple) VSR_to_timetuple(VSR_tuple) VSR_timestring_to_ISOtime(timestr) VSR_script_time(doy,h,m,s) VSR_script_time_to_timestamp(year,string) VSR_tuple_to_MPL(year,doy,seconds) VSR_tuple_to_datetime(year,doy,start_sec) VSR_tuple_to_timestamp(year,doy,start_sec) VSR_timestamp()

Time strings
------------MPLtime_to_UnixTime
Various functions to convert to and from time strings::

DDDMM_to_dec_deg(DDDMM) HHMM_to_timetuple(time_string) HHMM_to_dec_deg(HHMM) HHMMSS_to_seconds(string) make_date_string(date_tuple) timetuple_to_HHMM(time) YYYYDDD_datecode(year, midfix, doy)

DatesTimes.Miscellaneous()
-------------
Various useful functions::

datetime_to_UnixTime(t) deg_to_IAU_str(position,format=”h”) format_now() get_current_week() get_date() logtime_to_timetuple(time_string) macro_log_time_to_UnixTime(year,timestr) mpldate2doy(mpldate) MPLtime_to_UnixTime(MPLtime) now_string() parse_date(ses_date) seconds(timedelta) time_int_to_decimal(time) timestamp_to_str_with_ms(TS) timetuple_to_datetime(timetuple) UnixTime_to_datetime(UnixTimeStamp) UnixTime_to_MPL(UnixTimeStamp) week_number(year,doy) MJD_to_UnixTime(MJD)

Functions

DDDMM_to_dec_deg(DDDMM) Converts a strin DDDMM to decimal degrees.
HHMMSS_to_seconds(string) Converts a colon-separated time string (HH:MM:SS) to seconds since midnight
HHMM_to_dec_deg(HHMM) Converts a string HHMM to decimal hours.
HHMM_to_timetuple(time_string) This converts a time string of the form used in DSN schedules (HHMM) to a time tuple (h,m).
ISOtime2datetime(ISOtime) Converts an ISO string to a datetime object
MJD(*args) Returns modified Julian date from UNIX time or (year,doy) or (year,month,day)
MJD_to_UnixTime(MJD) Converts MJD time to UNIX time
MPLtime_to_UnixTime(MPLtime) Converts an MPL time to a UNIX time stamp
UnixTime_to_MJD(UnixTime) Convert UnixTime to fractional MJD
UnixTime_to_MPL(UnixTime) Converts a UNIX time stamp (seconds since the epoch) to matplotlib date/time.
UnixTime_to_datetime(UnixTimeStamp) Converts a UNIX time stamp to a Python datetime object
VSR_script_time(doy, h, m, s) This creates a timestamp such as VSR script files use.
VSR_script_time_to_timestamp(year, string) Converts a VSR time string like 123/12:34:45 to a UNIX time stamp.
VSR_timestamp() Alias for make_VSR_timestring, for backwards compatibility
VSR_timestring_to_ISOtime(timestr) Formats a VSR time string as YYYYMMDDTHHMMSS.
VSR_to_datetime(VSR_time_tuple) Converts a VSR time tuple to a datetime object.
VSR_to_timetuple(VSR_tuple) Converts a VSR time tuple to a Python time tuple.
VSR_tuple_to_MPL(year, doy, seconds) Converts a VSR time tuple to a matplotlib date/time float.
VSR_tuple_to_datetime(year, doy, start_sec) Converts VSR time specification toa datetime object.
VSR_tuple_to_timestamp(year, doy, start_sec) Converts a VSR time specification to a UNIX time stamp.
WVSR_script_time_to_timestamp(yrdoystr, timestr) Converts a VSR time string like 16/237 08:45:01 to a UNIX time stamp.
YYYYDDD_datecode(year, midfix, doy) Format the datecode pattern used in many log files.
calendar_date(year, doy) Calendar date from day of year
datetime_to_UnixTime(t) Converts a Python datetime object to a UNIX timestamp.
day_of_week(doy, year) Numeric value for the day of week
day_of_year(year, month, day) Day of year
deg_to_IAU_str(position[, format]) The position is a longitude-like, latitude-like tuple.
format_ISO_time(year, doy, timestr) Format an ISO-like time string: YYYY-DDDTHH:MM
format_now() Return the current time as a formatted string:
get_current_week()
get_date() This gets a date string of the form YYY-MM-DD from the command line or requests it from the user.
incr_VSR_timestamp(timestr) Alias for inc_VSR_timestring for backwards compatibility
incr_VSR_timestring(timestr) Increments a VSR timestamp.
julian_date(year, doy) Julian date
leap_year(year) Leap year
logtime_to_timetuple(time_string) This converts a time string of the form used in EAC and RAC logs (HH:MM:SS) to a time tuple (h,m,s).
macro_log_time_to_UnixTime(year, timestr) Given a time string DDD_HH:MM:SS it returns the UNIX timestamp
make_VSR_timestring() Creates a time string for the current time in the format that the VSR uses: ‘YYYY DDD SSSSS’.
make_date_string(date_tuple) Accepts a date tuple (year,month,day) and returns a formatted string of the form YYYY-MM-DD.
mpldate2doy(mpldate) get day of year from matplotlib date number
now_string() Current minute formatted as YYYY/DDD-HHMM
num2date(MPLtime) Replacement for matplotlib.dates function
parse_date(ses_date) This parses a date string of the form YYYY-MM-DD and returns the string, year, month, day and day of year.
seconds(timedelta[, unit]) Computes the length of a datetime interval to specified units
time_int_to_decimal(time) Takes a number of the form HHMMSS or +/-DDMMSS and converts it to a decimal.
timestamp_to_str_with_ms(TS) Converts a UNIX time.time float to a date time string with milliseconds.
timetuple_to_HHMM(time) Converts a time in time() format, seconds since the epoch, to an HHMM string.
timetuple_to_datetime(timetuple) Converts a timetuple (y,mo,d,h,mi,s) to a datetime object.
week_number(year, doy) Computes the week number given the year and day of year.

Classes

ST This subclass of tzinfo defines standard time in the current timezone
UTC This subclass of tzinfo defines UTC
ndarray ndarray(shape, dtype=float, buffer=None, offset=0,

Indices and tables

Reply via email to