open_clip icon indicating copy to clipboard operation
open_clip copied to clipboard

key error

Open ntz2000 opened this issue 1 year ago • 1 comments

use "python -m training.main --save-frequency 1 --zeroshot-frequency 1 --report-to tensorboard --train-data="test.csv" --csv-img-key filepath --csv-caption-key title --warmup 10000 --batch-size=128 --lr=1e-3 --wd=0.1 --epochs=30 --workers=1 --model RN50"

And the test.csv file has the same col but :

raise KeyError(key) from err KeyError: 'filepath'

ntz2000 avatar Jan 10 '24 20:01 ntz2000

Hi @ntz2000, It seems like the issue might be related to the CSV separator used in your command. The default separator for the --csv-separator option is set to '\t' (tab-separated). If your test.csv file uses a different separator, such as a comma or a semicolon, you need to specify this in your command.

Try adding the --csv-separator flag with the appropriate separator. For example, if your CSV file is comma-separated, modify your command to include --csv-separator ','. Make sure to match the separator with the actual format of your test.csv file.

StefanDenn3r avatar Jan 29 '24 16:01 StefanDenn3r