Skip to content
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

[Task] Create a protocol for common methods across model frameworks #676

Closed
oliverholworthy opened this issue Aug 25, 2022 · 0 comments · Fixed by #680
Closed

[Task] Create a protocol for common methods across model frameworks #676

oliverholworthy opened this issue Aug 25, 2022 · 0 comments · Fixed by #680
Assignees
Labels
enhancement New feature or request
Milestone

Comments

@oliverholworthy
Copy link
Member

oliverholworthy commented Aug 25, 2022

Part of #669
Relates to NVIDIA-Merlin/Merlin#545

Background

Based on the discussions around having a common API across the backend framework implementations. We would like to make this concrete with a protocol that each model can be checked against to help make it clear which methods are part of a common API and which are specific to the various model implementations.

Description

Write down the common API methods supported by each model in a protocol that can be runtime checked. This can be extended in future. For the purposes of this task. The following may be enough to consider this task complete:

  • training methods:
    • fit Fit (train) the model on a dataset provided
    • evaluate Evaluate the model on a dataset provided (returns metrics)
    • predict Run inference on the model returning the output predictions of the model
  • io methods:
    • save Write out artifact(s) that can be reloaded by the load method
    • load classmethod to re-load a model from a previously saved model instance.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
2 participants