Skip to main content

train_and_evaluate

Algorithm to train and evaluate a model on remote data.

Classes

ModelTrainingAndEvaluation

class ModelTrainingAndEvaluation(    *,    model: _DistributedModelTypeOrReference,    pretrained_file: Optional[Union[str, os.PathLike]] = None,    **kwargs: Any,):

Algorithm for training a model, evaluating it and returning metrics.

Arguments

  • model: The model to train and evaluate on remote data.

Attributes

  • name: The name of the algorithm.
  • model: The model to train and evaluate on remote data.
note

The metrics cannot currently be specified by the user.

Ancestors

  • bitfount.federated.algorithms.model_algorithms.base._BaseModelAlgorithmFactory
  • bitfount.federated.algorithms.base._BaseAlgorithmFactory
  • abc.ABC
  • bitfount.federated.roles._RolesMixIn
  • bitfount.types._BaseSerializableObjectMixIn

Methods


def modeller(    self, **kwargs: Any,)> bitfount.federated.algorithms.model_algorithms.train_and_evaluate._ModellerSide:

Returns the modeller side of the ModelTrainingAndEvaluation algorithm.

def worker(    self, hub: BitfountHub, **kwargs: Any,)> bitfount.federated.algorithms.model_algorithms.train_and_evaluate._WorkerSide:

Returns the worker side of the ModelTrainingAndEvaluation algorithm.

Arguments

  • hub: BitfountHub object to use for communication with the hub.

Variables

  • static nested_fields : ClassVar[Dict[str, Mapping[str, Any]]]