9. Some Exemplar Applications

Now that we have covered the basics, let’s take a look at some larger examples that illustrate message passing in Python using the mpi4py library. The two examples that we have prepared for you are called “Drug Design” and “Forest Fire”.

Both exemplars are located under the CSinParallel/Exemplars/mpi4py-examples/ folder. Click on the links below to read about each in detail.


In the exemplars that follow, we change the way we run the programs. Instead of using the run.py wrapper program (as we did in the earlier patternlet exaples), we now use the mpirun command in conjunction with a specified hostfile (called hostfile, which is located in the root directory). The -np flag specifies the number of processes to launch. Running programs using mpriun is the common way of executing MPI programs. In these exemplars, you will gain practice on using this command.

You have attempted of activities on this page