I started using MPJExpress recently on windows. Did all the configurations mentioned in the document for windows
Ran this small program :-
import mpi.*;
public class HelloWorld {
public static void main(String args[]) throws Exception {
MPI.Init(args);
int me = MPI.COMM_WORLD.Rank();
int size = MPI.COMM_WORLD.Size();
System.out.println("Hi from <" + me + ">");
MPI.Finalize();
}
}
And when I run this I get this error :-
Exception in thread "main" mpi.MPIException: Usage: java MPI <myrank> <conf_file> <device_name> conf_file can be, ../conf/xdev.conf <Local>OR http://holly.dsg.port.ac.uk:15000/xdev.conf <Remote>
at mpi.MPI.Init(MPI.java:232)
there is no xdev.conf file in ../conf/xdev.conf (I also checked previous MPJExpress versions) also http://holly.dsg.port.ac.uk:15000/xdev.conf is not reachable
When I see the code for MPJDev.java I see if
(args.length < 3) {
throw new MPJDevException("Usage: " +
"java MPJDev <myrank> <conf_file> <device_name>"
+"conf_file can be, ../conf/xdev.conf <Local>"
+"OR http://holly.dsg.port.ac.uk:15000/xdev.conf <Remote>");
}
What am I doing wrong, to get the above exception. It looks like args.length is less than 3, so I get the above exception. How can I rectify it ?
@aadityachauhan you cannot run MPJ Express applications using Run as Java Application option. For that you need to pass arguments in VM Arguments section. You can look at first half of this Youtube Video Tutorial to run MPJ Express with Eclipse.