flip.nvflare.controllers.init_training

Classes

InitTraining

The controller that is executed pre-training and is a part of the FLIP training model

Module Contents

class flip.nvflare.controllers.init_training.InitTraining(model_id: str, min_clients: int = FlipConstants.MIN_CLIENTS, flip: flip.FLIP = FLIP(), cleanup_timeout: int = 600)[source]

Bases: nvflare.apis.impl.controller.Controller

The controller that is executed pre-training and is a part of the FLIP training model

The InitTraining workflow sends a request to the Central Hub, stating that training has initiated and executes the client cleanup task.

Parameters:
  • model_id (str) – ID of the model that the training is being performed under.

  • min_clients (int, optional) – Minimum number of clients. Defaults to 1 for the aggregation to take place with successful results.

  • cleanup_timeout (int, optional) – Timeout for image cleanup, defaults to 600 seconds (10 minutes)

Raises:

ValueError

  • when the model ID is not a valid UUID.

  • when the minimum number of clients specified is less than 1

  • when cleanup_timeout is less the 0

flip[source]
start_controller(fl_ctx: nvflare.apis.fl_context.FLContext)[source]
control_flow(abort_signal: nvflare.apis.signal.Signal, fl_ctx: nvflare.apis.fl_context.FLContext)[source]
stop_controller(fl_ctx: nvflare.apis.fl_context.FLContext) None[source]
process_result_of_unknown_task(client: nvflare.apis.client.Client, task_name, client_task_id, result: nvflare.apis.shareable.Shareable, fl_ctx: nvflare.apis.fl_context.FLContext) None[source]