def HOUR(expression):
    """
    Returns the hour portion of a date as a number between 0 and 23.
    See https://docs.mongodb.com/manual/reference/operator/aggregation/hour/
    for more details
    :param expression: expression or variable of a Date, a Timestamp, or an ObjectID
    :return: Aggregation operator
    """
    return {'$hour': expression}