Module markov.data_models.experiment_recording

Classes

class AddExperimentHyperParametersRequest (experiment_id: str, hyper_parameters: Dict = <factory>)

AddExperimentHyperParametersRequest(experiment_id: str, hyper_parameters: Dict = )

Static methods

def from_dict(kvs: dict | list | str | int | float | bool | None, *, infer_missing=False) ‑> ~A
def from_json(s: str | bytes | bytearray,
*,
parse_float=None,
parse_int=None,
parse_constant=None,
infer_missing=False,
**kw) ‑> ~A
def schema(*,
infer_missing: bool = False,
only=None,
exclude=(),
many: bool = False,
context=None,
load_only=(),
dump_only=(),
partial: bool = False,
unknown=None) ‑> dataclasses_json.mm.SchemaF[~A]

Instance variables

var experiment_id : str
var hyper_parameters : Dict

Methods

def to_dict(self, encode_json=False) ‑> Dict[str, dict | list | str | int | float | bool | None]
def to_json(self,
*,
skipkeys: bool = False,
ensure_ascii: bool = True,
check_circular: bool = True,
allow_nan: bool = True,
indent: int | str | None = None,
separators: Tuple[str, str] | None = None,
default: Callable | None = None,
sort_keys: bool = False,
**kw) ‑> str
class AddExperimentHyperParametersResponse (return_code: str, message: str | None = '')

AddExperimentHyperParametersResponse(return_code: str, message: Optional[str] = '')

Ancestors

Static methods

def from_dict(kvs: dict | list | str | int | float | bool | None, *, infer_missing=False) ‑> ~A
def from_json(s: str | bytes | bytearray,
*,
parse_float=None,
parse_int=None,
parse_constant=None,
infer_missing=False,
**kw) ‑> ~A
def schema(*,
infer_missing: bool = False,
only=None,
exclude=(),
many: bool = False,
context=None,
load_only=(),
dump_only=(),
partial: bool = False,
unknown=None) ‑> dataclasses_json.mm.SchemaF[~A]

Instance variables

var message : str | None
var return_code : str

Methods

def to_dict(self, encode_json=False) ‑> Dict[str, dict | list | str | int | float | bool | None]
def to_json(self,
*,
skipkeys: bool = False,
ensure_ascii: bool = True,
check_circular: bool = True,
allow_nan: bool = True,
indent: int | str | None = None,
separators: Tuple[str, str] | None = None,
default: Callable | None = None,
sort_keys: bool = False,
**kw) ‑> str
class BinaryOperation (value, names=None, *, module=None, qualname=None, type=None, start=1)

An enumeration.

Ancestors

  • builtins.str
  • enum.Enum

Class variables

var EQUALS : Final
var GREATER_EQUAL : Final
var GREATER_THAN : Final
var LESS_EQUAL : Final
var LESS_THAN : Final
var NOT_EQUAL : Final
class Experiment (name: str,
model_id: str,
project_id: str,
notes: str = '',
dataset_id: str = '',
hyper_parameters: Dict = None,
config: Dict = <factory>,
package_requirements: Dict[str, str] = <factory>,
python_version: str = '',
summary: ExperimentSummaryRecord | None = None)

Model class for storing Experiment in Markov

Attributes

name : str
The name of the experiments
model_id : str
The model that is used to run this experiment
notes : str
Any notes associated to the experiment (Optional)
dataset_id : str
The id of the dataset which has been used to run this experiments (Optional)
project_id(str): Project this experiment belongs to
hyper_parameters : dict
The dictionary of hyper_parameters of the model used in the experiment
config : dict
Any additional metadata needed to represent the experiment
package_requirements : dict
The packages installed in the current environment used to run the experiment.

Static methods

def from_dict(kvs: dict | list | str | int | float | bool | None, *, infer_missing=False) ‑> ~A
def from_json(s: str | bytes | bytearray,
*,
parse_float=None,
parse_int=None,
parse_constant=None,
infer_missing=False,
**kw) ‑> ~A
def schema(*,
infer_missing: bool = False,
only=None,
exclude=(),
many: bool = False,
context=None,
load_only=(),
dump_only=(),
partial: bool = False,
unknown=None) ‑> dataclasses_json.mm.SchemaF[~A]

Instance variables

var config : Dict
var dataset_id : str
var hyper_parameters : Dict
var model_id : str
var name : str
var notes : str
var package_requirements : Dict[str, str]
var project_id : str
var python_version : str
var summaryExperimentSummaryRecord | None

Methods

def get_dict(self) ‑> Dict
def get_json(self) ‑> str
def to_dict(self, encode_json=False) ‑> Dict[str, dict | list | str | int | float | bool | None]
def to_json(self,
*,
skipkeys: bool = False,
ensure_ascii: bool = True,
check_circular: bool = True,
allow_nan: bool = True,
indent: int | str | None = None,
separators: Tuple[str, str] | None = None,
default: Callable | None = None,
sort_keys: bool = False,
**kw) ‑> str
class ExperimentAlert (condition: ExperimentAlertCondition,
text: str)

Class for sending alerts when a condition is met during experiment tracking

condition: The condition which when met, a notification is sent to the current user text: The notification text which needs to be sent

Instance variables

var conditionExperimentAlertCondition
var text : str

Methods

def send_alert_on_condition(self, key: str, value: Any)
class ExperimentAlertCondition (metric_name: str,
operation: BinaryOperation,
metric_value: Any)

ExperimentAlertCondition(metric_name: str, operation: markov.data_models.experiment_recording.BinaryOperation, metric_value: Any)

Instance variables

var metric_name : str
var metric_value : Any
var operationBinaryOperation

Methods

def is_matched(self, key: str, value: Any)
class ExperimentBatchResponse (return_code: str, message: str | None = '')

ExperimentBatchResponse(return_code: str, message: Optional[str] = '')

Ancestors

Static methods

def from_dict(kvs: dict | list | str | int | float | bool | None, *, infer_missing=False) ‑> ~A
def from_json(s: str | bytes | bytearray,
*,
parse_float=None,
parse_int=None,
parse_constant=None,
infer_missing=False,
**kw) ‑> ~A
def schema(*,
infer_missing: bool = False,
only=None,
exclude=(),
many: bool = False,
context=None,
load_only=(),
dump_only=(),
partial: bool = False,
unknown=None) ‑> dataclasses_json.mm.SchemaF[~A]

Instance variables

var message : str | None
var return_code : str

Methods

def to_dict(self, encode_json=False) ‑> Dict[str, dict | list | str | int | float | bool | None]
def to_json(self,
*,
skipkeys: bool = False,
ensure_ascii: bool = True,
check_circular: bool = True,
allow_nan: bool = True,
indent: int | str | None = None,
separators: Tuple[str, str] | None = None,
default: Callable | None = None,
sort_keys: bool = False,
**kw) ‑> str
class ExperimentMetadataResponse (recording_id: str,
return_code: str,
experiment_url: str = '',
message: str | None = '',
create_date: str = '')

ExperimentMetadataResponse(recording_id: str, return_code: str, experiment_url: str = '', message: Optional[str] = '', create_date: str = '')

Static methods

def from_dict(kvs: dict | list | str | int | float | bool | None, *, infer_missing=False) ‑> ~A
def from_json(s: str | bytes | bytearray,
*,
parse_float=None,
parse_int=None,
parse_constant=None,
infer_missing=False,
**kw) ‑> ~A
def schema(*,
infer_missing: bool = False,
only=None,
exclude=(),
many: bool = False,
context=None,
load_only=(),
dump_only=(),
partial: bool = False,
unknown=None) ‑> dataclasses_json.mm.SchemaF[~A]

Instance variables

var create_date : str
var experiment_url : str
var message : str | None
var recording_id : str
var return_code : str

Methods

def get_dict(self) ‑> Dict
def get_json(self) ‑> str
def ok(self)
def to_dict(self, encode_json=False) ‑> Dict[str, dict | list | str | int | float | bool | None]
def to_json(self,
*,
skipkeys: bool = False,
ensure_ascii: bool = True,
check_circular: bool = True,
allow_nan: bool = True,
indent: int | str | None = None,
separators: Tuple[str, str] | None = None,
default: Callable | None = None,
sort_keys: bool = False,
**kw) ‑> str
class ExperimentRecord (key: Any,
value: Any,
recording_id: str,
is_aggregable: bool | None = False,
label: str | None = '',
workspace_id: str | None = '')

Model class for storing Hyper parameter records - key value pair associated to a recording_id

Attributes

recording_id : str
The id associated with the Experiment Recording
is_agggregable : bool
To mark for the backend whether this value needs to be aggregated or not
label : str
Defines the type of the record - Values - metric/system (see: ExperimentRecordLabels)

Ancestors

Static methods

def from_dict(kvs: dict | list | str | int | float | bool | None, *, infer_missing=False) ‑> ~A
def from_json(s: str | bytes | bytearray,
*,
parse_float=None,
parse_int=None,
parse_constant=None,
infer_missing=False,
**kw) ‑> ~A
def from_multi_message_dict(kv_pairs: Dict, recording_id: str) ‑> List[ExperimentRecord]

Converts a dictionary to a list of ExperimentRecords

Args

kv_pairs
the dictionary with key value pair such that key is string
recording_id
the recording for which we need to create this hyper-parameter record

Returns

List of ExperimentRecords

def list_to_json(list_of_records: List[ForwardRef('ExperimentRecord')]) ‑> str
def schema(*,
infer_missing: bool = False,
only=None,
exclude=(),
many: bool = False,
context=None,
load_only=(),
dump_only=(),
partial: bool = False,
unknown=None) ‑> dataclasses_json.mm.SchemaF[~A]

Instance variables

var is_aggregable : bool | None
var label : str | None
var recording_id : str
var workspace_id : str | None

Methods

def set_label(self, label: str)
def to_dict(self, encode_json=False) ‑> Dict[str, dict | list | str | int | float | bool | None]
def to_json(self,
*,
skipkeys: bool = False,
ensure_ascii: bool = True,
check_circular: bool = True,
allow_nan: bool = True,
indent: int | str | None = None,
separators: Tuple[str, str] | None = None,
default: Callable | None = None,
sort_keys: bool = False,
**kw) ‑> str
class ExperimentRecordRegistrationResponse

ExperimentRecordRegistrationResponse()

class ExperimentRecordingCreateRequest (name: str,
model_id: str,
description: str = '',
dataset_id: str = '',
config: Dict = <factory>,
hyper_parameters: Dict = <factory>)

ExperimentRecordingCreateRequest(name: str, model_id: str, description: str = '', dataset_id: str = '', config: Dict = , hyper_parameters: Dict = )

Static methods

def from_dict(kvs: dict | list | str | int | float | bool | None, *, infer_missing=False) ‑> ~A
def from_json(s: str | bytes | bytearray,
*,
parse_float=None,
parse_int=None,
parse_constant=None,
infer_missing=False,
**kw) ‑> ~A
def schema(*,
infer_missing: bool = False,
only=None,
exclude=(),
many: bool = False,
context=None,
load_only=(),
dump_only=(),
partial: bool = False,
unknown=None) ‑> dataclasses_json.mm.SchemaF[~A]

Instance variables

var config : Dict
var dataset_id : str
var description : str
var hyper_parameters : Dict
var model_id : str
var name : str

Methods

def get_dict(self) ‑> Dict
def get_json(self) ‑> str
def to_dict(self, encode_json=False) ‑> Dict[str, dict | list | str | int | float | bool | None]
def to_json(self,
*,
skipkeys: bool = False,
ensure_ascii: bool = True,
check_circular: bool = True,
allow_nan: bool = True,
indent: int | str | None = None,
separators: Tuple[str, str] | None = None,
default: Callable | None = None,
sort_keys: bool = False,
**kw) ‑> str
class ExperimentSummaryRecord (training_loss: str | None = '',
validation_loss: str | None = '',
training_accuracy: str | None = '',
validation_accuracy: str | None = '',
number_of_epochs: str | None = '',
custom_fields: Dict[str, str] = <factory>)

Model class for storing the summary of an experiment in Markov

Static methods

def from_dict(kvs: dict | list | str | int | float | bool | None, *, infer_missing=False) ‑> ~A
def from_json(s: str | bytes | bytearray,
*,
parse_float=None,
parse_int=None,
parse_constant=None,
infer_missing=False,
**kw) ‑> ~A
def schema(*,
infer_missing: bool = False,
only=None,
exclude=(),
many: bool = False,
context=None,
load_only=(),
dump_only=(),
partial: bool = False,
unknown=None) ‑> dataclasses_json.mm.SchemaF[~A]

Instance variables

var custom_fields : Dict[str, str]
var number_of_epochs : str | None
var training_accuracy : str | None
var training_loss : str | None
var validation_accuracy : str | None
var validation_loss : str | None

Methods

def get_dict(self) ‑> Dict
def get_json(self) ‑> str
def to_dict(self, encode_json=False) ‑> Dict[str, dict | list | str | int | float | bool | None]
def to_json(self,
*,
skipkeys: bool = False,
ensure_ascii: bool = True,
check_circular: bool = True,
allow_nan: bool = True,
indent: int | str | None = None,
separators: Tuple[str, str] | None = None,
default: Callable | None = None,
sort_keys: bool = False,
**kw) ‑> str
class ExperimentSystemMetricsKeys (value, names=None, *, module=None, qualname=None, type=None, start=1)

An enumeration.

Ancestors

  • builtins.str
  • enum.Enum

Class variables

var CPU_PERCENT : Final
var GPU_LOAD : Final
var GPU_MEMORY_USED_IN_MB : Final
var GPU_MEMORY_USED_PERCENT : Final
var GPU_TEMPERATURE
var MEMORY_USED_MB : Final
var MEMORY_USED_PERCENT : Final
var PROCESS_THREADS : Final
class GetExperimentPackageRequirementsRequest (experiment_id: str)

GetExperimentPackageRequirementsRequest(experiment_id: str)

Static methods

def from_dict(kvs: dict | list | str | int | float | bool | None, *, infer_missing=False) ‑> ~A
def from_json(s: str | bytes | bytearray,
*,
parse_float=None,
parse_int=None,
parse_constant=None,
infer_missing=False,
**kw) ‑> ~A
def schema(*,
infer_missing: bool = False,
only=None,
exclude=(),
many: bool = False,
context=None,
load_only=(),
dump_only=(),
partial: bool = False,
unknown=None) ‑> dataclasses_json.mm.SchemaF[~A]

Instance variables

var experiment_id : str

Methods

def get_dict(self) ‑> Dict
def get_json(self) ‑> str
def to_dict(self, encode_json=False) ‑> Dict[str, dict | list | str | int | float | bool | None]
def to_json(self,
*,
skipkeys: bool = False,
ensure_ascii: bool = True,
check_circular: bool = True,
allow_nan: bool = True,
indent: int | str | None = None,
separators: Tuple[str, str] | None = None,
default: Callable | None = None,
sort_keys: bool = False,
**kw) ‑> str
class GetExperimentPackageRequirementsResponse (experiment_id: str,
package_requirements: Dict[str, str] = <factory>,
python_version: str = '',
return_code: str = 'COMMAND_FAILED',
message: str | None = '',
create_data: str = '')

GetExperimentPackageRequirementsResponse(experiment_id: str, package_requirements: Dict[str, str] = , python_version: str = '', return_code: str = 'COMMAND_FAILED', message: Optional[str] = '', create_data: str = '')

Static methods

def from_dict(kvs: dict | list | str | int | float | bool | None, *, infer_missing=False) ‑> ~A
def from_json(s: str | bytes | bytearray,
*,
parse_float=None,
parse_int=None,
parse_constant=None,
infer_missing=False,
**kw) ‑> ~A
def schema(*,
infer_missing: bool = False,
only=None,
exclude=(),
many: bool = False,
context=None,
load_only=(),
dump_only=(),
partial: bool = False,
unknown=None) ‑> dataclasses_json.mm.SchemaF[~A]

Instance variables

var create_data : str
var experiment_id : str
var message : str | None
var package_requirements : Dict[str, str]
var python_version : str
var return_code : str

Methods

def get_dict(self) ‑> Dict
def get_json(self) ‑> str
def ok(self) ‑> bool
def to_dict(self, encode_json=False) ‑> Dict[str, dict | list | str | int | float | bool | None]
def to_json(self,
*,
skipkeys: bool = False,
ensure_ascii: bool = True,
check_circular: bool = True,
allow_nan: bool = True,
indent: int | str | None = None,
separators: Tuple[str, str] | None = None,
default: Callable | None = None,
sort_keys: bool = False,
**kw) ‑> str
class SendExperimentSummaryResponse (return_code: str, message: str | None = '')

SendExperimentSummaryResponse(return_code: str, message: Optional[str] = '')

Ancestors

Static methods

def from_dict(kvs: dict | list | str | int | float | bool | None, *, infer_missing=False) ‑> ~A
def from_json(s: str | bytes | bytearray,
*,
parse_float=None,
parse_int=None,
parse_constant=None,
infer_missing=False,
**kw) ‑> ~A
def schema(*,
infer_missing: bool = False,
only=None,
exclude=(),
many: bool = False,
context=None,
load_only=(),
dump_only=(),
partial: bool = False,
unknown=None) ‑> dataclasses_json.mm.SchemaF[~A]

Instance variables

var message : str | None
var return_code : str

Methods

def to_dict(self, encode_json=False) ‑> Dict[str, dict | list | str | int | float | bool | None]
def to_json(self,
*,
skipkeys: bool = False,
ensure_ascii: bool = True,
check_circular: bool = True,
allow_nan: bool = True,
indent: int | str | None = None,
separators: Tuple[str, str] | None = None,
default: Callable | None = None,
sort_keys: bool = False,
**kw) ‑> str
class SetExperimentSummaryRequest (experiment_id: str,
summary: ExperimentSummaryRecord)

SetExperimentSummaryRequest(experiment_id: str, summary: markov.data_models.experiment_recording.ExperimentSummaryRecord)

Static methods

def from_dict(kvs: dict | list | str | int | float | bool | None, *, infer_missing=False) ‑> ~A
def from_json(s: str | bytes | bytearray,
*,
parse_float=None,
parse_int=None,
parse_constant=None,
infer_missing=False,
**kw) ‑> ~A
def schema(*,
infer_missing: bool = False,
only=None,
exclude=(),
many: bool = False,
context=None,
load_only=(),
dump_only=(),
partial: bool = False,
unknown=None) ‑> dataclasses_json.mm.SchemaF[~A]

Instance variables

var experiment_id : str
var summaryExperimentSummaryRecord

Methods

def get_dict(self) ‑> Dict
def get_json(self) ‑> str
def to_dict(self, encode_json=False) ‑> Dict[str, dict | list | str | int | float | bool | None]
def to_json(self,
*,
skipkeys: bool = False,
ensure_ascii: bool = True,
check_circular: bool = True,
allow_nan: bool = True,
indent: int | str | None = None,
separators: Tuple[str, str] | None = None,
default: Callable | None = None,
sort_keys: bool = False,
**kw) ‑> str
class StopRecordingResponse (return_code: str, message: str | None = '')

StopRecordingResponse(return_code: str, message: Optional[str] = '')

Ancestors

Static methods

def from_dict(kvs: dict | list | str | int | float | bool | None, *, infer_missing=False) ‑> ~A
def from_json(s: str | bytes | bytearray,
*,
parse_float=None,
parse_int=None,
parse_constant=None,
infer_missing=False,
**kw) ‑> ~A
def schema(*,
infer_missing: bool = False,
only=None,
exclude=(),
many: bool = False,
context=None,
load_only=(),
dump_only=(),
partial: bool = False,
unknown=None) ‑> dataclasses_json.mm.SchemaF[~A]

Instance variables

var message : str | None
var return_code : str

Methods

def to_dict(self, encode_json=False) ‑> Dict[str, dict | list | str | int | float | bool | None]
def to_json(self,
*,
skipkeys: bool = False,
ensure_ascii: bool = True,
check_circular: bool = True,
allow_nan: bool = True,
indent: int | str | None = None,
separators: Tuple[str, str] | None = None,
default: Callable | None = None,
sort_keys: bool = False,
**kw) ‑> str
class UpsertExperimentPackageRequirementsRequest (experiment_id: str, package_requirements: Dict = <factory>)

UpsertExperimentPackageRequirementsRequest(experiment_id: str, package_requirements: Dict = )

Static methods

def from_dict(kvs: dict | list | str | int | float | bool | None, *, infer_missing=False) ‑> ~A
def from_json(s: str | bytes | bytearray,
*,
parse_float=None,
parse_int=None,
parse_constant=None,
infer_missing=False,
**kw) ‑> ~A
def schema(*,
infer_missing: bool = False,
only=None,
exclude=(),
many: bool = False,
context=None,
load_only=(),
dump_only=(),
partial: bool = False,
unknown=None) ‑> dataclasses_json.mm.SchemaF[~A]

Instance variables

var experiment_id : str
var package_requirements : Dict

Methods

def to_dict(self, encode_json=False) ‑> Dict[str, dict | list | str | int | float | bool | None]
def to_json(self,
*,
skipkeys: bool = False,
ensure_ascii: bool = True,
check_circular: bool = True,
allow_nan: bool = True,
indent: int | str | None = None,
separators: Tuple[str, str] | None = None,
default: Callable | None = None,
sort_keys: bool = False,
**kw) ‑> str
class UpsertExperimentPackageRequirementsResponse (return_code: str, message: str | None = '')

UpsertExperimentPackageRequirementsResponse(return_code: str, message: Optional[str] = '')

Ancestors

Static methods

def from_dict(kvs: dict | list | str | int | float | bool | None, *, infer_missing=False) ‑> ~A
def from_json(s: str | bytes | bytearray,
*,
parse_float=None,
parse_int=None,
parse_constant=None,
infer_missing=False,
**kw) ‑> ~A
def schema(*,
infer_missing: bool = False,
only=None,
exclude=(),
many: bool = False,
context=None,
load_only=(),
dump_only=(),
partial: bool = False,
unknown=None) ‑> dataclasses_json.mm.SchemaF[~A]

Instance variables

var message : str | None
var return_code : str

Methods

def to_dict(self, encode_json=False) ‑> Dict[str, dict | list | str | int | float | bool | None]
def to_json(self,
*,
skipkeys: bool = False,
ensure_ascii: bool = True,
check_circular: bool = True,
allow_nan: bool = True,
indent: int | str | None = None,
separators: Tuple[str, str] | None = None,
default: Callable | None = None,
sort_keys: bool = False,
**kw) ‑> str