e45fef601195a9cb850e29703015d2a062aa9ea9,src/syft/core/store/storeable_object.py,StorableObject,_object2proto,#StorableObject#,43

Before Change


    def _object2proto(self) -> StorableObject_PB:
        key = self.key.serialize()
        data = self.data.serialize()
        return StorableObject_PB(
            key=key, data=data, description=self.description, tags=self.tags
        )

    @staticmethod
    def _proto2object(proto: StorableObject_PB) -> StorableObject_PB:
        key = _deserialize(proto.key)

After Change


    def _object2proto(self) -> StorableObject_PB:
        key = self.key.serialize()
        data = self.data.serialize()
        proto = StorableObject_PB()
        proto.key.CopyFrom(key)
        proto.schematic_qualname = (
            "syft." + type(data).__module__ + "." + type(data).__name__
        )
        proto.data.Pack(data)
        proto.obj_type = type(self).__module__ + "." + type(self).__name__
        proto.description = self.description
        for tag in self.tags:
            proto.tags.append(tag)
        return proto

    @staticmethod
    @syft_decorator(typechecking=True)
    def _proto2object(proto: StorableObject_PB) -> "StorableObject":
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 6

Instances


Project Name: OpenMined/PySyft
Commit Name: e45fef601195a9cb850e29703015d2a062aa9ea9
Time: 2020-08-05
Author: tudorcebere@gmail.com
File Name: src/syft/core/store/storeable_object.py
Class Name: StorableObject
Method Name: _object2proto


Project Name: OpenMined/PySyft
Commit Name: a35bc3be6bc0643a49bae001967fdeb54992c49a
Time: 2020-08-12
Author: 12518480+vvmnnnkv@users.noreply.github.com
File Name: src/syft/lib/torch/uppercase_tensor.py
Class Name: TorchTensorWrapper
Method Name: _data_object2proto


Project Name: OpenMined/PySyft
Commit Name: e45fef601195a9cb850e29703015d2a062aa9ea9
Time: 2020-08-05
Author: tudorcebere@gmail.com
File Name: src/syft/core/store/storeable_object.py
Class Name: StorableObject
Method Name: _object2proto


Project Name: OpenMined/PySyft
Commit Name: f21d53cfda625c8ffacf314db187d3ecd25255a8
Time: 2021-03-23
Author: me@madhavajay.com
File Name: src/syft/lib/python/slice.py
Class Name: Slice
Method Name: _object2proto