def make_setting_from_data(data):
    """ Constructs a new setting from a given dataset. This method will automatically
    instantiate a new class matching the type of the given dataset. It will fill
    all values provided by the dataset and then return the created instance """
    factory = {
        "int": IntType,
        "float": FloatType,
        "bool": BoolType,
        "enum": EnumType,
        "path": PathType,
        "power_of_two": PowerOfTwoType,
        "sample_sequence": SampleSequenceType
    }
    return make_setting_from_factory(data, factory)
 Constructs a new setting from a given dataset. This method will automatically
    instantiate a new class matching the type of the given dataset. It will fill
    all values provided by the dataset and then return the created instance 
metadrive/render_pipeline/rpcore/pluginbase/setting_types.py