File size: 932 Bytes
31dc8dc
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37


laion_root="allava_laion"

mkdir $laion_root
cd $laion_root


# 1. download annotation files
## 1.1 caption
wget -c -O ALLaVA-Caption-LAION-4V.json https://huggingface.co/datasets/FreedomIntelligence/ALLaVA-4V/resolve/main/allava_laion/ALLaVA-Caption-LAION-4V.json?download=true

## 1.2 instruction
wget -c -O ALLaVA-Instruct-LAION-4V.json https://huggingface.co/datasets/FreedomIntelligence/ALLaVA-4V/resolve/main/allava_laion/ALLaVA-Instruct-LAION-4V.json?download=true


# 2. download and upzip images
mkdir image_chunks

## 2.1 download
for ((i=0; i<10; i++))
do
    wget -c -O image_chunks/images_$i.zip https://huggingface.co/datasets/FreedomIntelligence/ALLaVA-4V/resolve/main/allava_laion/image_chunks/images_$i.zip?download=true &
done

mkdir -p images/
wait

## 2.2 unzip
for ((i=0; i<10; i++))
do
    unzip -j -o image_chunks/images_$i.zip -d images/ & # wait patiently, it takes a while...
done

wait
echo "All done!"