MLModelConfig

a model config defines execution properties within a pipeline.
usually to define how a pipeline should train and predict with your model.

Attributes

NameTypeDescription
by_twinbooldefine if pipeline need to train and use different model by twin item.
by_propertybooldefine if pipeline need to train and use different model based on 'property_name'.
featureslistdatapoint list to refine columns if necessary.
functionstrname of the function used instead of 'predict' on model inference.
model_keystrkey of the model to store (or use story property if dynamic).
model_typestrreserved for 'mlflow' defines model flavor such as 'sklearn' or 'pyfunc'.
model_aliasstrreserved for 'mlflow' set the alias to target and use inside a pipeline.
properties_mappingdictdict to map properties expected by the script with the properties from the context.
property_namestrdefine which property is looked for when using 'by_property'.
sourcestrdefine name of model storage to use 'wizata'.
train_scriptstrname of function referencing the script to train the model.
train_test_split_pctfloatpercentage repartition to split the data for training and scoring.
train_test_split_typestrtype of splitting desired to split the train dataframe.
output_appendbooltrue - default - append output to input dataframe. false to retrieve only 'predict' column(s).
output_columns_nameslistname list to rename columns inside output dataframe.
output_prefixstrset a prefix to put before output column names (default or custom).

Methods

api_id()

return current object id on Web API format.

endpoint()

return endpoint name used to contact backend.

from_json()

load the object from a dict originating of a JSON format.

NameTypeDefaultDescription
objobject to load information from.

has_target_feat()

determine if configuration possess a target feature

set_id()

specify the id_value neutrally

NameTypeDefaultDescription
id_value

return:

to_json()

transform current object into a dict that could be JSONIFY.

NameTypeDefaultDescription
targetstrNone

return: dumpable dict.