Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

{bio}[foss/2021b] finder v1.1.0 #16910

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
70 changes: 70 additions & 0 deletions easybuild/easyconfigs/f/finder/finder-1.1.0-foss-2021b.eb
Original file line number Diff line number Diff line change
@@ -0,0 +1,70 @@
# author: Denis Kristak (INUITS)
easyblock = 'Binary'

name = 'finder'
version = '1.1.0'

homepage = 'https://github.com/sagnikbanerjee15/Finder/'
description = """finder is a gene annotator pipeline which automates the process of downloading short reads,
aligning them and using the assembled transcripts to generate gene annotations."""

toolchain = {'name': 'foss', 'version': '2021b'}
toolchainopts = {'openmp': True}

source_urls = [
'https://github.com/sagnikbanerjee15/Finder/archive/',
'ftp://ftp.ensemblgenomes.org/pub/plants/release-49/fasta/arabidopsis_thaliana/dna/'
]
sources = ['%(name)s_v%(version)s.tar.gz', 'Arabidopsis_thaliana.TAIR10.dna_sm.toplevel.fa.gz']
patches = ['finder-%(version)s_run_bare_option.patch']
checksums = [
{'finder_v1.1.0.tar.gz': 'be416a01b94f2ac183fb9c4945b09b8f40ac0e40b12e2c08c343bd2aad28bf98'},
{'Arabidopsis_thaliana.TAIR10.dna_sm.toplevel.fa.gz':
'4598dbd9f6913527933e9822e0d15d7016571de1f8e925c37917e840e8a453bd'},
{'finder-1.1.0_run_bare_option.patch': '43ee4046bcecc1a1555ef0dc9b98487281c0344028ef6cf1428d24bbfd6cd1ca'},
]

dependencies = [
('STAR', '2.7.9a'),
('SAMtools', '1.14'),
('BEDTools', '2.30.0'),
('AUGUSTUS', '3.4.0'),
('BRAKER', '2.1.6'),
('GeneMark-ET', '4.71'),
('PsiCLASS', '1.0.3'),
('olego', '1.1.9'),
('GUSHR', '2020-09-28'),
('gffread', '0.12.7'),
('BEDOPS', '2.4.41'),
('RegTools', '0.5.2'),
('BLAST+', '2.12.0'),
('CodAn', '1.2'),
('GffCompare', '0.12.6'),
('XZ', '5.2.5'),
('bzip2', '1.0.8'),
('Autotools', '20210726'),
('Python', '3.9.6'),
('SciPy-bundle', '2021.10'),
('Trimmomatic', '0.39', '-Java-11', SYSTEM),
('Boost', '1.77.0'),
('ruffus', '2.8.4'),
('SRA-Toolkit', '3.0.0'),
]

extract_sources = True

install_cmd = "cp -r %(builddir)s/Finder-finder_v%(version)s/* %(installdir)s/ "


sanity_check_paths = {
'files': ['run_finder'],
"dirs": [],
}

modextrapaths = {
'PATH': ['utils']
}

sanity_check_commands = ["finder --help"]

moduleclass = 'bio'
84 changes: 84 additions & 0 deletions easybuild/easyconfigs/f/finder/finder-1.1.0_run_bare_option.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,84 @@
adding option to the run_finder script, to be able to run without using singularity or docker
author: Denis Kristak (INUITS)
diff -ruN Finder-finder_v1.1.0_orig/run_finder Finder-finder_v1.1.0/run_finder
--- Finder-finder_v1.1.0_orig/run_finder 2021-12-19 20:46:57.000000000 +0100
+++ Finder-finder_v1.1.0/run_finder 2022-12-15 12:08:39.120630477 +0100
@@ -45,7 +45,7 @@
optional_named.add_argument( "--skip_cpd", "--skip_cpd", help = "Turn on this option to skip changepoint detection. Could be effective for grasses", action = "store_true" )
optional_named.add_argument( "--exonerate_gff3", "-egff3", help = "Enter the exonerate output in gff3 format" )
optional_named.add_argument( "--star_shared_mem", "--star_shared_mem", help = "Turn on this option if you want STAR to load the genome index into shared memory. This saves memory if multiple finder runs are executing on the same host, but might not work in your cluster environment.", action = "store_true" )
- optional_named.add_argument( "--framework", "-fm", help = "Enter your choice of framework", choices = ["docker", "singularity"], default = "docker" )
+ optional_named.add_argument( "--framework", "-fm", help = "Enter your choice of framework", choices = ["docker", "singularity", "bare"], default = "bare" )

# optional_named.add_argument("--intron_gff3","-intron_gff3",help="Enter the name and location of the file containing introns in gff3 format")
# optional_named.add_argument("--ground_truth_gtf","-gt_gtf",help="Enter the gtf filename of the actual annotation [for developmental purposes]")
@@ -86,6 +86,12 @@
singularity_cmd += f" bash -c {command}"
os.system( singularity_cmd )

+def runBareCommand( command ):
+ """
+ Runs the command directly on the system
+ """
+ # Runs the main command
+ os.system( command )

def main():
commandLineArg = sys.argv
@@ -98,8 +104,8 @@
f"{'/'.join(options.genome.split('/')[:-1])}:{'/'.join(options.genome.split('/')[:-1])}",
f"{options.output_directory}:{options.output_directory}"]

- cmd = f" \" ulimit -n $(ulimit -Hn) && "
- cmd += f" finder "
+ # cmd = f" \" "
+ cmd = f" finder "
cmd += f" --metadatafile {options.metadatafile} "
cmd += f" --output_directory {options.output_directory} "
cmd += f" --genome {options.genome} "
@@ -137,20 +143,16 @@
cmd += f" --genemark_license {options.genemark_license}"
volumes_list.append( f"{'/'.join(options.genemark_license.split('/')[:-1])}:{'/'.join(options.genemark_license.split('/')[:-1])}" )

- cmd += f" \" "
+ # cmd += f" \" "

volumes_list = list( set( volumes_list ) )

os.system( f"mkdir -p {options.output_directory}" )
- os.system( f"which docker > {options.output_directory}/find_docker" )
- os.system( f"which singularity > {options.output_directory}/find_singularity" )
+ os.system( f"which docker > {options.output_directory}/find_docker 2> {options.output_directory}/find_docker.err" )
+ os.system( f"which singularity > {options.output_directory}/find_singularity 2> {options.output_directory}/find_singularity.err" )

- docker_installed = 1 if "Command not found" not in open( f"{options.output_directory}/find_docker", "r" ).read() else 0
- singularity_installed = 1 if "Command not found" not in open( f"{options.output_directory}/find_singularity", "r" ).read() else 0
-
- if docker_installed == 0 and singularity_installed == 0:
- print( "You need to have either docker or singularity installed" )
- sys.exit()
+ docker_installed = 1 if "no docker in" not in open( f"{options.output_directory}/find_docker", "r" ).read() else 0
+ singularity_installed = 1 if "no singularity in" not in open( f"{options.output_directory}/find_singularity", "r" ).read() else 0

framework_of_choice = ""
if options.framework == "docker":
@@ -165,6 +167,9 @@
else:
framework_of_choice = "docker"

+ elif options.framework == "bare":
+ framework_of_choice = "bare"
+
if framework_of_choice == "docker":
os.system( "docker pull sagnikbanerjee15/finder:1.1.0" )
runDockerCommand( name = "finder",
@@ -189,6 +194,9 @@
memory = '300g'
)

+ elif framework_of_choice == "bare":
+ runBareCommand(command=cmd)
+

if __name__ == "__main__":
main()
4 changes: 2 additions & 2 deletions test/easyconfigs/easyconfigs.py
Original file line number Diff line number Diff line change
Expand Up @@ -538,8 +538,8 @@ def check_dep_vars(self, gen, dep, dep_vars):
# SimpleITK 2.1.0 requires Lua 5.3.x, MedPy and nnU-Net depend on SimpleITK
(r'5\.3\.5', [r'nnU-Net-1\.7\.0-', r'MedPy-0\.4\.0-', r'SimpleITK-2\.1\.0-']),
],
# SRA-toolkit 3.0.0 requires ncbi-vdb 3.0.0
'ncbi-vdb': [(r'3\.0\.0', [r'SRA-Toolkit-3\.0\.0'])],
# SRA-toolkit 3.0.0 requires ncbi-vdb 3.0.0, Finder requires SRA-Toolkit 3.0.0
'ncbi-vdb': [(r'3\.0\.0', [r'SRA-Toolkit-3\.0\.0', r'finder-1\.1\.0'])],
# TensorFlow 2.5+ requires a more recent NCCL than version 2.4.8 used in 2019b generation;
# Horovod depends on TensorFlow, so same exception required there
'NCCL': [(r'2\.11\.4', [r'TensorFlow-2\.[5-9]\.', r'Horovod-0\.2[2-9]'])],
Expand Down