(setting_info, value)
return output_range[input_range.index(matched_value)]
Called by the "range" functions to process 'value' with the specified
    range settings in 'setting_info'.

    :param dict setting_info: The information dict of the setting from the
                              device profile.
    :param value: The input value.
    :rtype: int
Called by the "range" functions to process 'value' with the specified
    range settings in 'setting_info'.
Called by the range functions to process value with the specified range settings in setting_info .
def process_range(setting_info, value):
    """Called by the "range" functions to process 'value' with the specified
    range settings in 'setting_info'.

    :param dict setting_info: The information dict of the setting from the
                              device profile.
    :param value: The input value.
    :rtype: int
    """
    input_range = list(
        range(
            setting_info["input_range"][0],
            setting_info["input_range"][1] + 1,
            setting_info["input_range"][2],
        )
    )
    output_range = list(
        custom_range(
            setting_info["output_range"][0],
            setting_info["output_range"][1] + 1,
            setting_info["output_range"][2],
        )
    )

    if len(input_range) != len(output_range):
        raise ValueError("Input range and output range must have the same length")

    matched_value = matches_value_in_range(
        setting_info["input_range"][0],
        setting_info["input_range"][1],
        setting_info["input_range"][2],
        int(value),
    )
    return output_range[input_range.index(matched_value)]
def process_range ( setting_info , value ) : input_range = list ( range ( setting_info [ "input_range" ] [ 0 ] , setting_info [ "input_range" ] [ 1 ] + 1 , setting_info [ "input_range" ] [ 2 ] , ) ) output_range = list ( custom_range ( setting_info [ "output_range" ] [ 0 ] , setting_info [ "output_range" ] [ 1 ] + 1 , setting_info [ "output_range" ] [ 2 ] , ) ) if len ( input_range ) != len ( output_range ) : raise ValueError ( "Input range and output range must have the same length" ) matched_value = matches_value_in_range ( setting_info [ "input_range" ] [ 0 ] , setting_info [ "input_range" ] [ 1 ] , setting_info [ "input_range" ] [ 2 ] , int ( value ) , ) return output_range [ input_range . index ( matched_value ) ]