How FCLIPDataset works
masterThe FCLIPDataset class encapsulates catalog information and provides helper functions for data exploration and visualization. It is used to manage the relationship between images and their metadata (captions/IDs).
Initialization Parameters:
name(str): Name of the dataset.image_source_path(str): Absolute path to images (supports local or S3).image_source_type(str): Type of source (localors3).catalog(List[dict], optional): List of dictionaries containing at minimum the keys['id', 'image', 'caption'].
from fashion_clip import FCLIPDataset
# Using a pre-included dataset
dataset = FCLIPDataset(name='FF',
image_source_path='path/to/images',
image_source_type='local')
# Using a custom dataset
my_catalog = [{'id': 1, 'image': 'x.jpg', 'caption': 'image x'}]
dataset = FCLIPDataset(name='my_dataset',
image_source_path='path/to/images',
image_source_type='local',
catalog=my_catalog)