Closed esherman-credo closed 1 year ago
Coverage Report
Linking the per-evaluator validation requirements. I'm shooting to have this implemented such that one can trivially read an evaluator's assumptions/requirements from the validate_artifacts
function. E.g. in below screenshot from the updated Performance evaluator, we can see that the performance evaluator has the requirements:
Moreover, we can see that sensitive features doesn't need to be checked for nullness, which is a hint that that sub-artifact isn't used in this evaluator (not otherwise obvious without looking carefully through the code or making an assumption based on the evalutor's docstring).
Describe your changes
This is a feature branch implementing support for tensor-based data and neural network models. For Credo-internal developers, the proposed changes are detailed here.
Summary of Changes (in progress, more to come):
process_model
function__post_init__()
functionality for keras predictionspredict_proba
) vs. softmax (probability outputs;predict_proba
by default -> can inferpredict
) -DummyClassifierX
+y
artifacts to data wrapper when they're already wrappedX
andy
are separate in the user's non-Lens workflow, passing these to Lens will be done in the same way as forTabularData
X
andy
are wrapped in one object (such as atf.data
orkeras.utils.Sequence
object) then passing them to the Lens wrapper requires separating themmodel_like
toDummyClassifier
X
andy
)Data
process
functions to non-abstract (committed)Data
classTensorflowV2Classifier
rather than theirKerasClassifier
Lens Validation Validation of Model + Data --> At Lens init stage, we now verify that
predict
,predict_proba
, andcompare
(whichever are relevant to the provided model) works for the provided data. Throws an error and prevents instantiating/running evaluators without first checking Model + Data compatibility.Evaluator Validation Established a starting point for streamlining/unifying artifact checking. Converted
check_artifact_for_nulls
tocheck_data...
(name reflects what it's doing) and added options to only check some parts of the artifact (i.e., a subset ofX
,y
, andsensitive_features
) for nulls rather than checking all parts. Functionality doesn't fundamentally change but makes requirements more explicit from function arguments:check_X
,check_y
, andcheck_sens
(all boolean).Issue ticket number and link
https://credo-ai.atlassian.net/browse/DSP-344
Known outstanding issues that are not fully accounted for
Checklist before requesting a review
Extra-mile Checklist