-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathSingularity
750 lines (622 loc) · 17.7 KB
/
Singularity
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
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
Bootstrap: docker
From: centos:8
Stage: build
%setup
%files
%help
Bionformatics tools.
Complete list of installed tools:
- Samtools
- BEDTools
- FastQC
- Bowtie2
- MultiQC
- Cutadapt
- STAR
- Hisat2
- Picard
- Trimmomatic
- Samblaster
- VarScan
- Vcfanno
- Plink
- MACS2
- Homer
- NextFlow
- nf-core
- MAGeCK
- TrimGalore
- Bismark
- Subread
- UCSC tools:
- addCols
- ameme
- autoDtd
- autoSql
- autoXml
- ave
- aveCols
- axtChain
- axtSort
- axtSwap
- axtToMaf
- axtToPsl
- bamToPsl
- bedClip
- bedCommonRegions
- bedCoverage
- bedExtendRanges
- bedGeneParts
- bedGraphPack
- bedGraphToBigWig
- bedIntersect
- bedItemOverlapCount
- bedJoinTabOffset
- bedJoinTabOffset.py
- bedMergeAdjacent
- bedPartition
- bedPileUps
- bedRemoveOverlap
- bedRestrictToPositions
- bedSort
- bedToBigBed
- bedToExons
- bedToGenePred
- bedToPsl
- bedWeedOverlapping
- bigBedInfo
- bigBedNamedItems
- bigBedSummary
- bigBedToBed
- bigMafToMaf
- bigPslToPsl
- bigWigAverageOverBed
- bigWigCat
- bigWigCluster
- bigWigCorrelate
- bigWigInfo
- bigWigMerge
- bigWigSummary
- bigWigToBedGraph
- bigWigToWig
- binFromRange
- blastToPsl
- blastXmlToPsl
- blat
- calc
- catDir
- catUncomment
- chainAntiRepeat
- chainBridge
- chainFilter
- chainMergeSort
- chainNet
- chainPreNet
- chainSort
- chainSplit
- chainStitchId
- chainSwap
- chainToAxt
- chainToPsl
- chainToPslBasic
- checkAgpAndFa
- checkCoverageGaps
- checkHgFindSpec
- checkTableCoords
- chopFaLines
- chromGraphFromBin
- chromGraphToBin
- clusterGenes
- colTransform
- countChars
- cpg_lh
- crTreeIndexBed
- crTreeSearchBed
- dbSnoop
- dbTrash
- endsInLf
- estOrient
- expMatrixToBarchartBed
- faAlign
- faCmp
- faCount
- faFilter
- faFilterN
- faFrag
- faNoise
- faOneRecord
- faPolyASizes
- faRandomize
- faRc
- faSize
- faSomeRecords
- faSplit
- faToFastq
- faToTab
- faToTwoBit
- faTrans
- fastqStatsAndSubsample
- fastqToFa
- featureBits
- fetchChromSizes
- findMotif
- fixStepToBedGraph.pl
- gapToLift
- genePredCheck
- genePredFilter
- genePredHisto
- genePredSingleCover
- genePredToBed
- genePredToBigGenePred
- genePredToFakePsl
- genePredToGtf
- genePredToMafFrames
- genePredToProt
- gensub2
- getRna
- getRnaPred
- gfClient
- gfServer
- gff3ToGenePred
- gff3ToPsl
- gmtime
- gtfToGenePred
- headRest
- hgBbiDbLink
- hgFakeAgp
- hgFindSpec
- hgGcPercent
- hgGoldGapGl
- hgLoadBed
- hgLoadChain
- hgLoadGap
- hgLoadMaf
- hgLoadMafSummary
- hgLoadNet
- hgLoadOut
- hgLoadOutJoined
- hgLoadSqlTab
- hgLoadWiggle
- hgSpeciesRna
- hgTrackDb
- hgWiggle
- hgsqldump
- hgvsToVcf
- hicInfo
- htmlCheck
- hubCheck
- hubClone
- hubPublicCheck
- ixIxx
- lavToAxt
- lavToPsl
- ldHgGene
- liftOver
- liftOverMerge
- liftUp
- linesToRa
- localtime
- mafAddIRows
- mafAddQRows
- mafCoverage
- mafFetch
- mafFilter
- mafFrag
- mafFrags
- mafGene
- mafMeFirst
- mafNoAlign
- mafOrder
- mafRanges
- mafSpeciesList
- mafSpeciesSubset
- mafSplit
- mafSplitPos
- mafToAxt
- mafToBigMaf
- mafToPsl
- mafToSnpBed
- mafsInRegion
- makeTableList
- maskOutFa
- mktime
- mrnaToGene
- netChainSubset
- netClass
- netFilter
- netSplit
- netSyntenic
- netToAxt
- netToBed
- newProg
- newPythonProg
- nibFrag
- nibSize
- oligoMatch
- overlapSelect
- para
- paraFetch
- paraHub
- paraHubStop
- paraNode
- paraNodeStart
- paraNodeStatus
- paraNodeStop
- paraSync
- paraTestJob
- parasol
- positionalTblCheck
- pslCDnaFilter
- pslCat
- pslCheck
- pslDropOverlap
- pslFilter
- pslHisto
- pslLiftSubrangeBlat
- pslMap
- pslMapPostChain
- pslMrnaCover
- pslPairs
- pslPartition
- pslPosTarget
- pslPretty
- pslRc
- pslRecalcMatch
- pslReps
- pslScore
- pslSelect
- pslSomeRecords
- pslSort
- pslStats
- pslSwap
- pslToBed
- pslToBigPsl
- pslToChain
- pslToPslx
- pslxToFa
- qaToQac
- qacAgpLift
- qacToQa
- qacToWig
- raSqlQuery
- raToLines
- raToTab
- randomLines
- rmFaDups
- rowsToCols
- sizeof
- spacedToTab
- splitFile
- splitFileByColumn
- sqlToXml
- strexCalc
- stringify
- subChar
- subColumn
- tailLines
- tdbQuery
- tdbRename
- tdbSort
- textHistogram
- tickToDate
- toLower
- toUpper
- transMapPslToGenePred
- trfBig
- twoBitDup
- twoBitInfo
- twoBitMask
- twoBitToFa
- ucscApiClient
- vai.pl
- validateFiles
- validateManifest
- varStepToBedGraph.pl
- webSync
- wigCorrelate
- wigEncode
- wigToBigWig
- wordLine
- xmlCat
- xmlToSql
## END HELP
%post
NOW=`date`
echo "export NOW=\"${NOW}\"" >> $SINGULARITY_ENVIRONMENT
set -e
dnf -y makecache
dnf -y group install "Development Tools"
dnf -y install --allowerasing hostname which dnf-utils \
python3-pip git zlib zlib-devel bzip2 bzip2-devel \
xz xz-devel libcurl libcurl-devel ncurses ncurses-devel \
unzip wget gnuplot rsync java-1.8.0-openjdk java-1.8.0-openjdk-devel \
openssl-devel libffi-devel python36-devel
ln -s /usr/bin/python3 /usr/bin/python
ln -s /usr/bin/pip3 /usr/bin/pip
pip install numpy pandas matplotlib scikit-learn scipy opencv-contrib-python
# Intel Threading Building Blocks 2019 U8
echo "/usr/local/lib" >> /etc/ld.so.conf.d/usr_local_lib.conf
rm -rf tbb
git clone https://github.com/intel/tbb
cd tbb
make -j 8
find . -name '*so' | grep release | xargs -I{} cp {} /usr/local/lib/ # Copy release libs to sys dir
find . -name '*so.2' | grep release | xargs -I{} cp {} /usr/local/lib/
cp -R include/* /usr/local/include/
cd ..
ldconfig
mkdir -p /usr/local/lib64/python3.6/site-packages
%runscript
echo "Container was created $NOW"
echo "Arguments received: $*"
exec echo "$@"
%labels
Author "[email protected] and [email protected]"
Version 0.29
%environment
# GLOBAL=variables
# AVAILABLE="to all apps"
export PATH=$PATH:/usr/bin:/usr/local/bin/homer/bin:/opt/ucsc_tools:/opt/Bismark-0.22.3
LANG="en_US.UTF-8"
export LANG
PYTHONWARNINGS=ignore::yaml.YAMLLoadWarning
# ################### Samtools #################################
%apprun samtools
exec samtools
%appinstall samtools
rm -rf htslib
git clone https://github.com/samtools/htslib
cd htslib
autoheader
autoconf
./configure
make -j 8
make install
cd ..
rm -rf samtools
git clone https://github.com/samtools/samtools
cd samtools
autoheader
autoconf -Wno-syntax
./configure
make -j 8
make install
cd ..
%apphelp samtools
Samtools 1.9. https://github.com/samtools/samtools
# ######################## Bedtools ###################################
%apprun bedtools
exec bedtools
%appinstall bedtools
rm -rf bedtools2
git clone https://github.com/arq5x/bedtools2/
#wget https://github.com/arq5x/bedtools2/releases/download/v2.28.0/
#bedtools-2.28.0.tar.gz
#tar -zxf bedtools-2.28.0.tar.gz
cd bedtools2
make -j 8
cp bin/* /usr/local/bin/
%apphelp bedtools
Bedtools 2.28.0. https://github.com/arq5x/bedtools2/
# ######################## FastQC ###################################
%apprun fastqc
exec fastqc
%appinstall fastqc
#git clone https://github.com/s-andrews/FastQC
cd /usr/local/bin
wget http://www.bioinformatics.babraham.ac.uk/projects/fastqc/fastqc_v0.11.8.zip
unzip -o fastqc_v0.11.8.zip
chmod +x FastQC/fastqc
ln -sf FastQC/fastqc .
rm fastqc_v0.11.8.zip
%apphelp fastqc
FastQC v0.11.8. https://github.com/s-andrews/FastQC
# ######################## Bowtie2 ################################
%apprun bowtie2
exec bowtie2
%appinstall bowtie2
wget -O bowtie.zip https://sourceforge.net/projects/bowtie-bio/files/bowtie2/2.3.5.1/bowtie2-2.3.5.1-source.zip/download
unzip -o bowtie.zip
cd bowtie2-2.3.5.1
make -j 8
cp bowtie2* /usr/local/bin/
cd ..
%apphelp bowtie2
Bowtie 2 v. 2.3.5.1 . http://bowtie-bio.sourceforge.net/bowtie2/index.shtml
# ######################## MultiQC ##################################
%apprun multiqc
exec multiqc
%appinstall multiqc
pip install git+https://github.com/ewels/MultiQC.git
%apphelp multiqc
MultiQC v1.8dev. https://multiqc.info/
# ######################## Cutadapt ################################
%apprun cutadapt
exec cutadapt
%appinstall cutadapt
pip install cutadapt
%apphelp cutadapt
Cutadapt 2.4.. https://cutadapt.readthedocs.io/en/stable/guide.html
# ######################### STAR ###################################
%apprun star
exec star
%appinstall star
rm -rf STAR
git clone https://github.com/alexdobin/STAR.git
cd STAR/source
make -j 8 STAR
cp STAR /usr/local/bin/
ln -sf /usr/local/bin/STAR /usr/local/bin/star
cd ..
cd ..
%apphelp star
STAR 2.7.1a. https://github.com/alexdobin/STAR
# ######################## HISAT2 #################################
%apprun hisat2
exec hisat2
%appinstall hisat2
rm -rf hisat2-2.1.0
wget http://ccb.jhu.edu/software/hisat2/dl/hisat2-2.1.0-source.zip
unzip hisat2-2.1.0-source.zip
cd hisat2-2.1.0
make -j 8
#find . -name '*py' | xargs -I{} cp {} /usr/local/bin/
find . -executable -type f | grep -v tinythread | xargs -I{} cp {} /usr/local/bin/
cd ..
%apphelp hisat2
HISAT2 2.1.0. https://ccb.jhu.edu/software/hisat2/index.shtml
# ######################## Picard #########################
%apprun picard
exec picard
%appinstall picard
wget https://github.com/broadinstitute/picard/releases/download/2.20.5/picard.jar
mv picard.jar /usr/local/bin
echo "#"'!'"/usr/bin/bash" > /usr/local/bin/picard
echo "java -jar /usr/local/bin/picard.jar \"\$@\"" >> /usr/local/bin/picard
chmod +x /usr/local/bin/picard
%apphelp picard
Picard 2.20.5. http://broadinstitute.github.io/picard/
# ######################### Trimmomatic #######################
%apprun trimmomatic
exec trimmomatic
%appinstall trimmomatic
wget http://www.usadellab.org/cms/uploads/supplementary/Trimmomatic/Trimmomatic-0.39.zip
unzip -o Trimmomatic-0.39.zip -d /usr/local/bin
echo "#"'!'"/usr/bin/bash" > /usr/local/bin/trimmomatic
echo "java -jar /usr/local/bin/Trimmomatic-0.39/trimmomatic-0.39.jar \"\$@\"" >> /usr/local/bin/trimmomatic
chmod +x /usr/local/bin/trimmomatic
rm Trimmomatic-0.39.zip
%apphelp trimmomatic
Trimmomatic 0.39. http://www.usadellab.org/cms/?page=trimmomatic
# ######################### Samblaster ############################
%apprun samblaster
exec samblaster
%appinstall samblaster
git clone git://github.com/GregoryFaust/samblaster.git
cd samblaster
make -j 8
cp samblaster /usr/local/bin/
cd ..
rm -r samblaster
%apphelp samblaster
Samblaster 0.1.24 . https://github.com/GregoryFaust/samblaster
# ########################## VarScan #################################
%apprun varscan
exec varscan
%appinstall varscan
wget https://github.com/dkoboldt/varscan/raw/master/VarScan.v2.4.4.jar
mv VarScan.v2.4.4.jar /usr/local/bin/
echo "#"'!'"/usr/bin/bash" > /usr/local/bin/varscan
echo "java -jar /usr/local/bin/VarScan.v2.4.4.jar \"\$@\"" >> /usr/local/bin/varscan
chmod +x /usr/local/bin/varscan
%apphelp varscan
VarScan 2.4.4 . https://github.com/dkoboldt/varscan
# ########################### VcfAnno ###############################
%apprun vcfanno
exec vcfanno
%appinstall vcfanno
wget https://github.com/brentp/vcfanno/releases/download/v0.3.2/vcfanno_linux64 -O /usr/local/bin/vcfanno
chmod +x /usr/local/bin/vcfanno
%apphelp vcfanno
VcfAnno 0.3.2 . https://github.com/brentp/vcfanno/releases/
# ############################ Plink ##################################
%apprun plink
exec plink
%appinstall plink
wget http://s3.amazonaws.com/plink1-assets/plink_linux_x86_64_20190617.zip
unzip plink_linux_x86_64_20190617.zip
mv plink /usr/local/bin/
mv prettify /usr/local/bin/
%apphelp plink
PLINK v1.90b6.10 64-bit (17 Jun 2019) . https://www.cog-genomics.org/plink2
# ############################ MACS2 ######################################
%apprun macs2
exec macs2
%appinstall macs2
export PYTHONPATH=$PYTHONPATH:/usr/local/lib64/python3.6/site-packages/
git clone https://github.com/taoliu/MACS.git
cd MACS/
python setup.py install --prefix /usr/local
cd ..
rm -r MACS
%apphelp macs2
MACS2 2.2.4 ( Oct 7 2019) . https://github.com/taoliu/MACS
# ############################ Homer ########################
%apprun homer
exec homer
%appinstall homer
mkdir -p /usr/local/bin/homer
cd /usr/local/bin/homer
wget http://homer.ucsd.edu/homer/configureHomer.pl
perl configureHomer.pl -install
%apphelp homer
Homer 4.10 ( Oct 7 2019 ) . http://homer.ucsd.edu/homer/
# ############################ Nextflow #######################
%apprun nextflow
exec nextflow
%appinstall nextflow
cd /usr/local/bin
curl -s https://get.nextflow.io | bash
chmod 777 /usr/local/bin/nextflow
%apphelp nextflow
Nextflow 19.09 ( Oct 7 2019 ) . https://www.nextflow.io/index.html
# ############################ nf-core ########################
%apprun nfcore
exec nf-core
%appinstall nfcore
LANG="en_US.UTF-8"
export LANG
pip install --upgrade --force-reinstall git+https://github.com/nf-core/tools.git
%apphelp nfcore
Nf-Core . https://nf-co.re/ . A community effort to collect a curated set of analysis pipelines built using Nextflow.
# ############################ MAGeCK ########################
%apprun mageck
exec mageck
%appinstall mageck
wget "https://downloads.sourceforge.net/project/mageck/0.5/liulab-mageck-0.5.9.2.tar.gz"
tar zxvf liulab-mageck-0.5.9.2.tar.gz
cd liulab-mageck-ef7c39474ed0
python setup.py install
cd ..
rm -r liulab-mageck-ef7c39474ed0
%apphelp mageck
MAGeCK (0.5.9.2) enables robust identification of essential genes from genome-scale CRISPR/Cas9 knockout screens
# ############################ TrimGalore ########################
%apprun trim_galore
exec trim_galore
%appinstall trim_galore
curl -fsSL https://github.com/FelixKrueger/TrimGalore/archive/0.6.5.tar.gz -o trim_galore.tar.gz
tar xzf trim_galore.tar.gz
cp TrimGalore-0.6.5/trim_galore /usr/local/bin
rm -r TrimGalore-0.6.5
%apphelp trim_galore
TrimGalore (0.6.5) . https://github.com/FelixKrueger/TrimGalore
# ############################ Bismark ########################
%apprun bismark
exec bismark
%appinstall bismark
curl -fsSL https://github.com/FelixKrueger/Bismark/archive/0.22.3.tar.gz -o Bismark_0.22.3.tar.gz
tar xzf Bismark_0.22.3.tar.gz -C /opt/
%apphelp bismark
Bismark (0.22.3) . https://github.com/FelixKrueger/Bismark
# ############################ Subread package ###################
%apprun featureCounts
exec featureCounts
%appinstall featureCounts
wget -O subread.tar.gz https://sourceforge.net/projects/subread/files/subread-2.0.1/subread-2.0.1-source.tar.gz/download
tar zxvf subread.tar.gz
cd subread-2.0.1-source/src
make -f Makefile.Linux
cd ../bin
cp -R * /usr/local/bin/
cd ../..
rm subread.tar.gz
%apphelp featureCounts
Subread 2.0.1 featureCounts http://bioinf.wehi.edu.au/subread-package/
# ############################ UCSC tools ########################
%appinstall ucsc_tools
mkdir -p /opt/ucsc_tools
cd /opt/ucsc_tools
rsync -aP rsync://hgdownload.soe.ucsc.edu/genome/admin/exe/linux.x86_64/ ./
%apphelp ucsc_tools
UCSC tools (v390) . http://hgdownload.soe.ucsc.edu/admin/exe/ DOC: http://hgdownload.soe.ucsc.edu/admin/exe/linux.x86_64/FOOTER.txt