TrainingTracer / Logger / DataFilter
The entry points that do not name a task — one per purpose. A multi-head model
(a ModelSpec declaring heads=) can carry heads of different tasks, so these are the
entry points that serve it; they accept single-head models just as well and resolve to
the declared (or auto-detected) task's own class.
For how to declare and use a multi-head model, see heads= (Multi-Head Models).
from ml_debugger import TrainingTracer, Logger, DataFilter
ml_debugger.entry.TrainingTracer(*args, **kwargs)
Record a training run of a model, whatever it predicts.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
|
Any
|
|
()
|
|
Any
|
|
{}
|
Returns:
| Type | Description |
|---|---|
Any
|
The tracer for this model: call it in place of the model to record what it |
Any
|
predicted, then |
Raises:
| Type | Description |
|---|---|
ValueError
|
If the declaration cannot be served -- a head name that composes a model name the service will not accept, or a model whose task cannot be determined without a Spec. |
ml_debugger.entry.Logger(*args, **kwargs)
Monitor a model in production, whatever it predicts.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
|
Any
|
|
()
|
|
Any
|
|
{}
|
Returns:
| Type | Description |
|---|---|
Any
|
The logger for this model: call it in place of the model to record every |
Any
|
inference it makes. |
Raises:
| Type | Description |
|---|---|
ValueError
|
If the declaration cannot be served (see :func: |
ml_debugger.entry.DataFilter(*args, **kwargs)
Select the data worth collecting from a model, whatever it predicts.
On a model declaring several heads, filter_config is given per head -- a decision
is made on what THAT head predicted -- and the decisions come back per head.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
|
Any
|
|
()
|
|
Any
|
|
{}
|
Returns:
| Type | Description |
|---|---|
Any
|
The data filter for this model: call it in place of the model to get back what it |
Any
|
predicted together with the filtering decisions. |
Raises:
| Type | Description |
|---|---|
ValueError
|
If the declaration cannot be served (see :func: |