concepts.benchmark.clevr.dataset.make_custom_transfer_dataset#
- make_custom_transfer_dataset(scenes_json, questions_json, image_root, query_list_key, custom_fields, *, image_transform=None, output_vocab_json=None, **kwargs)[source]#
Make a CLEVR custom transfer dataset. See
CLEVRCustomTransferDataset
for more details.- Parameters:
scenes_json (str) – the path to the scenes json file.
questions_json (str) – the path to the questions json file.
image_root (str) – the root directory of the images.
query_list_key (str) – the key of the query list in the questions json file (e.g., ‘questions’ or ‘questions_human’).
custom_fields (Sequence[str]) – the custom fields to be included in the dataset. These are fields in the scene annotations.
image_transform – the image transform (torchvision transform). If None, a default transform will be used.
output_vocab_json – the path to the output vocab json file. If None, the output vocab will be built from the dataset.
**kwargs – other keyword arguments for the dataset.
- Returns:
a CLEVR custom transfer dataset.
- Return type: