1
1
# ------------------------------------------------------------------------------
2
- # TEST CRISPRme conda package
2
+ # TEST CRISPRme Docker
3
3
4
4
echo " Download and extract fundamental data..."
5
5
40
40
while true ; do # retry download if caught timeout
41
41
wget -T 15 -c ftp://ftp.1000genomes.ebi.ac.uk/vol1/ftp/data_collections/1000_genomes_project/release/20190312_biallelic_SNV_and_INDEL/ALL.chr${i} .shapeit2_integrated_snvindels_v2a_27022019.GRCh38.phased.vcf.gz && break
42
42
done
43
+ sleep 2 # allow disk sync for md5sum check
43
44
local_md5sum=" $( md5sum ALL.chr${i} .shapeit2_integrated_snvindels_v2a_27022019.GRCh38.phased.vcf.gz | cut -d ' ' -f 1) "
44
45
if [ " $original_md5sum " != " $local_md5sum " ]; then # check download consistency
45
46
echo " ERROR: unexpected failure while downloading ALL.chr${i} .shapeit2_integrated_snvindels_v2a_27022019.GRCh38.phased.vcf.gz"
@@ -59,7 +60,16 @@ cd $SAMPLESIDS
59
60
# download 1000G samples IDs
60
61
echo " Downloading samples ids for 1000G dataset"
61
62
SAMPLES1000G=" hg38_1000G.samplesID.txt"
62
- wget https://raw.githubusercontent.com/pinellolab/CRISPRme/refs/heads/gnomad-4.1-converter/download_data/${SAMPLES1000G}
63
+ original_md5sum=" $( curl -sL https://raw.githubusercontent.com/pinellolab/CRISPRme/refs/heads/gnomad-4.1-converter/download_data/${SAMPLES1000G} | md5sum | cut -d ' ' -f 1) " # compute original md5sum
64
+ while true ; do # retry download if caught timeout
65
+ wget -T 15 -c https://raw.githubusercontent.com/pinellolab/CRISPRme/refs/heads/gnomad-4.1-converter/download_data/${SAMPLES1000G} && break
66
+ done
67
+ sleep 2 # allow disk sync for md5sum check
68
+ local_md5sum=" $( md5sum $SAMPLES1000G | cut -d ' ' -f 1) "
69
+ if [ " $original_md5sum " != " $local_md5sum " ]; then
70
+ echo " ERROR: unexpected failure while downloading ${SAMPLES1000G} "
71
+ exit 1
72
+ fi
63
73
cd ..
64
74
65
75
# initialize samples config file
@@ -72,31 +82,33 @@ mkdir -p $ANNOTATIONDIR # create annotation folder
72
82
cd $ANNOTATIONDIR
73
83
echo " Downloading ENCODE+GENCODE annotation data..."
74
84
original_md5sum=" $( curl -sL https://raw.githubusercontent.com/pinellolab/CRISPRme/gnomad-4.1-converter/download_data/dhs+encode+gencode.hg38.bed.tar.gz | md5sum | cut -d ' ' -f 1) "
75
- encodegencode =" dhs+encode+gencode.hg38.bed.zip"
85
+ DHSENCODE =" dhs+encode+gencode.hg38.bed.zip"
76
86
while true ; do # retry download if caught timeout
77
- wget -T 15 -c -O $encodegencode https://raw.githubusercontent.com/pinellolab/CRISPRme/gnomad-4.1-converter/download_data/dhs+encode+gencode.hg38.bed.tar.gz && break
87
+ wget -T 15 -c -O $DHSENCODE https://raw.githubusercontent.com/pinellolab/CRISPRme/gnomad-4.1-converter/download_data/dhs+encode+gencode.hg38.bed.tar.gz && break
78
88
done
79
- local_md5sum=" $( md5sum $encodegencode | cut -d ' ' -f 1) "
89
+ sleep 2 # allow disk sync for md5sum check
90
+ local_md5sum=" $( md5sum $DHSENCODE | cut -d ' ' -f 1) "
80
91
if [ " $original_md5sum " != " $local_md5sum " ]; then
81
- echo " ERROR: unexpected failure while downloading ${encodegencode } "
92
+ echo " ERROR: unexpected failure while downloading ${DHSENCODE } "
82
93
exit 1
83
94
fi
84
- echo " Extracting ${encodegencode } ..."
85
- tar -xvf $encodegencode
95
+ echo " Extracting ${DHSENCODE } ..."
96
+ tar -xvf $DHSENCODE
86
97
87
98
echo " Downloading GENCODE encoding sequences..."
88
- original_md5sum=" $( curl -sL https://raw.githubusercontent.com/pinellolab/CRISPRme/gnomad-4.1-converter/download_data/dhs+encode+ gencode.hg38 .bed.tar.gz | md5sum | cut -d ' ' -f 1) "
89
- gencode =" gencode.protein_coding.bed.zip"
99
+ original_md5sum=" $( curl -sL https://raw.githubusercontent.com/pinellolab/CRISPRme/gnomad-4.1-converter/download_data/gencode.protein_coding .bed.tar.gz | md5sum | cut -d ' ' -f 1) "
100
+ GENCODE =" gencode.protein_coding.bed.zip"
90
101
while true ; do # retry download if caught timeout
91
- wget -T 15 -c -O $gencode https://raw.githubusercontent.com/pinellolab/CRISPRme/gnomad-4.1-converter/download_data/gencode.protein_coding.bed.tar.gz && break
102
+ wget -T 15 -c -O $GENCODE https://raw.githubusercontent.com/pinellolab/CRISPRme/gnomad-4.1-converter/download_data/gencode.protein_coding.bed.tar.gz && break
92
103
done
93
- local_md5sum=" $( md5sum $gencode | cut -d ' ' -f 1) "
104
+ sleep 2 # allow disk sync for md5sum check
105
+ local_md5sum=" $( md5sum $GENCODE | cut -d ' ' -f 1) "
94
106
if [ " $original_md5sum " != " $local_md5sum " ]; then
95
- echo " ERROR: unexpected failure while downloading ${gencode } "
107
+ echo " ERROR: unexpected failure while downloading ${GENCODE } "
96
108
exit 1
97
109
fi
98
- echo " Extracting ${gencode } ..."
99
- tar -xvf $gencode
110
+ echo " Extracting ${GENCODE } ..."
111
+ tar -xvf $GENCODE
100
112
cd ..
101
113
102
114
# create Dictionaries folder
@@ -115,4 +127,4 @@ printf "NNNNNNNNNNNNNNNNNNNNNGG 3\n" > $NGGPAM
115
127
cd ..
116
128
117
129
echo " Start CRISPRme test..."
118
- docker run -v ${PWD} :/DATA -w /DATA -i pinellolab/crisprme crisprme.py complete-search --genome Genomes/hg38/ --vcf $VCFCONFIG --guide $GUIDEFILE --pam PAMs/$NGGPAM --annotation Annotations/$encodegencode --samplesID $SAMPLESCONFIG --gene_annotation Annotations/$gencode --mm 6 --bDNA 2 --bRNA 2 --merge 3 --output sg1617.6.2.2 --thread 4
130
+ docker run -v ${PWD} :/DATA -w /DATA -i pinellolab/crisprme crisprme.py complete-search --genome Genomes/$HG38 --vcf $VCFCONFIG --guide $GUIDEFILE --pam PAMs/$NGGPAM --annotation Annotations/$DHSENCODE --samplesID $SAMPLESCONFIG --gene_annotation Annotations/$GENCODE --sorting-criteria-scoring mm+bulges --sorting-criteria mm,bulges --mm 6 --bDNA 2 --bRNA 2 --merge 3 --output sg1617.6.2.2 --thread 4
0 commit comments