#!/usr/bin/env python """Build the training shards from images + captions. See docs/data_format.md. python scripts/prepare_data.py --images ./my_images --out ./data python scripts/prepare_data.py --captions-file pairs.jsonl --out ./data python scripts/prepare_data.py --hf-dataset / --image-column image --caption-column caption --out ./data """ import os import sys try: from dwd_klein.prepare import main except ImportError: # running from a source checkout without installing the package sys.path.insert(0, os.path.join(os.path.dirname(os.path.abspath(__file__)), "..", "src")) from dwd_klein.prepare import main if __name__ == "__main__": sys.exit(main())