class ModelErrorAnalysis[source]#

Find the properties that best split the data into segments of high and low model error.

The check trains a regression model to predict the error of the user’s model. Then, the properties scoring the highest feature importance for the error regression model are selected and the distribution of the error vs the property values is plotted. The check results are shown only if the error regression model manages to predict the error well enough.

image_propertiesList[Dict[str, Any]], default: None

List of properties. Replaces the default deepchecks properties. Each property is a dictionary with keys 'name' (str), method (Callable) and 'output_type' (str), representing attributes of said method. ‘output_type’ must be one of:

  • 'numeric' - for continuous ordinal outputs.

  • 'categorical' - for discrete, non-ordinal outputs. These can still be numbers, but these numbers do not have inherent value.

For more on image / label properties, see the guide about Data Properties.

max_properties_to_showint , default: 3

maximal number of properties to show error distribution for.

min_property_contributionfloat , default: 0.15

minimum feature importance of a property to the error regression model in order to show the property.

min_error_model_scorefloat , default: 0.5

minimum r^2 score of the error regression model for displaying the check.

min_segment_sizefloat , default: 0.05

minimal fraction of data that can comprise a weak segment.

n_display_samplesint , default: 5_000

number of samples to display in scatter plot.

random_stateint, default: 42

random seed for all check internals.

__init__(image_properties: Optional[List[Dict[str, Any]]] = None, max_properties_to_show: int = 20, min_property_contribution: float = 0.15, min_error_model_score: float = 0.5, min_segment_size: float = 0.05, n_display_samples: int = 5000, random_state: int = 42, **kwargs)[source]#
__new__(*args, **kwargs)#


ModelErrorAnalysis.add_condition(name, ...)

Add new condition function to the check.


Remove all conditions from this check instance.


Find segments that contribute to model error.


Run conditions on given result.


Return check configuration (conditions' configuration not yet supported).

ModelErrorAnalysis.from_config(conf[, ...])

Return check object from a CheckConfig object.

ModelErrorAnalysis.from_json(conf[, ...])

Deserialize check instance from JSON string.


Initialize property and score lists.


Return check metadata.

Name of class in split camel case.


Return parameters to show when printing the check.


Remove given condition by index., ...[, ...])

Run check.


Serialize check instance to JSON string.

ModelErrorAnalysis.update(context, batch, ...)

Accumulate property data of images and scores.