import calendar


def dt2unix(dto):
    """
    dt2unix : Convert a datetime object to a UNIX time stamp

    Usage: unixTS = dt2unix(dto)

    Input:dto A datetime object

    Output: a unix time stamp (int)

    """
    return calendar.timegm(dto.utctimetuple())