Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Issue with MPI in openseespy #298

Open
tanzeel970 opened this issue Dec 26, 2023 · 2 comments
Open

Issue with MPI in openseespy #298

tanzeel970 opened this issue Dec 26, 2023 · 2 comments

Comments

@tanzeel970
Copy link

Hi
i want to use a HPC to run a multiple process analysis
I have gone through the video https://www.youtube.com/watch?v=vjGm2kM5Ihc and was running the simple hello world code, i keep on getting no of processes to be 1, even though i am using multiple inputs ! /usr/mpi/gcc/openmpi-4.1.5rc2/bin/mpiexec -np 4 python codename.py following is the output
Hello World 0
Total number of processes 1
Hello World 0
Total number of processes 1
Hello World 0
Total number of processes 1
Process 0 Terminating
Hello World 0
Total number of processes 1
Process 0 Terminating
Process 0 Terminating
Process 0 Terminating

To check if the issue was with MPI i ran the following python code using the same command ! /usr/mpi/gcc/openmpi-4.1.5rc2/bin/mpiexec -np 4 python codename.py
from mpi4py import MPI

comm = MPI.COMM_WORLD
pid = comm.Get_rank()
np = comm.Get_size()

print('Hello World from process:', pid)
if pid == 0:
print('Total processes:', np)

and i get the following output
Hello World from process: 3
Hello World from process: 1
Hello World from process: 0
Total processes: 4
Hello World from process: 2
Am i missing something?

@zhuminjie
Copy link
Owner

Might be due to mpi version and implementation. We compiled it using MPICH.

@tanzeel970
Copy link
Author

Thank you for your kind response, I loaded the MPICH using module in the a separate environment and it worked

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants