tlc.core.builtins.schemas.schemas
¶
A number of helper classes for common simple schemas
Module Contents¶
Classes¶
Class |
Description |
---|---|
A Schema defining an (x, y, z) value |
|
A Schema defining COCO label |
|
A Schema defining CIFAR10 label |
|
A schema for a categorical label |
|
A schema for a 2D vector |
|
A schema for a 3D vector |
|
A schema for example ID values |
|
A schema for epoch values |
|
A schema for iteration values |
|
A schema describing a value that identifies a foreign table |
|
A schema for sample weight values |
API¶
- class XyzSchema(
- display_name: str = '',
- description: str = '',
- writable: bool = True,
- display_importance: float = 0,
- value_type: str = _DEFAULT_SCALAR_VALUE_TYPE,
Bases:
tlc.core.schema.Schema
A Schema defining an (x, y, z) value
- class COCOLabelSchema(
- display_name: str = 'label',
- description: str = 'COCO Label',
- writable: bool = False,
- display_importance: float = 0,
Bases:
tlc.core.schema.Schema
A Schema defining COCO label
- class CIFAR10LabelSchema(
- display_name: str = 'label',
- description: str = 'CIFAR-10 Label',
- writable: bool = False,
- display_importance: float = 0,
- value_type: str = _DEFAULT_SCALAR_VALUE_TYPE,
Bases:
tlc.core.schema.Schema
A Schema defining CIFAR10 label
- class CategoricalLabelSchema(
- class_names: list[str],
- display_name: str = 'label',
- description: str = '',
- writable: bool = False,
- display_colors: list[str] | None = None,
- display_importance: float = 0,
Bases:
tlc.core.schema.Schema
A schema for a categorical label
- class FloatVector2Schema(
- display_name: str = '2D Embedding',
- description: str = '',
- writable: bool = False,
- display_importance: float = 0,
- number_role: str = NUMBER_ROLE_XY_COMPONENT,
- mode: Literal[numpy, python] = 'python',
Bases:
tlc.core.schema.Schema
A schema for a 2D vector
- class FloatVector3Schema(
- display_name: str = '3D Embedding',
- description: str = '',
- writable: bool = False,
- display_importance: float = 0,
- number_role: str = NUMBER_ROLE_XYZ_COMPONENT,
- mode: Literal[numpy, python] = 'python',
Bases:
tlc.core.schema.Schema
A schema for a 3D vector
- class ExampleIdSchema(
- display_name: str = 'Example ID',
- description: str = '',
- writable: bool = False,
- computable: bool = False,
Bases:
tlc.core.schema.Schema
A schema for example ID values
Example ID is a unique identifier for an example. It is used to identify examples across different tables.
- class EpochSchema(
- display_name: str = 'Epoch',
- description: str = 'Epoch of training',
- display_importance: float | None = None,
Bases:
tlc.core.schema.Schema
A schema for epoch values
- class IterationSchema(
- display_name: str = 'Iteration',
- description: str = 'The current iteration of the training process.',
- display_importance: float | None = None,
Bases:
tlc.core.schema.Schema
A schema for iteration values
- class ForeignTableIdSchema( )¶
Bases:
tlc.core.schema.Schema
A schema describing a value that identifies a foreign table
- class SampleWeightSchema(
- display_name: str = 'Weight',
- description: str = 'The weights of the samples in this table.',
- sample_type: str = 'hidden',
- default_value: float = 1.0,
Bases:
tlc.core.schema.Schema
A schema for sample weight values
Initialize the SampleWeightSchema
- Parameters:
display_name – The display name of the schema
description – The description of the schema
sample_type – The sample type of the schema
default_value – The default value of the schema