layanmoyura / mpi_basics-1

MPI basics codes of EE8207 HPC module

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

mpi_basics

Dedicated to MPI Basics

Make sure you have installed MPI in your system. We will be using OpenMPI to write our examples.

C++

cd cpp
mkdir build
cd build
cmake ../
make

Python

Create a virtual environment

python3 -m venv mpi_env
source mpi_env/bin/activate
pip install mpi4py

Run Examples

C++

cd cpp
mpirun -n 4 ./hello_world

Python

mpirun -n 4 python3 hello_world.py

About

MPI basics codes of EE8207 HPC module

License:Apache License 2.0


Languages

Language:Python 69.9%Language:C++ 22.6%Language:Cuda 4.7%Language:CMake 2.8%