Function - deconstruct_model_proto#
- openfl.protocols.utils.deconstruct_model_proto(model_proto, compression_pipeline, keys_only=False)[source]#
Deconstruct model proto.
This function takes a model protobuf and a compression pipeline, and deconstructs the protobuf into a dictionary of tensors and a round number.
- Parameters:
model_proto – The protobuf of the model.
compression_pipeline – The compression pipeline for the model.
keys_only – Boolean to not return the output of the compression pipeline
- Returns:
A dictionary where the keys are tensor names and the values are the corresponding tensors. round_number: The round number for the model.
- Return type:
tensor_dict