arthurai.core.model_utils#

Functions

check_attr_is_bias(model, attr_name)

Returns True if and only if the model has an attribute with the given name attr_name being monitored for bias by Arthur

check_has_bias_attrs(model)

Returns True if and only if the model has any attributes being monitored for bias by Arthur

get_positive_predicted_class(model)

Checks if model is a binary classifier.

tensors_to_arthur_inference(log_tensor, ...)

Convert an array of log probabilities with shape (sequence length, vocab size) to an Arthur Token Likelihoods formatted object.