-
Notifications
You must be signed in to change notification settings - Fork 97
feat(operator): sklearn testing operator #3534
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR adds a new “Sklearn Testing” operator that computes common evaluation metrics on a collected dataset using a provided scikit-learn model.
- Introduces
SklearnTestingOpDesc
with Python code generation for accuracy, F1, precision, and recall. - Registers the new operator in the logical operator registry.
- Extends the output schema to include the computed metric fields.
Reviewed Changes
Copilot reviewed 2 out of 3 changed files in this pull request and generated 2 comments.
File | Description |
---|---|
core/workflow-operator/src/main/scala/edu/uci/ics/amber/operator/sklearn/testing/SklearnTestingOpDesc.scala | New operator descriptor for Sklearn testing with codegen and schema updates |
core/workflow-operator/src/main/scala/edu/uci/ics/amber/operator/LogicalOp.scala | Added registration of the Sklearn Testing operator |
Comments suppressed due to low confidence (1)
core/workflow-operator/src/main/scala/edu/uci/ics/amber/operator/sklearn/testing/SklearnTestingOpDesc.scala:33
- This new operator does not appear to have any associated unit or integration tests; adding test coverage for typical and edge-case scenarios would help ensure correctness.
class SklearnTestingOpDesc extends PythonOperatorDescriptor {
...perator/src/main/scala/edu/uci/ics/amber/operator/sklearn/testing/SklearnTestingOpDesc.scala
Outdated
Show resolved
Hide resolved
...perator/src/main/scala/edu/uci/ics/amber/operator/sklearn/testing/SklearnTestingOpDesc.scala
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This operator's design can be further discussed.
...perator/src/main/scala/edu/uci/ics/amber/operator/sklearn/testing/SklearnTestingOpDesc.scala
Show resolved
Hide resolved
...perator/src/main/scala/edu/uci/ics/amber/operator/sklearn/testing/SklearnTestingOpDesc.scala
Show resolved
Hide resolved
...perator/src/main/scala/edu/uci/ics/amber/operator/sklearn/testing/SklearnTestingOpDesc.scala
Show resolved
Hide resolved
...perator/src/main/scala/edu/uci/ics/amber/operator/sklearn/testing/SklearnTestingOpDesc.scala
Show resolved
Hide resolved
...perator/src/main/scala/edu/uci/ics/amber/operator/sklearn/testing/SklearnTestingOpDesc.scala
Show resolved
Hide resolved
Had offline discussions. |
Introduce the Sklearn Testing Operator, which accepts any number of machine learning models (from 1 to n) and computes
accuracy
,F1
score,precision
, andrecall
for each model, appending these metrics to the output columns.There is a port dependency between the model and the data: the data port must be finished first. The data table is then used as an internal state for testing. This operator can accept any number of models; each model will be tested against the same data table.
Input single model:

Input multiple models:
