-
Notifications
You must be signed in to change notification settings - Fork 0
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add flwr proto status #7
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The translation from struct Code
to Flwr_Proto_Code
e.g. in propertiesToProto, fitResToProto, evaluateResToProto, parametersToProto, should be implemented in Serde.swift.
Naming changes in Typing.swift and Serde.swift, analog to changes in transport.pb file: e.g Properties
and 'PropertiesRes' to GetPropertiesIns
and GetPropertiesRes
, Parameters
and 'ParametersRes' to GetParametersIns
and GetParametersRes
.
The Client
protocol extension should be modified, since we are not using getProperties
right now, it should contain an getPropertiesNotImplemented code in its returned object. Optional message in string would be "Client does not implement get_properties
"
Status Code ok with optional message "Success" should be implemented in the example project.
|
||
public init(parameters: Parameters) { | ||
self.parameters = parameters | ||
self.status = Status(code: .ok, message: String()) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The status should be left as a parameter
public init(status: Status, parameters: Parameters)
|
||
public init(parameters: Parameters, numExamples: Int, metrics: Metrics? = nil) { | ||
self.parameters = parameters | ||
self.numExamples = numExamples | ||
self.metrics = metrics | ||
self.status = Status(code: .ok, message: String()) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The status should be left as a parameter
public init(status: Status, parameters: Parameters, numExamples: Int, metrics: Metrics? = nil)
Protobuf to own struct and vice versa
According to the
transport.pb
template theStatus
struct was added to the code.