1# Copyright 2022 Google LLC 2# 3# Licensed under the Apache License, Version 2.0 (the "License"); 4# you may not use this file except in compliance with the License. 5# You may obtain a copy of the License at 6# 7# http://www.apache.org/licenses/LICENSE-2.0 8# 9# Unless required by applicable law or agreed to in writing, software 10# distributed under the License is distributed on an "AS IS" BASIS, 11# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 12# See the License for the specific language governing permissions and 13# limitations under the License. 14 15# Aggregation Protocol Package 16 17load("//fcp:config.bzl", "FCP_COPTS") 18 19package( 20 default_visibility = ["//fcp/aggregation:internal"], 21 licenses = ["notice"], # Apache 2.0 22) 23 24cc_library( 25 name = "simple_aggregation", 26 srcs = [ 27 "simple_aggregation_protocol.cc", 28 ], 29 hdrs = [ 30 "simple_aggregation_protocol.h", 31 ], 32 copts = FCP_COPTS, 33 deps = [ 34 "//fcp/aggregation/core:aggregator", 35 "//fcp/aggregation/core:federated_sum", 36 "//fcp/aggregation/core:tensor", 37 "//fcp/aggregation/protocol:aggregation_protocol", 38 "//fcp/aggregation/protocol:cc_proto", 39 "//fcp/aggregation/protocol:checkpoint_builder", 40 "//fcp/aggregation/protocol:checkpoint_parser", 41 "//fcp/aggregation/protocol:configuration_cc_proto", 42 "//fcp/aggregation/protocol:resource_resolver", 43 "//fcp/aggregation/tensorflow:converters", 44 "//fcp/base", 45 "//fcp/protos:plan_cc_proto", 46 "@com_google_absl//absl/base:core_headers", 47 "@com_google_absl//absl/container:flat_hash_map", 48 "@com_google_absl//absl/memory", 49 "@com_google_absl//absl/status", 50 "@com_google_absl//absl/status:statusor", 51 "@com_google_absl//absl/strings", 52 "@com_google_absl//absl/strings:cord", 53 "@com_google_absl//absl/strings:str_format", 54 "@com_google_absl//absl/synchronization", 55 ], 56 alwayslink = 1, 57) 58 59cc_test( 60 name = "simple_aggregation_test", 61 srcs = ["simple_aggregation_protocol_test.cc"], 62 copts = FCP_COPTS, 63 deps = [ 64 ":simple_aggregation", 65 "//fcp/aggregation/core:aggregator", 66 "//fcp/aggregation/core:tensor", 67 "//fcp/aggregation/protocol:cc_proto", 68 "//fcp/aggregation/protocol:checkpoint_builder", 69 "//fcp/aggregation/protocol:checkpoint_parser", 70 "//fcp/aggregation/protocol:configuration_cc_proto", 71 "//fcp/aggregation/protocol/testing:mock_callback", 72 "//fcp/aggregation/testing", 73 "//fcp/aggregation/testing:test_data", 74 "//fcp/base", 75 "//fcp/base:scheduler", 76 "//fcp/testing", 77 "@com_google_absl//absl/status", 78 "@com_google_absl//absl/status:statusor", 79 "@com_google_absl//absl/strings:cord", 80 "@com_google_absl//absl/synchronization", 81 "@com_google_googletest//:gtest_main", 82 ], 83) 84