nvflare.app_common.abstract.formatter module

class Formatter[source]

Bases: FLComponent

Init FLComponent.

The FLComponent is the base class of all FL Components. (executors, controllers, responders, filters, aggregators, and widgets are all FLComponents)

FLComponents have the capability to handle and fire events and contain various methods for logging.

abstract format(fl_ctx: FLContext) str[source]

Format the data into human readable string.

Parameters:

fl_ctx (FLContext) – FL Context object.

Returns:

Human readable string.

Return type:

str