DeepDiff: Deep Difference and search of any Python object/data. DeepHash: Hash of any object based on its contents. Delta: Use deltas to reconstruct objects by adding deltas together.
class Image(BaseModel):
size: SizeFormat
extension: ImageFormat
data: bytes
Image object contains the data field, which is a byte string representing the image. When comparing Image lists, an error occurs:
{UnicodeDecodeError}UnicodeDecodeError('utf-8', b'RIFF\x84-\x03\x00WEBPVP8 x-\x03\x00P\xe1\n\x9d\x01\x80\x078\x04>m2\x95H\xa4"\xa4\xa6$\x93\xca\x...x03\x00P\n\x01\x078...'. Please either pass ignore_encoding_errors=True or pass the encoding via encodings=['utf-8', '...'].")
I'm trying to calculate the differences in the following way:
DeepDiff([image1], [image2], ignore_order=True, exclude_regex_paths=r'\[\d+\].data')
But the error does not disappear...
Image object contains the data field, which is a byte string representing the image. When comparing Image lists, an error occurs:
I'm trying to calculate the differences in the following way:
DeepDiff([image1], [image2], ignore_order=True, exclude_regex_paths=r'\[\d+\].data')
But the error does not disappear...