DPFedAvgFixed¶
- class DPFedAvgFixed(strategy: Strategy, num_sampled_clients: int, clip_norm: float, noise_multiplier: float = 1, server_side_noising: bool = True)[소스]¶
기반 클래스:
Strategy
Wrapper for configuring a Strategy for DP with Fixed Clipping.
경고
This class is deprecated and will be removed in a future release.
메소드
aggregate_evaluate
(server_round, results, ...)Aggregate evaluation losses using the given strategy.
aggregate_fit
(server_round, results, failures)Aggregate training results using unweighted aggregation.
configure_evaluate
(server_round, parameters, ...)Configure the next round of evaluation using the specified strategy.
configure_fit
(server_round, parameters, ...)Configure the next round of training incorporating Differential Privacy (DP).
evaluate
(server_round, parameters)Evaluate model parameters using an evaluation function from the strategy.
initialize_parameters
(client_manager)Initialize global model parameters using given strategy.
- aggregate_evaluate(server_round: int, results: list[tuple[ClientProxy, EvaluateRes]], failures: list[tuple[ClientProxy, EvaluateRes] | BaseException]) tuple[float | None, dict[str, bool | bytes | float | int | str]] [소스]¶
Aggregate evaluation losses using the given strategy.
- aggregate_fit(server_round: int, results: list[tuple[ClientProxy, FitRes]], failures: list[tuple[ClientProxy, FitRes] | BaseException]) tuple[Parameters | None, dict[str, bool | bytes | float | int | str]] [소스]¶
Aggregate training results using unweighted aggregation.
- configure_evaluate(server_round: int, parameters: Parameters, client_manager: ClientManager) list[tuple[ClientProxy, EvaluateIns]] [소스]¶
Configure the next round of evaluation using the specified strategy.
- 매개변수:
server_round (int) – The current round of federated learning.
parameters (Parameters) – 현재(전역) 모델 매개변수입니다.
client_manager (ClientManager) – The client manager which holds all currently connected clients.
- 반환:
evaluate_configuration – A list of tuples. Each tuple in the list identifies a ClientProxy and the EvaluateIns for this particular ClientProxy. If a particular ClientProxy is not included in this list, it means that this ClientProxy will not participate in the next round of federated evaluation.
- 반환 형식:
List[Tuple[ClientProxy, EvaluateIns]]
- configure_fit(server_round: int, parameters: Parameters, client_manager: ClientManager) list[tuple[ClientProxy, FitIns]] [소스]¶
Configure the next round of training incorporating Differential Privacy (DP).
Configuration of the next training round includes information related to DP, such as clip norm and noise stddev.
- 매개변수:
server_round (int) – The current round of federated learning.
parameters (Parameters) – 현재(전역) 모델 매개변수입니다.
client_manager (ClientManager) – The client manager which holds all currently connected clients.
- 반환:
fit_configuration – A list of tuples. Each tuple in the list identifies a ClientProxy and the FitIns for this particular ClientProxy. If a particular ClientProxy is not included in this list, it means that this ClientProxy will not participate in the next round of federated learning.
- 반환 형식:
List[Tuple[ClientProxy, FitIns]]
- evaluate(server_round: int, parameters: Parameters) tuple[float, dict[str, bool | bytes | float | int | str]] | None [소스]¶
Evaluate model parameters using an evaluation function from the strategy.
- initialize_parameters(client_manager: ClientManager) Parameters | None [소스]¶
Initialize global model parameters using given strategy.