Bioconda: Difference between revisions
Jump to navigation
Jump to search
Line 104: | Line 104: | ||
#SBATCH --time=0-01:00:00 | #SBATCH --time=0-01:00:00 | ||
# ==================================== | # ==================================== | ||
# Activate | # Activate BioConda. | ||
source /global/software/bioconda/init-2024-10 | source /global/software/bioconda/init-2024-10 | ||
Latest revision as of 21:55, 14 November 2024
General
- Home page: https://bioconda.github.io/index.html
- List of available packages: https://bioconda.github.io/conda-package_index.html
Bioconda on ARC
Available modules
To activate
$ module avail bioconda -------------------- /global/software/Modules/4.6.0/modulefiles ----------------- bioconda/2024-10
- BioConda/2024-10 is based on the
bioconda
andconda-forge
channels.
- It does not depend nor use the Anaconda
base
andanaconda
channels to avoid any licensing complications. - It was installed in October 2024 and includes a large number of more popular BioConda packages.
You can load the module
$ module load bioconda/2024-10 ### !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! ### This is a stub module. It does not activate the central BioConda install. If you want to activate BioConda/2024-10 please use the following command in your job script: source /global/software/bioconda/init-2024-10 Module activation does not work propely for this BioConda due to technical limitaions. This may change in the future. ### !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! ### Loading bioconda/2024-10 ERROR: Module evaluation aborted
The message indicate that the module cannot activate BioConda correctly, so you have to use the command
source /global/software/bioconda/init-2024-10
instead.
Once you have BioConda activated you can check the software
$ samtools --version samtools 1.21 Using htslib 1.21 Copyright (C) 2024 Genome Research Ltd. $ salmon --version version : 0.8.1 $ kraken --version Kraken version 1.1.1 Copyright 2013-2019, Derrick Wood, Jennifer Lu (jlu26@jhmi.edu)
Get the full list of installed packages:
$ conda list ....
or search for a specific package:
$ conda list STAR # packages in environment at /global/software/bioconda/2024-10/envs/bioconda: # # Name Version Build Channel star 2.7.11a h0033a41_0 bioconda star-fusion 1.7.0 1 bioconda staramr 0.10.0 pyhdfd78af_0 bioconda starcode 1.4 h031d066_5 bioconda starfish 0.2.2 pyhdfd78af_0 bioconda
Installing your own personal BioConda
If the preinstalled versions provided by the modules do not work for you, you can
- Install your own Conda, following these instructions.
- Create a new BioConda environment:
conda create -n bioconda
- Activate the environment:
conda activate bioconda
- Install the required packages
conda install -c bioconda samtools star salmon kraken
Using Conda in your job scripts
Centrally Installed BioConda
If you want to use the preinstalled BioConda environment:
preinstalled-bioconda-job.slurm
:
#! /bin/bash
# ====================================
#SBATCH --job-name=conda-test
#SBATCH --nodes=1
#SBATCH --ntasks=1
#SBATCH --cpus-per-task=1
#SBATCH --mem=4GB
#SBATCH --time=0-01:00:00
# ====================================
# Activate BioConda.
source /global/software/bioconda/init-2024-10
# Use the software here.
....
....
Personal Conda
If you are going to be using your own personal BioConda install:
personal-conda-job.slurm
:
#! /bin/bash
# ====================================
#SBATCH --job-name=conda-test
#SBATCH --nodes=1
#SBATCH --ntasks=1
#SBATCH --cpus-per-task=1
#SBATCH --mem=4GB
#SBATCH --time=0-01:00:00
# ====================================
# Activate Conda and then the environment.
source ~/software/init-conda
conda activate bioconda
# Use the software here.
....
....