dry-ability-69144
02/07/2023, 1:44 PMdry-ability-69144
02/07/2023, 6:00 PMbroad-monitor-993
02/07/2023, 7:04 PMdry-ability-69144
02/07/2023, 7:06 PMbroad-monitor-993
02/07/2023, 7:08 PMbroad-monitor-993
02/07/2023, 7:10 PMbroad-monitor-993
02/07/2023, 7:10 PMdry-ability-69144
02/07/2023, 7:13 PMbroad-monitor-993
02/07/2023, 7:25 PMpip insatll gsutil
and flyte handles serialization/deserialization of data structures (including files and images) to and from the blob store.
what kind of metadata do you want to attach to the images?dry-ability-69144
02/07/2023, 7:27 PMbroad-monitor-993
02/07/2023, 7:31 PMdataclasses
to attach metadata to files (see custom python objects in docs):
from dataclasses import dataclass
from dataclasses_json import dataclass_json
from flytekit.types.file import PNGImageFile
@dataclass_json
@dataclass
class ImageWithMetadata:
"""
Example of a simple custom class that is modeled as a dataclass
"""
file: PNGImageFile
metadata: typing.Dict[str, str]
broad-monitor-993
02/07/2023, 7:32 PMImageWithMetadata
will behave like a regular dataclass, but Flyte will automatically handle writing to/reading from blobstore when it’s used in tasks and workflowsdry-ability-69144
02/07/2023, 7:43 PMbroad-monitor-993
02/07/2023, 7:57 PM