AUTO_VI$null_vss {autovi} | R Documentation |
Simulate null plots and predict the visual signal strength
Description
This function simulates null plots from the null hypothesis distribution, and predicts the visual signal strength.
Usage
AUTO_VI$null_vss( draws = 100L, fitted_model = self$fitted_model, keras_model = self$keras_model, null_method = self$null_method, node_index = self$node_index, keep_null_data = FALSE, keep_null_plot = FALSE, extract_feature_from_layer = NULL )
Arguments
draws |
Integer. Number of simulation draws. |
fitted_model |
Model. A model object, e.g. |
keras_model |
Keras model. A trained computer vision model. |
null_method |
Function. A method to simulate residuals from the null
hypothesis distribution. For |
node_index |
Integer. An index indicating which node of the output layer contains the visual signal strength. This is particularly useful when the keras model has more than one output nodes. |
keep_null_data |
Boolean. Whether to keep the simulated null data. |
keep_null_plot |
Boolean. Whether to keep the simulated null plots. |
extract_feature_from_layer |
Character/Integer. A layer name or an integer layer index for extracting features from a layer. |
Value
A tibble.
Examples
keras_model <- try(get_keras_model("vss_phn_32"))
if (!inherits(keras_model, "try-error")) {
myvi <- auto_vi(lm(dist ~ speed, data = cars), keras_model)
myvi$null_vss()
}