@amapic in the sample submission from starter kit you can find:
AICROWD_TEST_IMAGES_PATH = os.getenv("AICROWD_TEST_IMAGES_PATH", "./data/test_images_small/") AICROWD_TEST_METADATA_PATH = os.getenv("AICROWD_TEST_METADATA_PATH", "./data/test_metadata_small.csv") AICROWD_PREDICTIONS_OUTPUT_PATH = os.getenv("AICROWD_PREDICTIONS_OUTPUT_PATH", "random_prediction.csv")
as @ValAn told you, it’s better if you don’t change the defaults. But if you still need to change, make sure to just change the second parameter from the call to os.getenv.
This is because when you submit your code aicrowd expects you to “read” those paths from environment variables they’ve set.
For you to test that it works on your local machine it should be enough with the default values and uncompressing both
test_images_small.tar.gz in the
data folder. You can download both of those files in the resources page
As for dealing with corrupt files you can see how @gokuleloop did it for round 2 @ https://github.com/GokulEpiphany/contests-final-code/blob/master/aicrowd-snake-species/inference/run.py#L196
Disclaimer: It’s impossible to use his same idea, due to now we don’t have a sample submission .csv file, but you can get an idea of how to deal with those.
Personally what I do is simply generate a “fake” random image, but I guess there are better ways (more efficient / scoring higher) my pseudocode would be like:
try : image = read(file) except : image = random
Final tip: Be sure to add a line with a corrupt / non-existent image file to the test_metadata_small.csv mentioned earlier, so you can also be sure your code can handle errors when reading the images.
Best of luck!