-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdownlaod_dataset.sh
executable file
·62 lines (55 loc) · 1.58 KB
/
downlaod_dataset.sh
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
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
#!/bin/bash
echo "creating the folder ~/kaggale for testing the APi "
#after installing kaggale APi packages automatically will be created
#folder into local directroy
#/home/<username>/.kaggle
path_api="/home/yunus/.kaggle"
#creat APi kaggale account from kaggale
api="kaggle.json"
#run commaned to download the datatset from kaggale
cmd="kaggle datasets download -d awsaf49/brats20-dataset-training-validation"
mkcd()
{
#make file executable
cd ..
python create_env.py Unet
source Unet/bin/activate
cd processing
if [-f kaggle.json];then
chmod 600 $api
else
echo "Ops the file kaggale does not exist ${/n}make you have API kaggale account"
fi
#move file into locale directory
mv $api $path_api
$cmd
#unzip the file in project directory
unzip brats20-dataset-training-validation.zip
}
mkcd
echo ".... Stage 2 setup the Biomedical packges"
mkcd()
{
cd ..
if [-e requirements.txt]
then pip install -r requirements.txt
else echo "something goes wrong make sure the file executable"
cd processing
echo " make this take well to finish be patient"
python fslinstaller.py
echo "-----------finished ------------------"
echo "-----------stage 3 setup the variable environment"
<<'COMMENTS'
# Change the value for FSLDIR if you have
# installed FSL into a different location
FSLDIR=/usr/local/fsl
. ${FSLDIR}/etc/fslconf/fsl.sh
PATH=${FSLDIR}/bin:${PATH}
export FSLDIR PATH
# My custom values for FSL environment variables
export FSLOUTPUTTYPE=NIFTI
COMMENTS
echo $FSLDIR
echo "done"
}
mkcd