flwr-nightly 1.7.0.dev20231228__tar.gz → 1.7.0.dev20240104__tar.gz

Sign up to get free protection for your applications and to get access to all the features.
Files changed (137) hide show
  1. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/PKG-INFO +1 -1
  2. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/pyproject.toml +1 -1
  3. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/client/app.py +3 -5
  4. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/client/grpc_client/connection.py +1 -1
  5. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/client/message_handler/message_handler.py +1 -1
  6. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/client/message_handler/task_handler.py +5 -5
  7. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/client/node_state.py +10 -12
  8. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/client/node_state_tests.py +7 -7
  9. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/driver/app.py +4 -4
  10. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/driver/driver.py +11 -11
  11. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/driver/driver_client_proxy.py +3 -5
  12. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/proto/driver_pb2.py +16 -16
  13. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/proto/driver_pb2.pyi +8 -8
  14. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/proto/task_pb2.py +20 -20
  15. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/proto/task_pb2.pyi +8 -8
  16. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/server/driver/driver_servicer.py +3 -3
  17. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/server/state/in_memory_state.py +15 -15
  18. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/server/state/sqlite_state.py +23 -23
  19. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/server/state/state.py +4 -4
  20. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/simulation/ray_transport/ray_client_proxy.py +5 -5
  21. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/LICENSE +0 -0
  22. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/README.md +0 -0
  23. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/__init__.py +0 -0
  24. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/client/__init__.py +0 -0
  25. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/client/client.py +0 -0
  26. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/client/dpfedavg_numpy_client.py +0 -0
  27. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/client/flower.py +0 -0
  28. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/client/grpc_client/__init__.py +0 -0
  29. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/client/grpc_rere_client/__init__.py +0 -0
  30. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/client/grpc_rere_client/connection.py +0 -0
  31. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/client/message_handler/__init__.py +0 -0
  32. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/client/middleware/__init__.py +0 -0
  33. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/client/middleware/utils.py +0 -0
  34. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/client/numpy_client.py +0 -0
  35. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/client/rest_client/__init__.py +0 -0
  36. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/client/rest_client/connection.py +0 -0
  37. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/client/secure_aggregation/__init__.py +0 -0
  38. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/client/secure_aggregation/handler.py +0 -0
  39. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/client/secure_aggregation/secaggplus_handler.py +0 -0
  40. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/client/typing.py +0 -0
  41. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/client/workload_state.py +0 -0
  42. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/common/__init__.py +0 -0
  43. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/common/address.py +0 -0
  44. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/common/constant.py +0 -0
  45. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/common/date.py +0 -0
  46. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/common/dp.py +0 -0
  47. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/common/grpc.py +0 -0
  48. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/common/logger.py +0 -0
  49. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/common/parameter.py +0 -0
  50. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/common/retry_invoker.py +0 -0
  51. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/common/secure_aggregation/__init__.py +0 -0
  52. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/common/secure_aggregation/crypto/__init__.py +0 -0
  53. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/common/secure_aggregation/crypto/shamir.py +0 -0
  54. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/common/secure_aggregation/crypto/symmetric_encryption.py +0 -0
  55. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/common/secure_aggregation/ndarrays_arithmetic.py +0 -0
  56. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/common/secure_aggregation/quantization.py +0 -0
  57. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/common/secure_aggregation/secaggplus_constants.py +0 -0
  58. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/common/secure_aggregation/secaggplus_utils.py +0 -0
  59. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/common/serde.py +0 -0
  60. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/common/telemetry.py +0 -0
  61. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/common/typing.py +0 -0
  62. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/common/version.py +0 -0
  63. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/driver/__init__.py +0 -0
  64. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/driver/grpc_driver.py +0 -0
  65. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/flower/__init__.py +0 -0
  66. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/proto/__init__.py +0 -0
  67. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/proto/driver_pb2_grpc.py +0 -0
  68. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/proto/driver_pb2_grpc.pyi +0 -0
  69. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/proto/fleet_pb2.py +0 -0
  70. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/proto/fleet_pb2.pyi +0 -0
  71. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/proto/fleet_pb2_grpc.py +0 -0
  72. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/proto/fleet_pb2_grpc.pyi +0 -0
  73. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/proto/node_pb2.py +0 -0
  74. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/proto/node_pb2.pyi +0 -0
  75. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/proto/node_pb2_grpc.py +0 -0
  76. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/proto/node_pb2_grpc.pyi +0 -0
  77. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/proto/task_pb2_grpc.py +0 -0
  78. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/proto/task_pb2_grpc.pyi +0 -0
  79. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/proto/transport_pb2.py +0 -0
  80. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/proto/transport_pb2.pyi +0 -0
  81. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/proto/transport_pb2_grpc.py +0 -0
  82. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/proto/transport_pb2_grpc.pyi +0 -0
  83. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/py.typed +0 -0
  84. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/server/__init__.py +0 -0
  85. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/server/app.py +0 -0
  86. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/server/client_manager.py +0 -0
  87. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/server/client_proxy.py +0 -0
  88. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/server/criterion.py +0 -0
  89. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/server/driver/__init__.py +0 -0
  90. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/server/fleet/__init__.py +0 -0
  91. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/server/fleet/grpc_bidi/__init__.py +0 -0
  92. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/server/fleet/grpc_bidi/driver_client_manager.py +0 -0
  93. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/server/fleet/grpc_bidi/flower_service_servicer.py +0 -0
  94. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/server/fleet/grpc_bidi/grpc_bridge.py +0 -0
  95. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/server/fleet/grpc_bidi/grpc_client_proxy.py +0 -0
  96. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/server/fleet/grpc_bidi/grpc_server.py +0 -0
  97. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/server/fleet/grpc_bidi/ins_scheduler.py +0 -0
  98. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/server/fleet/grpc_rere/__init__.py +0 -0
  99. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/server/fleet/grpc_rere/fleet_servicer.py +0 -0
  100. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/server/fleet/message_handler/__init__.py +0 -0
  101. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/server/fleet/message_handler/message_handler.py +0 -0
  102. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/server/fleet/rest_rere/__init__.py +0 -0
  103. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/server/fleet/rest_rere/rest_api.py +0 -0
  104. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/server/history.py +0 -0
  105. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/server/server.py +0 -0
  106. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/server/state/__init__.py +0 -0
  107. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/server/state/state_factory.py +0 -0
  108. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/server/strategy/__init__.py +0 -0
  109. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/server/strategy/aggregate.py +0 -0
  110. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/server/strategy/bulyan.py +0 -0
  111. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/server/strategy/dpfedavg_adaptive.py +0 -0
  112. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/server/strategy/dpfedavg_fixed.py +0 -0
  113. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/server/strategy/fault_tolerant_fedavg.py +0 -0
  114. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/server/strategy/fedadagrad.py +0 -0
  115. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/server/strategy/fedadam.py +0 -0
  116. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/server/strategy/fedavg.py +0 -0
  117. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/server/strategy/fedavg_android.py +0 -0
  118. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/server/strategy/fedavgm.py +0 -0
  119. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/server/strategy/fedmedian.py +0 -0
  120. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/server/strategy/fedopt.py +0 -0
  121. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/server/strategy/fedprox.py +0 -0
  122. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/server/strategy/fedtrimmedavg.py +0 -0
  123. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/server/strategy/fedxgb_bagging.py +0 -0
  124. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/server/strategy/fedxgb_cyclic.py +0 -0
  125. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/server/strategy/fedxgb_nn_avg.py +0 -0
  126. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/server/strategy/fedyogi.py +0 -0
  127. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/server/strategy/krum.py +0 -0
  128. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/server/strategy/qfedavg.py +0 -0
  129. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/server/strategy/strategy.py +0 -0
  130. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/server/utils/__init__.py +0 -0
  131. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/server/utils/tensorboard.py +0 -0
  132. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/server/utils/validator.py +0 -0
  133. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/simulation/__init__.py +0 -0
  134. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/simulation/app.py +0 -0
  135. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/simulation/ray_transport/__init__.py +0 -0
  136. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/simulation/ray_transport/ray_actor.py +0 -0
  137. {flwr_nightly-1.7.0.dev20231228 → flwr_nightly-1.7.0.dev20240104}/src/py/flwr/simulation/ray_transport/utils.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: flwr-nightly
3
- Version: 1.7.0.dev20231228
3
+ Version: 1.7.0.dev20240104
4
4
  Summary: Flower: A Friendly Federated Learning Framework
5
5
  Home-page: https://flower.dev
6
6
  License: Apache-2.0
@@ -4,7 +4,7 @@ build-backend = "poetry.core.masonry.api"
4
4
 
5
5
  [tool.poetry]
6
6
  name = "flwr-nightly"
7
- version = "1.7.0-dev20231228"
7
+ version = "1.7.0-dev20240104"
8
8
  description = "Flower: A Friendly Federated Learning Framework"
9
9
  license = "Apache-2.0"
10
10
  authors = ["The Flower Authors <hello@flower.dev>"]
@@ -349,7 +349,7 @@ def _start_client_internal(
349
349
  break
350
350
 
351
351
  # Register state
352
- node_state.register_workloadstate(workload_id=task_ins.workload_id)
352
+ node_state.register_workloadstate(run_id=task_ins.run_id)
353
353
 
354
354
  # Load app
355
355
  app: Flower = load_flower_callable_fn()
@@ -357,15 +357,13 @@ def _start_client_internal(
357
357
  # Handle task message
358
358
  fwd_msg: Fwd = Fwd(
359
359
  task_ins=task_ins,
360
- state=node_state.retrieve_workloadstate(
361
- workload_id=task_ins.workload_id
362
- ),
360
+ state=node_state.retrieve_workloadstate(run_id=task_ins.run_id),
363
361
  )
364
362
  bwd_msg: Bwd = app(fwd=fwd_msg)
365
363
 
366
364
  # Update node state
367
365
  node_state.update_workloadstate(
368
- workload_id=bwd_msg.task_res.workload_id,
366
+ run_id=bwd_msg.task_res.run_id,
369
367
  workload_state=bwd_msg.state,
370
368
  )
371
369
 
@@ -119,7 +119,7 @@ def grpc_connection(
119
119
  return TaskIns(
120
120
  task_id=str(uuid.uuid4()),
121
121
  group_id="",
122
- workload_id=0,
122
+ run_id=0,
123
123
  task=Task(
124
124
  producer=Node(node_id=0, anonymous=True),
125
125
  consumer=Node(node_id=0, anonymous=True),
@@ -112,7 +112,7 @@ def handle(
112
112
  task_res = TaskRes(
113
113
  task_id="",
114
114
  group_id="",
115
- workload_id=0,
115
+ run_id=0,
116
116
  task=Task(
117
117
  ancestry=[],
118
118
  sa=SecureAggregation(named_values=serde.named_values_to_proto(res)),
@@ -70,7 +70,7 @@ def validate_task_res(task_res: TaskRes) -> bool:
70
70
  Returns
71
71
  -------
72
72
  is_valid: bool
73
- True if the `task_id`, `group_id`, and `workload_id` fields in TaskRes
73
+ True if the `task_id`, `group_id`, and `run_id` fields in TaskRes
74
74
  and the `producer`, `consumer`, and `ancestry` fields in its sub-message Task
75
75
  are not initialized accidentally elsewhere,
76
76
  False otherwise.
@@ -84,7 +84,7 @@ def validate_task_res(task_res: TaskRes) -> bool:
84
84
  if (
85
85
  "task_id" in initialized_fields_in_task_res
86
86
  or "group_id" in initialized_fields_in_task_res
87
- or "workload_id" in initialized_fields_in_task_res
87
+ or "run_id" in initialized_fields_in_task_res
88
88
  or "producer" in initialized_fields_in_task
89
89
  or "consumer" in initialized_fields_in_task
90
90
  or "ancestry" in initialized_fields_in_task
@@ -129,7 +129,7 @@ def wrap_client_message_in_task_res(client_message: ClientMessage) -> TaskRes:
129
129
  return TaskRes(
130
130
  task_id="",
131
131
  group_id="",
132
- workload_id=0,
132
+ run_id=0,
133
133
  task=Task(ancestry=[], legacy_client_message=client_message),
134
134
  )
135
135
 
@@ -139,7 +139,7 @@ def configure_task_res(
139
139
  ) -> TaskRes:
140
140
  """Set the metadata of a TaskRes.
141
141
 
142
- Fill `group_id` and `workload_id` in TaskRes
142
+ Fill `group_id` and `run_id` in TaskRes
143
143
  and `producer`, `consumer`, and `ancestry` in Task in TaskRes.
144
144
 
145
145
  `producer` in Task in TaskRes will remain unchanged/unset.
@@ -152,7 +152,7 @@ def configure_task_res(
152
152
  task_res = TaskRes(
153
153
  task_id="", # This will be generated by the server
154
154
  group_id=ref_task_ins.group_id,
155
- workload_id=ref_task_ins.workload_id,
155
+ run_id=ref_task_ins.run_id,
156
156
  task=task_res.task,
157
157
  )
158
158
  # pylint: disable-next=no-member
@@ -27,24 +27,22 @@ class NodeState:
27
27
  self._meta: Dict[str, Any] = {} # holds metadata about the node
28
28
  self.workload_states: Dict[int, WorkloadState] = {}
29
29
 
30
- def register_workloadstate(self, workload_id: int) -> None:
30
+ def register_workloadstate(self, run_id: int) -> None:
31
31
  """Register new workload state for this node."""
32
- if workload_id not in self.workload_states:
33
- self.workload_states[workload_id] = WorkloadState({})
32
+ if run_id not in self.workload_states:
33
+ self.workload_states[run_id] = WorkloadState({})
34
34
 
35
- def retrieve_workloadstate(self, workload_id: int) -> WorkloadState:
36
- """Get workload state given a workload_id."""
37
- if workload_id in self.workload_states:
38
- return self.workload_states[workload_id]
35
+ def retrieve_workloadstate(self, run_id: int) -> WorkloadState:
36
+ """Get workload state given a run_id."""
37
+ if run_id in self.workload_states:
38
+ return self.workload_states[run_id]
39
39
 
40
40
  raise RuntimeError(
41
- f"WorkloadState for workload_id={workload_id} doesn't exist."
41
+ f"WorkloadState for run_id={run_id} doesn't exist."
42
42
  " A workload must be registered before it can be retrieved or updated "
43
43
  " by a client."
44
44
  )
45
45
 
46
- def update_workloadstate(
47
- self, workload_id: int, workload_state: WorkloadState
48
- ) -> None:
46
+ def update_workloadstate(self, run_id: int, workload_state: WorkloadState) -> None:
49
47
  """Update workload state."""
50
- self.workload_states[workload_id] = workload_state
48
+ self.workload_states[run_id] = workload_state
@@ -32,7 +32,7 @@ def _run_dummy_task(state: WorkloadState) -> WorkloadState:
32
32
  def test_multiworkload_in_node_state() -> None:
33
33
  """Test basic NodeState logic."""
34
34
  # Tasks to perform
35
- tasks = [TaskIns(workload_id=w_id) for w_id in [0, 1, 1, 2, 3, 2, 1, 5]]
35
+ tasks = [TaskIns(run_id=r_id) for r_id in [0, 1, 1, 2, 3, 2, 1, 5]]
36
36
  # the "tasks" is to count how many times each workload is executed
37
37
  expected_values = {0: "1", 1: "1" * 3, 2: "1" * 2, 3: "1", 5: "1"}
38
38
 
@@ -40,20 +40,20 @@ def test_multiworkload_in_node_state() -> None:
40
40
  node_state = NodeState()
41
41
 
42
42
  for task in tasks:
43
- w_id = task.workload_id
43
+ r_id = task.run_id
44
44
 
45
45
  # Register
46
- node_state.register_workloadstate(workload_id=w_id)
46
+ node_state.register_workloadstate(run_id=r_id)
47
47
 
48
48
  # Get workload state
49
- state = node_state.retrieve_workloadstate(workload_id=w_id)
49
+ state = node_state.retrieve_workloadstate(run_id=r_id)
50
50
 
51
51
  # Run "task"
52
52
  updated_state = _run_dummy_task(state)
53
53
 
54
54
  # Update workload state
55
- node_state.update_workloadstate(workload_id=w_id, workload_state=updated_state)
55
+ node_state.update_workloadstate(run_id=r_id, workload_state=updated_state)
56
56
 
57
57
  # Verify values
58
- for w_id, state in node_state.workload_states.items():
59
- assert state.state["counter"] == expected_values[w_id]
58
+ for r_id, state in node_state.workload_states.items():
59
+ assert state.state["counter"] == expected_values[r_id]
@@ -170,8 +170,8 @@ def update_client_manager(
170
170
  and dead nodes will be removed from the ClientManager via
171
171
  `client_manager.unregister()`.
172
172
  """
173
- # Request for workload_id
174
- workload_id = driver.create_workload(driver_pb2.CreateWorkloadRequest()).workload_id
173
+ # Request for run_id
174
+ run_id = driver.create_workload(driver_pb2.CreateWorkloadRequest()).run_id
175
175
 
176
176
  # Loop until the driver is disconnected
177
177
  registered_nodes: Dict[int, DriverClientProxy] = {}
@@ -181,7 +181,7 @@ def update_client_manager(
181
181
  if driver.stub is None:
182
182
  break
183
183
  get_nodes_res = driver.get_nodes(
184
- req=driver_pb2.GetNodesRequest(workload_id=workload_id)
184
+ req=driver_pb2.GetNodesRequest(run_id=run_id)
185
185
  )
186
186
  all_node_ids = {node.node_id for node in get_nodes_res.nodes}
187
187
  dead_nodes = set(registered_nodes).difference(all_node_ids)
@@ -199,7 +199,7 @@ def update_client_manager(
199
199
  node_id=node_id,
200
200
  driver=driver,
201
201
  anonymous=False,
202
- workload_id=workload_id,
202
+ run_id=run_id,
203
203
  )
204
204
  if client_manager.register(client_proxy):
205
205
  registered_nodes[node_id] = client_proxy
@@ -54,37 +54,37 @@ class Driver:
54
54
  self.addr = driver_service_address
55
55
  self.certificates = certificates
56
56
  self.grpc_driver: Optional[GrpcDriver] = None
57
- self.workload_id: Optional[int] = None
57
+ self.run_id: Optional[int] = None
58
58
  self.node = Node(node_id=0, anonymous=True)
59
59
 
60
- def _get_grpc_driver_and_workload_id(self) -> Tuple[GrpcDriver, int]:
60
+ def _get_grpc_driver_and_run_id(self) -> Tuple[GrpcDriver, int]:
61
61
  # Check if the GrpcDriver is initialized
62
- if self.grpc_driver is None or self.workload_id is None:
62
+ if self.grpc_driver is None or self.run_id is None:
63
63
  # Connect and create workload
64
64
  self.grpc_driver = GrpcDriver(
65
65
  driver_service_address=self.addr, certificates=self.certificates
66
66
  )
67
67
  self.grpc_driver.connect()
68
68
  res = self.grpc_driver.create_workload(CreateWorkloadRequest())
69
- self.workload_id = res.workload_id
69
+ self.run_id = res.run_id
70
70
 
71
- return self.grpc_driver, self.workload_id
71
+ return self.grpc_driver, self.run_id
72
72
 
73
73
  def get_nodes(self) -> List[Node]:
74
74
  """Get node IDs."""
75
- grpc_driver, workload_id = self._get_grpc_driver_and_workload_id()
75
+ grpc_driver, run_id = self._get_grpc_driver_and_run_id()
76
76
 
77
77
  # Call GrpcDriver method
78
- res = grpc_driver.get_nodes(GetNodesRequest(workload_id=workload_id))
78
+ res = grpc_driver.get_nodes(GetNodesRequest(run_id=run_id))
79
79
  return list(res.nodes)
80
80
 
81
81
  def push_task_ins(self, task_ins_list: List[TaskIns]) -> List[str]:
82
82
  """Schedule tasks."""
83
- grpc_driver, workload_id = self._get_grpc_driver_and_workload_id()
83
+ grpc_driver, run_id = self._get_grpc_driver_and_run_id()
84
84
 
85
- # Set workload_id
85
+ # Set run_id
86
86
  for task_ins in task_ins_list:
87
- task_ins.workload_id = workload_id
87
+ task_ins.run_id = run_id
88
88
 
89
89
  # Call GrpcDriver method
90
90
  res = grpc_driver.push_task_ins(PushTaskInsRequest(task_ins_list=task_ins_list))
@@ -92,7 +92,7 @@ class Driver:
92
92
 
93
93
  def pull_task_res(self, task_ids: Iterable[str]) -> List[TaskRes]:
94
94
  """Get task results."""
95
- grpc_driver, _ = self._get_grpc_driver_and_workload_id()
95
+ grpc_driver, _ = self._get_grpc_driver_and_run_id()
96
96
 
97
97
  # Call GrpcDriver method
98
98
  res = grpc_driver.pull_task_res(
@@ -31,13 +31,11 @@ SLEEP_TIME = 1
31
31
  class DriverClientProxy(ClientProxy):
32
32
  """Flower client proxy which delegates work using the Driver API."""
33
33
 
34
- def __init__(
35
- self, node_id: int, driver: GrpcDriver, anonymous: bool, workload_id: int
36
- ):
34
+ def __init__(self, node_id: int, driver: GrpcDriver, anonymous: bool, run_id: int):
37
35
  super().__init__(str(node_id))
38
36
  self.node_id = node_id
39
37
  self.driver = driver
40
- self.workload_id = workload_id
38
+ self.run_id = run_id
41
39
  self.anonymous = anonymous
42
40
 
43
41
  def get_properties(
@@ -106,7 +104,7 @@ class DriverClientProxy(ClientProxy):
106
104
  task_ins = task_pb2.TaskIns(
107
105
  task_id="",
108
106
  group_id="",
109
- workload_id=self.workload_id,
107
+ run_id=self.run_id,
110
108
  task=task_pb2.Task(
111
109
  producer=node_pb2.Node(
112
110
  node_id=0,
@@ -16,7 +16,7 @@ from flwr.proto import node_pb2 as flwr_dot_proto_dot_node__pb2
16
16
  from flwr.proto import task_pb2 as flwr_dot_proto_dot_task__pb2
17
17
 
18
18
 
19
- DESCRIPTOR = _descriptor_pool.Default().AddSerializedFile(b'\n\x17\x66lwr/proto/driver.proto\x12\nflwr.proto\x1a\x15\x66lwr/proto/node.proto\x1a\x15\x66lwr/proto/task.proto\"\x17\n\x15\x43reateWorkloadRequest\"-\n\x16\x43reateWorkloadResponse\x12\x13\n\x0bworkload_id\x18\x01 \x01(\x12\"&\n\x0fGetNodesRequest\x12\x13\n\x0bworkload_id\x18\x01 \x01(\x12\"3\n\x10GetNodesResponse\x12\x1f\n\x05nodes\x18\x01 \x03(\x0b\x32\x10.flwr.proto.Node\"@\n\x12PushTaskInsRequest\x12*\n\rtask_ins_list\x18\x01 \x03(\x0b\x32\x13.flwr.proto.TaskIns\"\'\n\x13PushTaskInsResponse\x12\x10\n\x08task_ids\x18\x02 \x03(\t\"F\n\x12PullTaskResRequest\x12\x1e\n\x04node\x18\x01 \x01(\x0b\x32\x10.flwr.proto.Node\x12\x10\n\x08task_ids\x18\x02 \x03(\t\"A\n\x13PullTaskResResponse\x12*\n\rtask_res_list\x18\x01 \x03(\x0b\x32\x13.flwr.proto.TaskRes2\xd0\x02\n\x06\x44river\x12Y\n\x0e\x43reateWorkload\x12!.flwr.proto.CreateWorkloadRequest\x1a\".flwr.proto.CreateWorkloadResponse\"\x00\x12G\n\x08GetNodes\x12\x1b.flwr.proto.GetNodesRequest\x1a\x1c.flwr.proto.GetNodesResponse\"\x00\x12P\n\x0bPushTaskIns\x12\x1e.flwr.proto.PushTaskInsRequest\x1a\x1f.flwr.proto.PushTaskInsResponse\"\x00\x12P\n\x0bPullTaskRes\x12\x1e.flwr.proto.PullTaskResRequest\x1a\x1f.flwr.proto.PullTaskResResponse\"\x00\x62\x06proto3')
19
+ DESCRIPTOR = _descriptor_pool.Default().AddSerializedFile(b'\n\x17\x66lwr/proto/driver.proto\x12\nflwr.proto\x1a\x15\x66lwr/proto/node.proto\x1a\x15\x66lwr/proto/task.proto\"\x17\n\x15\x43reateWorkloadRequest\"(\n\x16\x43reateWorkloadResponse\x12\x0e\n\x06run_id\x18\x01 \x01(\x12\"!\n\x0fGetNodesRequest\x12\x0e\n\x06run_id\x18\x01 \x01(\x12\"3\n\x10GetNodesResponse\x12\x1f\n\x05nodes\x18\x01 \x03(\x0b\x32\x10.flwr.proto.Node\"@\n\x12PushTaskInsRequest\x12*\n\rtask_ins_list\x18\x01 \x03(\x0b\x32\x13.flwr.proto.TaskIns\"\'\n\x13PushTaskInsResponse\x12\x10\n\x08task_ids\x18\x02 \x03(\t\"F\n\x12PullTaskResRequest\x12\x1e\n\x04node\x18\x01 \x01(\x0b\x32\x10.flwr.proto.Node\x12\x10\n\x08task_ids\x18\x02 \x03(\t\"A\n\x13PullTaskResResponse\x12*\n\rtask_res_list\x18\x01 \x03(\x0b\x32\x13.flwr.proto.TaskRes2\xd0\x02\n\x06\x44river\x12Y\n\x0e\x43reateWorkload\x12!.flwr.proto.CreateWorkloadRequest\x1a\".flwr.proto.CreateWorkloadResponse\"\x00\x12G\n\x08GetNodes\x12\x1b.flwr.proto.GetNodesRequest\x1a\x1c.flwr.proto.GetNodesResponse\"\x00\x12P\n\x0bPushTaskIns\x12\x1e.flwr.proto.PushTaskInsRequest\x1a\x1f.flwr.proto.PushTaskInsResponse\"\x00\x12P\n\x0bPullTaskRes\x12\x1e.flwr.proto.PullTaskResRequest\x1a\x1f.flwr.proto.PullTaskResResponse\"\x00\x62\x06proto3')
20
20
 
21
21
 
22
22
 
@@ -91,19 +91,19 @@ if _descriptor._USE_C_DESCRIPTORS == False:
91
91
  _CREATEWORKLOADREQUEST._serialized_start=85
92
92
  _CREATEWORKLOADREQUEST._serialized_end=108
93
93
  _CREATEWORKLOADRESPONSE._serialized_start=110
94
- _CREATEWORKLOADRESPONSE._serialized_end=155
95
- _GETNODESREQUEST._serialized_start=157
96
- _GETNODESREQUEST._serialized_end=195
97
- _GETNODESRESPONSE._serialized_start=197
98
- _GETNODESRESPONSE._serialized_end=248
99
- _PUSHTASKINSREQUEST._serialized_start=250
100
- _PUSHTASKINSREQUEST._serialized_end=314
101
- _PUSHTASKINSRESPONSE._serialized_start=316
102
- _PUSHTASKINSRESPONSE._serialized_end=355
103
- _PULLTASKRESREQUEST._serialized_start=357
104
- _PULLTASKRESREQUEST._serialized_end=427
105
- _PULLTASKRESRESPONSE._serialized_start=429
106
- _PULLTASKRESRESPONSE._serialized_end=494
107
- _DRIVER._serialized_start=497
108
- _DRIVER._serialized_end=833
94
+ _CREATEWORKLOADRESPONSE._serialized_end=150
95
+ _GETNODESREQUEST._serialized_start=152
96
+ _GETNODESREQUEST._serialized_end=185
97
+ _GETNODESRESPONSE._serialized_start=187
98
+ _GETNODESRESPONSE._serialized_end=238
99
+ _PUSHTASKINSREQUEST._serialized_start=240
100
+ _PUSHTASKINSREQUEST._serialized_end=304
101
+ _PUSHTASKINSRESPONSE._serialized_start=306
102
+ _PUSHTASKINSRESPONSE._serialized_end=345
103
+ _PULLTASKRESREQUEST._serialized_start=347
104
+ _PULLTASKRESREQUEST._serialized_end=417
105
+ _PULLTASKRESRESPONSE._serialized_start=419
106
+ _PULLTASKRESRESPONSE._serialized_end=484
107
+ _DRIVER._serialized_start=487
108
+ _DRIVER._serialized_end=823
109
109
  # @@protoc_insertion_point(module_scope)
@@ -22,25 +22,25 @@ global___CreateWorkloadRequest = CreateWorkloadRequest
22
22
 
23
23
  class CreateWorkloadResponse(google.protobuf.message.Message):
24
24
  DESCRIPTOR: google.protobuf.descriptor.Descriptor
25
- WORKLOAD_ID_FIELD_NUMBER: builtins.int
26
- workload_id: builtins.int
25
+ RUN_ID_FIELD_NUMBER: builtins.int
26
+ run_id: builtins.int
27
27
  def __init__(self,
28
28
  *,
29
- workload_id: builtins.int = ...,
29
+ run_id: builtins.int = ...,
30
30
  ) -> None: ...
31
- def ClearField(self, field_name: typing_extensions.Literal["workload_id",b"workload_id"]) -> None: ...
31
+ def ClearField(self, field_name: typing_extensions.Literal["run_id",b"run_id"]) -> None: ...
32
32
  global___CreateWorkloadResponse = CreateWorkloadResponse
33
33
 
34
34
  class GetNodesRequest(google.protobuf.message.Message):
35
35
  """GetNodes messages"""
36
36
  DESCRIPTOR: google.protobuf.descriptor.Descriptor
37
- WORKLOAD_ID_FIELD_NUMBER: builtins.int
38
- workload_id: builtins.int
37
+ RUN_ID_FIELD_NUMBER: builtins.int
38
+ run_id: builtins.int
39
39
  def __init__(self,
40
40
  *,
41
- workload_id: builtins.int = ...,
41
+ run_id: builtins.int = ...,
42
42
  ) -> None: ...
43
- def ClearField(self, field_name: typing_extensions.Literal["workload_id",b"workload_id"]) -> None: ...
43
+ def ClearField(self, field_name: typing_extensions.Literal["run_id",b"run_id"]) -> None: ...
44
44
  global___GetNodesRequest = GetNodesRequest
45
45
 
46
46
  class GetNodesResponse(google.protobuf.message.Message):
@@ -16,7 +16,7 @@ from flwr.proto import node_pb2 as flwr_dot_proto_dot_node__pb2
16
16
  from flwr.proto import transport_pb2 as flwr_dot_proto_dot_transport__pb2
17
17
 
18
18
 
19
- DESCRIPTOR = _descriptor_pool.Default().AddSerializedFile(b'\n\x15\x66lwr/proto/task.proto\x12\nflwr.proto\x1a\x15\x66lwr/proto/node.proto\x1a\x1a\x66lwr/proto/transport.proto\"\xbe\x02\n\x04Task\x12\"\n\x08producer\x18\x01 \x01(\x0b\x32\x10.flwr.proto.Node\x12\"\n\x08\x63onsumer\x18\x02 \x01(\x0b\x32\x10.flwr.proto.Node\x12\x12\n\ncreated_at\x18\x03 \x01(\t\x12\x14\n\x0c\x64\x65livered_at\x18\x04 \x01(\t\x12\x0b\n\x03ttl\x18\x05 \x01(\t\x12\x10\n\x08\x61ncestry\x18\x06 \x03(\t\x12)\n\x02sa\x18\x07 \x01(\x0b\x32\x1d.flwr.proto.SecureAggregation\x12<\n\x15legacy_server_message\x18\x65 \x01(\x0b\x32\x19.flwr.proto.ServerMessageB\x02\x18\x01\x12<\n\x15legacy_client_message\x18\x66 \x01(\x0b\x32\x19.flwr.proto.ClientMessageB\x02\x18\x01\"a\n\x07TaskIns\x12\x0f\n\x07task_id\x18\x01 \x01(\t\x12\x10\n\x08group_id\x18\x02 \x01(\t\x12\x13\n\x0bworkload_id\x18\x03 \x01(\x12\x12\x1e\n\x04task\x18\x04 \x01(\x0b\x32\x10.flwr.proto.Task\"a\n\x07TaskRes\x12\x0f\n\x07task_id\x18\x01 \x01(\t\x12\x10\n\x08group_id\x18\x02 \x01(\t\x12\x13\n\x0bworkload_id\x18\x03 \x01(\x12\x12\x1e\n\x04task\x18\x04 \x01(\x0b\x32\x10.flwr.proto.Task\"\xf3\x03\n\x05Value\x12\x10\n\x06\x64ouble\x18\x01 \x01(\x01H\x00\x12\x10\n\x06sint64\x18\x02 \x01(\x12H\x00\x12\x0e\n\x04\x62ool\x18\x03 \x01(\x08H\x00\x12\x10\n\x06string\x18\x04 \x01(\tH\x00\x12\x0f\n\x05\x62ytes\x18\x05 \x01(\x0cH\x00\x12\x33\n\x0b\x64ouble_list\x18\x15 \x01(\x0b\x32\x1c.flwr.proto.Value.DoubleListH\x00\x12\x33\n\x0bsint64_list\x18\x16 \x01(\x0b\x32\x1c.flwr.proto.Value.Sint64ListH\x00\x12/\n\tbool_list\x18\x17 \x01(\x0b\x32\x1a.flwr.proto.Value.BoolListH\x00\x12\x33\n\x0bstring_list\x18\x18 \x01(\x0b\x32\x1c.flwr.proto.Value.StringListH\x00\x12\x31\n\nbytes_list\x18\x19 \x01(\x0b\x32\x1b.flwr.proto.Value.BytesListH\x00\x1a\x1a\n\nDoubleList\x12\x0c\n\x04vals\x18\x01 \x03(\x01\x1a\x1a\n\nSint64List\x12\x0c\n\x04vals\x18\x01 \x03(\x12\x1a\x18\n\x08\x42oolList\x12\x0c\n\x04vals\x18\x01 \x03(\x08\x1a\x1a\n\nStringList\x12\x0c\n\x04vals\x18\x01 \x03(\t\x1a\x19\n\tBytesList\x12\x0c\n\x04vals\x18\x01 \x03(\x0c\x42\x07\n\x05value\"\xa0\x01\n\x11SecureAggregation\x12\x44\n\x0cnamed_values\x18\x01 \x03(\x0b\x32..flwr.proto.SecureAggregation.NamedValuesEntry\x1a\x45\n\x10NamedValuesEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12 \n\x05value\x18\x02 \x01(\x0b\x32\x11.flwr.proto.Value:\x02\x38\x01\x62\x06proto3')
19
+ DESCRIPTOR = _descriptor_pool.Default().AddSerializedFile(b'\n\x15\x66lwr/proto/task.proto\x12\nflwr.proto\x1a\x15\x66lwr/proto/node.proto\x1a\x1a\x66lwr/proto/transport.proto\"\xbe\x02\n\x04Task\x12\"\n\x08producer\x18\x01 \x01(\x0b\x32\x10.flwr.proto.Node\x12\"\n\x08\x63onsumer\x18\x02 \x01(\x0b\x32\x10.flwr.proto.Node\x12\x12\n\ncreated_at\x18\x03 \x01(\t\x12\x14\n\x0c\x64\x65livered_at\x18\x04 \x01(\t\x12\x0b\n\x03ttl\x18\x05 \x01(\t\x12\x10\n\x08\x61ncestry\x18\x06 \x03(\t\x12)\n\x02sa\x18\x07 \x01(\x0b\x32\x1d.flwr.proto.SecureAggregation\x12<\n\x15legacy_server_message\x18\x65 \x01(\x0b\x32\x19.flwr.proto.ServerMessageB\x02\x18\x01\x12<\n\x15legacy_client_message\x18\x66 \x01(\x0b\x32\x19.flwr.proto.ClientMessageB\x02\x18\x01\"\\\n\x07TaskIns\x12\x0f\n\x07task_id\x18\x01 \x01(\t\x12\x10\n\x08group_id\x18\x02 \x01(\t\x12\x0e\n\x06run_id\x18\x03 \x01(\x12\x12\x1e\n\x04task\x18\x04 \x01(\x0b\x32\x10.flwr.proto.Task\"\\\n\x07TaskRes\x12\x0f\n\x07task_id\x18\x01 \x01(\t\x12\x10\n\x08group_id\x18\x02 \x01(\t\x12\x0e\n\x06run_id\x18\x03 \x01(\x12\x12\x1e\n\x04task\x18\x04 \x01(\x0b\x32\x10.flwr.proto.Task\"\xf3\x03\n\x05Value\x12\x10\n\x06\x64ouble\x18\x01 \x01(\x01H\x00\x12\x10\n\x06sint64\x18\x02 \x01(\x12H\x00\x12\x0e\n\x04\x62ool\x18\x03 \x01(\x08H\x00\x12\x10\n\x06string\x18\x04 \x01(\tH\x00\x12\x0f\n\x05\x62ytes\x18\x05 \x01(\x0cH\x00\x12\x33\n\x0b\x64ouble_list\x18\x15 \x01(\x0b\x32\x1c.flwr.proto.Value.DoubleListH\x00\x12\x33\n\x0bsint64_list\x18\x16 \x01(\x0b\x32\x1c.flwr.proto.Value.Sint64ListH\x00\x12/\n\tbool_list\x18\x17 \x01(\x0b\x32\x1a.flwr.proto.Value.BoolListH\x00\x12\x33\n\x0bstring_list\x18\x18 \x01(\x0b\x32\x1c.flwr.proto.Value.StringListH\x00\x12\x31\n\nbytes_list\x18\x19 \x01(\x0b\x32\x1b.flwr.proto.Value.BytesListH\x00\x1a\x1a\n\nDoubleList\x12\x0c\n\x04vals\x18\x01 \x03(\x01\x1a\x1a\n\nSint64List\x12\x0c\n\x04vals\x18\x01 \x03(\x12\x1a\x18\n\x08\x42oolList\x12\x0c\n\x04vals\x18\x01 \x03(\x08\x1a\x1a\n\nStringList\x12\x0c\n\x04vals\x18\x01 \x03(\t\x1a\x19\n\tBytesList\x12\x0c\n\x04vals\x18\x01 \x03(\x0c\x42\x07\n\x05value\"\xa0\x01\n\x11SecureAggregation\x12\x44\n\x0cnamed_values\x18\x01 \x03(\x0b\x32..flwr.proto.SecureAggregation.NamedValuesEntry\x1a\x45\n\x10NamedValuesEntry\x12\x0b\n\x03key\x18\x01 \x01(\t\x12 \n\x05value\x18\x02 \x01(\x0b\x32\x11.flwr.proto.Value:\x02\x38\x01\x62\x06proto3')
20
20
 
21
21
 
22
22
 
@@ -126,23 +126,23 @@ if _descriptor._USE_C_DESCRIPTORS == False:
126
126
  _TASK._serialized_start=89
127
127
  _TASK._serialized_end=407
128
128
  _TASKINS._serialized_start=409
129
- _TASKINS._serialized_end=506
130
- _TASKRES._serialized_start=508
131
- _TASKRES._serialized_end=605
132
- _VALUE._serialized_start=608
133
- _VALUE._serialized_end=1107
134
- _VALUE_DOUBLELIST._serialized_start=963
135
- _VALUE_DOUBLELIST._serialized_end=989
136
- _VALUE_SINT64LIST._serialized_start=991
137
- _VALUE_SINT64LIST._serialized_end=1017
138
- _VALUE_BOOLLIST._serialized_start=1019
139
- _VALUE_BOOLLIST._serialized_end=1043
140
- _VALUE_STRINGLIST._serialized_start=1045
141
- _VALUE_STRINGLIST._serialized_end=1071
142
- _VALUE_BYTESLIST._serialized_start=1073
143
- _VALUE_BYTESLIST._serialized_end=1098
144
- _SECUREAGGREGATION._serialized_start=1110
145
- _SECUREAGGREGATION._serialized_end=1270
146
- _SECUREAGGREGATION_NAMEDVALUESENTRY._serialized_start=1201
147
- _SECUREAGGREGATION_NAMEDVALUESENTRY._serialized_end=1270
129
+ _TASKINS._serialized_end=501
130
+ _TASKRES._serialized_start=503
131
+ _TASKRES._serialized_end=595
132
+ _VALUE._serialized_start=598
133
+ _VALUE._serialized_end=1097
134
+ _VALUE_DOUBLELIST._serialized_start=953
135
+ _VALUE_DOUBLELIST._serialized_end=979
136
+ _VALUE_SINT64LIST._serialized_start=981
137
+ _VALUE_SINT64LIST._serialized_end=1007
138
+ _VALUE_BOOLLIST._serialized_start=1009
139
+ _VALUE_BOOLLIST._serialized_end=1033
140
+ _VALUE_STRINGLIST._serialized_start=1035
141
+ _VALUE_STRINGLIST._serialized_end=1061
142
+ _VALUE_BYTESLIST._serialized_start=1063
143
+ _VALUE_BYTESLIST._serialized_end=1088
144
+ _SECUREAGGREGATION._serialized_start=1100
145
+ _SECUREAGGREGATION._serialized_end=1260
146
+ _SECUREAGGREGATION_NAMEDVALUESENTRY._serialized_start=1191
147
+ _SECUREAGGREGATION_NAMEDVALUESENTRY._serialized_end=1260
148
148
  # @@protoc_insertion_point(module_scope)
@@ -59,44 +59,44 @@ class TaskIns(google.protobuf.message.Message):
59
59
  DESCRIPTOR: google.protobuf.descriptor.Descriptor
60
60
  TASK_ID_FIELD_NUMBER: builtins.int
61
61
  GROUP_ID_FIELD_NUMBER: builtins.int
62
- WORKLOAD_ID_FIELD_NUMBER: builtins.int
62
+ RUN_ID_FIELD_NUMBER: builtins.int
63
63
  TASK_FIELD_NUMBER: builtins.int
64
64
  task_id: typing.Text
65
65
  group_id: typing.Text
66
- workload_id: builtins.int
66
+ run_id: builtins.int
67
67
  @property
68
68
  def task(self) -> global___Task: ...
69
69
  def __init__(self,
70
70
  *,
71
71
  task_id: typing.Text = ...,
72
72
  group_id: typing.Text = ...,
73
- workload_id: builtins.int = ...,
73
+ run_id: builtins.int = ...,
74
74
  task: typing.Optional[global___Task] = ...,
75
75
  ) -> None: ...
76
76
  def HasField(self, field_name: typing_extensions.Literal["task",b"task"]) -> builtins.bool: ...
77
- def ClearField(self, field_name: typing_extensions.Literal["group_id",b"group_id","task",b"task","task_id",b"task_id","workload_id",b"workload_id"]) -> None: ...
77
+ def ClearField(self, field_name: typing_extensions.Literal["group_id",b"group_id","run_id",b"run_id","task",b"task","task_id",b"task_id"]) -> None: ...
78
78
  global___TaskIns = TaskIns
79
79
 
80
80
  class TaskRes(google.protobuf.message.Message):
81
81
  DESCRIPTOR: google.protobuf.descriptor.Descriptor
82
82
  TASK_ID_FIELD_NUMBER: builtins.int
83
83
  GROUP_ID_FIELD_NUMBER: builtins.int
84
- WORKLOAD_ID_FIELD_NUMBER: builtins.int
84
+ RUN_ID_FIELD_NUMBER: builtins.int
85
85
  TASK_FIELD_NUMBER: builtins.int
86
86
  task_id: typing.Text
87
87
  group_id: typing.Text
88
- workload_id: builtins.int
88
+ run_id: builtins.int
89
89
  @property
90
90
  def task(self) -> global___Task: ...
91
91
  def __init__(self,
92
92
  *,
93
93
  task_id: typing.Text = ...,
94
94
  group_id: typing.Text = ...,
95
- workload_id: builtins.int = ...,
95
+ run_id: builtins.int = ...,
96
96
  task: typing.Optional[global___Task] = ...,
97
97
  ) -> None: ...
98
98
  def HasField(self, field_name: typing_extensions.Literal["task",b"task"]) -> builtins.bool: ...
99
- def ClearField(self, field_name: typing_extensions.Literal["group_id",b"group_id","task",b"task","task_id",b"task_id","workload_id",b"workload_id"]) -> None: ...
99
+ def ClearField(self, field_name: typing_extensions.Literal["group_id",b"group_id","run_id",b"run_id","task",b"task","task_id",b"task_id"]) -> None: ...
100
100
  global___TaskRes = TaskRes
101
101
 
102
102
  class Value(google.protobuf.message.Message):
@@ -51,7 +51,7 @@ class DriverServicer(driver_pb2_grpc.DriverServicer):
51
51
  """Get available nodes."""
52
52
  log(INFO, "DriverServicer.GetNodes")
53
53
  state: State = self.state_factory.state()
54
- all_ids: Set[int] = state.get_nodes(request.workload_id)
54
+ all_ids: Set[int] = state.get_nodes(request.run_id)
55
55
  nodes: List[Node] = [
56
56
  Node(node_id=node_id, anonymous=False) for node_id in all_ids
57
57
  ]
@@ -63,8 +63,8 @@ class DriverServicer(driver_pb2_grpc.DriverServicer):
63
63
  """Create workload ID."""
64
64
  log(INFO, "DriverServicer.CreateWorkload")
65
65
  state: State = self.state_factory.state()
66
- workload_id = state.create_workload()
67
- return CreateWorkloadResponse(workload_id=workload_id)
66
+ run_id = state.create_workload()
67
+ return CreateWorkloadResponse(run_id=run_id)
68
68
 
69
69
  def PushTaskIns(
70
70
  self, request: PushTaskInsRequest, context: grpc.ServicerContext
@@ -32,7 +32,7 @@ class InMemoryState(State):
32
32
 
33
33
  def __init__(self) -> None:
34
34
  self.node_ids: Set[int] = set()
35
- self.workload_ids: Set[int] = set()
35
+ self.run_ids: Set[int] = set()
36
36
  self.task_ins_store: Dict[UUID, TaskIns] = {}
37
37
  self.task_res_store: Dict[UUID, TaskRes] = {}
38
38
 
@@ -43,9 +43,9 @@ class InMemoryState(State):
43
43
  if any(errors):
44
44
  log(ERROR, errors)
45
45
  return None
46
- # Validate workload_id
47
- if task_ins.workload_id not in self.workload_ids:
48
- log(ERROR, "`workload_id` is invalid")
46
+ # Validate run_id
47
+ if task_ins.run_id not in self.run_ids:
48
+ log(ERROR, "`run_id` is invalid")
49
49
  return None
50
50
 
51
51
  # Create task_id, created_at and ttl
@@ -104,9 +104,9 @@ class InMemoryState(State):
104
104
  log(ERROR, errors)
105
105
  return None
106
106
 
107
- # Validate workload_id
108
- if task_res.workload_id not in self.workload_ids:
109
- log(ERROR, "`workload_id` is invalid")
107
+ # Validate run_id
108
+ if task_res.run_id not in self.run_ids:
109
+ log(ERROR, "`run_id` is invalid")
110
110
  return None
111
111
 
112
112
  # Create task_id, created_at and ttl
@@ -199,25 +199,25 @@ class InMemoryState(State):
199
199
  raise ValueError(f"Node {node_id} not found")
200
200
  self.node_ids.remove(node_id)
201
201
 
202
- def get_nodes(self, workload_id: int) -> Set[int]:
202
+ def get_nodes(self, run_id: int) -> Set[int]:
203
203
  """Return all available client nodes.
204
204
 
205
205
  Constraints
206
206
  -----------
207
- If the provided `workload_id` does not exist or has no matching nodes,
207
+ If the provided `run_id` does not exist or has no matching nodes,
208
208
  an empty `Set` MUST be returned.
209
209
  """
210
- if workload_id not in self.workload_ids:
210
+ if run_id not in self.run_ids:
211
211
  return set()
212
212
  return self.node_ids
213
213
 
214
214
  def create_workload(self) -> int:
215
215
  """Create one workload."""
216
- # Sample a random int64 as workload_id
217
- workload_id: int = int.from_bytes(os.urandom(8), "little", signed=True)
216
+ # Sample a random int64 as run_id
217
+ run_id: int = int.from_bytes(os.urandom(8), "little", signed=True)
218
218
 
219
- if workload_id not in self.workload_ids:
220
- self.workload_ids.add(workload_id)
221
- return workload_id
219
+ if run_id not in self.run_ids:
220
+ self.run_ids.add(run_id)
221
+ return run_id
222
222
  log(ERROR, "Unexpected workload creation failure.")
223
223
  return 0