Download Zindi's compositions datasets directly to google colab
Zindi is Zindi is a social enterprise whose mission is to build the data science ecosystem in Africa. Our vision is for a vibrant community of data scientists across Africa, mobilized towards solving the region’s most pressing problems.
we need to get the URL and the authentication value
- joining the competition
- Right click in the page + Inspect
- click the top left icon or (Ctrl + shift +c)
- then click on the dataset name (training for example ) you will see that the right page will show the Web script which contain the URL of the dataset and the authentication value
- copy them and use the python script in colab to download them directly
import requests
import requests, zipfile
#the url and auth_value from the website
url = 'https://api.zindi.africa/v1/competitions/iclr-workshop-challenge-1-cgiar-computer-vision-for-crop-disease/files/train.zip'
myobj = {'auth_token': 'sfffghgghgvkhuf'} #use your own
x = requests.post(url, data = myobj,stream=True)
target_path = 'data.zip'
handle = open(target_path, "wb")
for chunk in x.iter_content(chunk_size=512):
if chunk: # filter out keep-alive new chunks
handle.write(chunk)
handle.close()
!unzip -qq /content/data.zip