Skip to content

migrate-n

A bioinformatics and population genetics program that models population sizes, gene flow between populations, and past migration rates.


migrate-n requires an environment module

In order to use migrate-n, you must first load the appropriate environment module:

module load gnu

Running migrate-n#

Once the appropriate modules are loaded (gnu is required, and gnu openmpi if you want to run the app in parallel).

1
2
3
4
5
6
7
8
# Load the GNU module to access the `migrate-n` runtime command
$ module load gnu

# Load the OpenMPI module if you need to run migrate-n on the cluster in parallel
$ module load openmpi

$ migrate-n-4      # Serial
$ migrate-n-4-mpi  # Parallel

Migrate-n expects an input file named infile to be present in the same path as you run the program from.

# Load the GNU environment module
$ module load gnu

# Create directory and copy sample data file into it 
$ mkdir ~/migrate-n
$ cp /gpfs/research/software/migrate-n/infile.sample ~/migrate-n/infile

# Run migrate-n
$ cd ~/migrate-n
$ migrate-n
A menu will appear, which can be ignored for the purpose of this example. Simply type Y and allow the program to run. Using the sample infile will not produce any useful results, but it will complete successfully.

Parallel execution#

Migrate-n is available using the both OpenMPI and MVAPICH2. To run Migrate-n in parallel mode, use the following commands:

$ module load gnu openmpi
$ migrate-n-4-mpi

The design of the program requires on director node in addition to worker nodes, so for a four-node job, you need n=5 total nodes.

Slurm submit script example#

1
2
3
4
5
6
7
8
9
#!/bin/bash
#SBATCH --nodes=5
#SBATCH --ntasks-per-node=4
#SBATCH -A backfill
#SBATCH -t 04:00:00

module load gnu openmpi

srun migrate-n-4-mpi