def xldate_as_datetime(xldate, datemode):
    if datemode not in (0, 1):
        raise XLDateBadDatemode(datemode)
if xldate == 0.0:
    return datetime.time(0, 0, 0)
if xldate < 0.0:
    raise XLDateNegative(xldate)
xldays = int(xldate)
frac = xldate - xldays
seconds = int(round(frac * 86400.0))
assert 0 <= seconds <= 86400
if seconds == 86400:
    seconds = 0
xldays += 1
if xldays >= _XLDAYS_TOO_LARGE[datemode]:
    raise XLDateTooLarge(xldate)
if xldays == 0:
    minutes, second = divmod(seconds, 60)
hour, minute = divmod(minutes, 60)
return datetime.time(hour, minute, second)
if xldays < 61 and datemode == 0:
    raise XLDateAmbiguous(xldate)
return datetime.datetime.fromordinal(xldays + 693594 + 1462 * datemode
    ) + datetime.timedelta(seconds=seconds)
Как прочитать дату в формате Excel в Python?