def sameday(dt1, dt2):
    return (dt1.day == dt2.day and dt1.month == dt2.month
            and dt1.year == dt2.year)
Do two datetimes reference the same day? (ignore times)
dataset/ETHPy150Open marineam/nagcat/railroad/railroad/viewhosts/templatetags/services.py/sameday