Imagelab Serializer#
Classes:
- class cleanvision.utils.serialize.Serializer[source]#
Bases:
object
Methods:
serialize
(path, imagelab, force)Serializes the imagelab object to disk.
deserialize
(path)Deserializes the imagelab object from disk.
- classmethod serialize(path, imagelab, force)[source]#
Serializes the imagelab object to disk.
- Parameters:
path (str) – Path to save the imagelab object to.
imagelab (Imagelab) – The imagelab object to save.
force (bool) – If True, will overwrite existing files at the specified path.
- Raises:
FileExistsError – If force is set to False, and an existing path is specified for saving Imagelab instance.
- Return type:
None
- classmethod deserialize(path)[source]#
Deserializes the imagelab object from disk.
- Parameters:
path (str) – Path to the saved Imagelab folder previously specified in
_Serializer.serialize()
(not the individual pickle file).- Return type:
- Raises:
ValueError: – If the path specified for imagelab folder does not exist