Documentation ¶
Overview ¶
Package canonical registers the "canonical" models.
Model implementations are made accessible through a registration mechanism for three main usecases: - A user wants all the available official models (called "canonical" models") to be available.
In this case, the user import this "canonical" package. Importing this package registers the canonical models.
- A user is developing a custom model. This implementation is not canonical. The user import the
implementation package manually once.
- A user is developing a size critical binary that serves a single type of model. The user import
the implementation package of the corresponding model.
Remark, this registration system is similar as the one used in the C++ code. However, unlike the c++ code that only require for models to be added as "deps", the go code requires for models to be added as "deps" AND imported once.
Like for the c++ code. Models (in the "/model" directory) and engines (i.e. optimized code to run models on specific hardward (in the "/serving" directory) are independent.