forked from easybuilders/easybuild-easyconfigs
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request easybuilders#19489 from boegel/20240104140049_new_…
…pr_dorado051 {bio}[foss/2022a] dorado v0.5.1 w/ CUDA 11.7.0
- Loading branch information
Showing
1 changed file
with
74 additions
and
0 deletions.
There are no files selected for viewing
74 changes: 74 additions & 0 deletions
74
easybuild/easyconfigs/d/dorado/dorado-0.5.1-foss-2022a-CUDA-11.7.0.eb
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,74 @@ | ||
easyblock = 'CMakeMake' | ||
|
||
name = 'dorado' | ||
version = '0.5.1' | ||
versionsuffix = '-CUDA-%(cudaver)s' | ||
|
||
homepage = 'https://github.com/nanoporetech/dorado' | ||
description = """Dorado is a high-performance, easy-to-use, open source basecaller for Oxford Nanopore reads.""" | ||
|
||
toolchain = {'name': 'foss', 'version': '2022a'} | ||
# -Wno-error option is required to fix: | ||
# error: void {anonymous}::convert_f32_to_f16_impl(c10::Half*, const float*, std::size_t) defined but not used | ||
toolchainopts = {'usempi': True, 'extra_cxxflags': "-Wno-error=unused-function"} | ||
|
||
source_urls = ['https://github.com/nanoporetech/dorado/archive/'] | ||
sources = [{ | ||
'git_config': { | ||
'url': 'https://github.com/nanoporetech', | ||
'repo_name': name, | ||
'tag': 'v%(version)s', | ||
'recursive': True, | ||
}, | ||
'filename': SOURCE_TAR_GZ, | ||
}] | ||
checksums = [None] | ||
|
||
builddependencies = [ | ||
('binutils', '2.38'), | ||
('CMake', '3.24.3'), | ||
] | ||
|
||
dependencies = [ | ||
('CUDA', '11.7.0', '', SYSTEM), | ||
('OpenSSL', '1.1', '', SYSTEM), | ||
('PyTorch', '1.12.0', '-CUDA-%(cudaver)s'), | ||
('HDF5', '1.12.2'), | ||
('zstd', '1.5.2'), | ||
('HTSlib', '1.15.1'), | ||
('kineto', '0.4.0'), | ||
('libaec', '1.0.6'), | ||
] | ||
|
||
# don't link to OpenSSL static libraries | ||
# fix for CMake Error "missing: OPENSSL_CRYPTO_LIBRARY" (if only shared OpenSSL libraries are available) | ||
preconfigopts = "sed -i '/OPENSSL_USE_STATIC_LIBS TRUE/d' ../dorado/cmake/OpenSSL.cmake && " | ||
preconfigopts += "export OPENSSL_ROOT_DIR=$EBROOTOPENSSL && " | ||
# link in the ssl and crypto libs, to fix: | ||
# undefined reference to symbol 'SSL_get_peer_certificate@@OPENSSL_1_1_0' | ||
preconfigopts += "sed -i 's/OpenSSL::SSL/ssl\\n crypto/g' ../dorado/dorado/utils/CMakeLists.txt && " | ||
|
||
# don't use vendored HTSlib, use provided HTSlib dependency | ||
preconfigopts += "rm -r ../dorado/dorado/3rdparty/htslib/ && " | ||
preconfigopts += "sed -i '/add_dependencies.*htslib_project/d' ../dorado/CMakeLists.txt && " | ||
preconfigopts += "sed -i '/add_dependencies.*htslib_project/d' ../dorado/dorado/utils/CMakeLists.txt && " | ||
preconfigopts += "sed -i '/Htslib.cmake/d' ../dorado/CMakeLists.txt && " | ||
# link with -lhts, not -lhtslib | ||
preconfigopts += "sed -i 's/htslib/hts/g' ../dorado/CMakeLists.txt && " | ||
preconfigopts += "sed -i 's/htslib/hts/g' ../dorado/dorado/utils/CMakeLists.txt && " | ||
|
||
configopts = "-DDORADO_INSTALL_PATH=%(installdir)s " | ||
configopts += "-DCUDA_TOOLKIT_ROOT_DIR=$EBROOTCUDA -DCMAKE_CUDA_COMPILER=$EBROOTCUDA/bin/nvcc " | ||
configopts += "-DDORADO_LIBTORCH_DIR=$EBROOTPYTORCH/lib " | ||
# add -pthread flag (in addition to -lpthread) to avoid linking error: | ||
# in function `_GLOBAL__sub_I_mutex.cc': mutex.cc:(.text.startup+0x17): undefined reference to `pthread_atfork' | ||
configopts += '-DCMAKE_C_FLAGS="$CFLAGS -pthread" ' | ||
|
||
sanity_check_paths = { | ||
'files': ['bin/dorado'], | ||
'dirs': [], | ||
} | ||
|
||
sanity_check_commands = ["dorado basecaller --help"] | ||
|
||
moduleclass = 'bio' |