RAMjET

ramjet.data_interface.metadatabase

Code for the the metadatabase.

Module Contents

Classes

MetadatabaseModel A general model for the metadatabase tables.

Functions

convert_class_to_table_name(model_class: Type[Model]) Creates the table name based on the model class.
metadatabase_uuid(name: str) → UUID Generates a reproducible UUID for the metadatabase based on a name string.
dataset_split_from_uuid(uuid: UUID) → int Generates a repeatable dataset split from a UUID.
metadatabase
metadatabase_uuid_namespace
convert_class_to_table_name(model_class: Type[Model])[source]

Creates the table name based on the model class.

Parameters:model_class – The class to create the table name for.
Returns:The name of the table.
class MetadatabaseModel(*args, **kwargs)[source]

Bases: peewee.Model

A general model for the metadatabase tables.

class Meta

The meta information for the metadatabase models.

database
table_function
primary_key = False
metadatabase_uuid(name: str) → UUID[source]

Generates a reproducible UUID for the metadatabase based on a name string.

Parameters:name – The string used to produce the UUID.
Returns:The UUID.
dataset_split_from_uuid(uuid: UUID) → int[source]

Generates a repeatable dataset split from a UUID.

Parameters:uuid – The UUID to seed with.
Returns:The dataset split.