def make_datetime(dt, date_parser=parse_date):
if (isinstance(dt, (datetime.datetime, datetime.date, datetime.time, pd.Timestamp, np.datetime64)) or<EOL>dt in (float('<STR_LIT>'), float('<STR_LIT>'), float('<STR_LIT>'), None, '<STR_LIT>')):<EOL><INDENT>return dt<EOL><DEDENT>if isinstance(dt, (float, int)):<EOL><INDENT>return datetime_from_ordinal_float(dt)<EOL><DEDENT>if isinstance(dt, datetime.date):<EOL><INDENT>return datetime.datetime(dt.year, dt.month, dt.day)<EOL><DEDENT>if isinstance(dt, datetime.time):<EOL><INDENT>return datetime.datetime(<NUM_LIT:1>, <NUM_LIT:1>, <NUM_LIT:1>, dt.hour, dt.minute, dt.second, dt.microsecond)<EOL><DEDENT>if not dt:<EOL><INDENT>return datetime.datetime(<NUM_LIT>, <NUM_LIT:1>, <NUM_LIT:1>)<EOL><DEDENT>if isinstance(dt, basestring):<EOL><INDENT>try:<EOL><INDENT>return date_parser(dt)<EOL><DEDENT>except ValueError:<EOL><INDENT>print('<STR_LIT>'.format(dt))<EOL>raise<EOL><DEDENT><DEDENT>try:<EOL><INDENT>return datetime.datetime(*dt.timetuple()[:<NUM_LIT:7>])<EOL><DEDENT>except AttributeError:<EOL><INDENT>try:<EOL><INDENT>dt = list(dt)<EOL>if <NUM_LIT:0> < len(dt) < <NUM_LIT:7>:<EOL><INDENT>try:<EOL><INDENT>return datetime.datetime(*dt[:<NUM_LIT:7>])<EOL><DEDENT>except (TypeError, IndexError, ValueError):<EOL><INDENT>pass<EOL><DEDENT><DEDENT><DEDENT>except (TypeError, IndexError, ValueError, AttributeError):<EOL><INDENT>return dt<EOL><DEDENT><DEDENT>return [make_datetime(val, date_parser=date_parser) for val in dt]<EOL>
Coerce a datetime or string into datetime.datetime object

    Arguments:
      dt (str or datetime.datetime or atetime.time or numpy.Timestamp): time or date
        to be coerced into a `datetime.date` object

    Returns:
      datetime.time: Time of day portion of a `datetime` string or object

    >>> make_date('')
    datetime.date(1970, 1, 1)
    >>> make_date(None)
    datetime.date(1970, 1, 1)
    >>> make_date("11:59 PM") == datetime.date.today()
    True
    >>> make_date(datetime.datetime(1999, 12, 31, 23, 59, 59))
    datetime.date(1999, 12, 31)
    >>> make_datetime(['1970-10-31', '1970-12-25'])  # doctest: +NORMALIZE_WHITESPACE
    [datetime.datetime(1970, 10, 31, 0, 0), datetime.datetime(1970, 12, 25, 0, 0)]