def remap(value, old_min, old_max, new_min, new_max):
    """
    Remaps the value to a new min and max value
    Args:
        value: value to remap
        old_min: old min of range
        old_max: old max of range
        new_min: new min of range
        new_max: new max of range

    Returns:
        The remapped value in the new range
    """
    return new_min + (((value - old_min) / (old_max - old_min)) * (new_max - new_min))