Skip to content

Need a 'workout test' for estimators #707

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

Closed
Zruty0 opened this issue Aug 22, 2018 · 1 comment
Closed

Need a 'workout test' for estimators #707

Zruty0 opened this issue Aug 22, 2018 · 1 comment
Labels
API Issues pertaining the friendly API

Comments

@Zruty0
Copy link
Contributor

Zruty0 commented Aug 22, 2018

Pretty much any IEstimator needs to adhere to certain properties, which we should enforce in a test:

Estimator est:

  • est.Fit() throws on a data if est.GetOutputSchema() throws on its schema.
    • The opposite may not be true.
  • est.Fit() on the same data produces identical transformers.
  • Schema validation errors should look properly (same message).

Fitted transformer xf = est.Fit(data):

  • xf should be able to transform the data it was fitted on.
  • xf.GetOutputSchema() should match est.GetOutputSchema().
  • xf.Transform() throws on a data if xf.GetOutputSchema() throws on its schema.
    • The opposite may not be true.
  • Save/load should be transparent for xf.
  • Subject the outputs of xf.Transform() to the same workouts as we do for transforms: CheckSameSchema, CheckSameValues.
@Zruty0 Zruty0 added the API Issues pertaining the friendly API label Aug 22, 2018
@Zruty0
Copy link
Contributor Author

Zruty0 commented Aug 28, 2018

Actually, we also want to port TestDataPipe tests to ML.NET.

Zruty0 added a commit that referenced this issue Aug 30, 2018
Converted the following transforms to Estimators:

- ImageLoader
- ImageResizer
- ImagePixelExtractor
- ImageGrayscale

Fixes #707
@ghost ghost locked as resolved and limited conversation to collaborators Mar 29, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
API Issues pertaining the friendly API
Projects
None yet
Development

No branches or pull requests

1 participant