Problem while running NEB, neb style 'each'

Hello everyone
I am sorry if the question is so bacis, acutally I am facing problem while running NEB and using the file style ‘each’. The calculation don’t run with the error of ‘Illegal NEB command (src/REPLICA/neb.cpp:124)’.
I have all replicas initial configurations present in the directory and here is the simplest command I am using for neb
‘neb 0.0 0.001 1000 500 30 each sic.1 sic.2 sic.3 sic.4 sic.5 sic.6 sic.7’

I have also tried by specifying variable “variable i equal part” and neb command “neb 0.0 0.001 1000 500 50 each sic.$i”
even, I also try to run with “variable u uloop 7” and mentioning it in neb command.
can you suggest me where could be the problem.
i am facing very bad optimisation of final replica with file style final for so I am trying to be mroe confident of final geometry so I am using this file style.
please accept my best regards
Irslan Ullah Ashraf

Basic or not, there are crucial pieces of information missing here like what is the exact LAMMPS version you are using, what is the platform you are running on and - since you are using a REPLICA package command, what is the exact command line you are using, so that we see how many replica you are using.

This is incorrect and in conflict with the documentation.

What is the exact error message in this case?

That would also be incorrect.

That reasoning makes little sense.
Are you saying that if you use minimize in a standalone calculation on the final geometry, you get a different geometry than what you get with the neb command? Can you provide a minimal example demonstrating that?

1 Like

FWIW, I can run the in.neb.sivac input file from the LAMMPS distribution with the following modifications:

  • in the in.neb.sivac file replace the line neb 0.0 0.01 100 100 10 final final.sivac with variable i equal part and neb 0.0 0.01 100 100 10 each $i.sivac
  • copy the file final.sivac to 2.sivac
  • create a file 1.sivac based on 2.sivac where the coordinates are in between their values in initial.sivac and 2.sivac

This input deck runs without errors and converges to the specified tolerances.

1 Like

Dear akohlmey
I am using lammps version 2019. For now I try to reproduce your calculation, I applied your suggested modifications in the in.neb.sivac from the LAMMPS distribution, I generated a complete replica 1.sivac with interpolated coordinated for 7 atoms(as in 2.sivac). all other coordinates are unchanged and it showed following error.
mpirun -np 3 lmp -partition 3x1 -in in.neb.sivac

No protocol specified

LAMMPS (20 Nov 2019)

Running on 3 partitions of processors

ERROR on proc 0: Cannot open file 0.sivac (src/REPLICA/neb.cpp:568)


MPI_ABORT was invoked on rank 0 in communicator MPI COMMUNICATOR 3 SPLIT FROM 0

with errorcode 1.

NOTE: invoking MPI_ABORT causes Open MPI to kill all MPI processes.

You may or may not see output from other processes, depending on

exactly when Open MPI kills them.

seeing this error I also generated 0.sivac by copying initial.sivac, but than it showed this error

Running on 3 partitions of processors
ERROR: Incorrectly formatted NEB file (src/REPLICA/neb.cpp:404)

Primary job terminated normally, but 1 process returned
a non-zero exit code. Per user-direction, the job has been aborted.


mpirun detected that one or more processes exited with non-zero status, thus causing
the job to be terminated. The first process to do so was:

Process name: [[47190,1],0]
Exit code: 1
can you please look at this matter
please accept my best regards
Irslan Ullah Ashraf

Dear Dr. Akohlmey
Please find the the required information,

I am using LAMMPS version nov 2019. and I am running on server machine platform with following command ‘mpirun np 14 lmp -partition 7x2 -in in.neb.si.vac’ so I am using 7 replicas.

since I was facing error with replica files by using variable, so I try to specify each unique replica in simplest way directly but before that I do specified the replica files according to documentation

i got following error; " mpirun -np 14 lmp -partition 7x2 -in in.si.vac.hop

No protocol specified

LAMMPS (20 Nov 2019)

Running on 7 partitions of processors

ERROR: Illegal NEB command (src/REPLICA/neb.cpp:124)


Primary job terminated normally, but 1 process returned

a non-zero exit code. Per user-direction, the job has been aborted.



mpirun detected that one or more processes exited with non-zero status, thus causing

the job to be terminated. The first process to do so was:

Process name: [[46400,1],0]

Exit code: 1"

you catch the message correctly, to give an example, I try to calculate carbon antisite vacancy diffusion barrier using NEB, I checked opitmisation of final replica, and accuracy of NEB calculaiton by doing standalone calculation for initial and final Replicas. The difference of energy among them should be same to diffusion barrier of NEB that was not the case, so I try to go with different method of NEB.

Thank you so much for kind suggestions
Irslan Ullah Ashraf

This error does not happen for me with the same version of LAMMPS.

Either you did not do the modifications exactly as indicated or your MPI library is not functioning correctly. In either case, there is nothing that I can do about it.

1 Like

When looking up the line in the source code where the error message is printed, I can see that this specific error would happen, if either of the numbers N1 or N2 are not multiples of the Nevery setting. The documentation explicitly states that this is a requirement. This error has nothing to do with how you specify the coordinates for the individual replica.

Not at all. The barrier determined by NEB is the barrier between two (local) minima. By definition it has to be larger than the difference in energy between the two minima. If it would be that same, then there would be no barrier.

1 Like

Dear Dr. Akohlmey,
I have a question related to this speficied file-style of final. Since you are asking to specify the intermediate replica “1.sivac” and than taking it with part no. variable. but according to documentation
" For a file-style setting of final , a filename is specified which contains atomic coordinates for zero or more atoms, in the format described below. For each atom that appears in the file, the new coordinates are assigned to that atom in the final replica. Each intermediate replica also assigns a new position to that atom in an interpolated manner."
my question is why we need to specify ourself intermediate coordinates if it has to calculate on it self. can you suggest example for file-style ‘each’ ?
Moreover, for the same file-style it’s mentioned that "Note that for this procedure to produce consistent coordinates across all the replicas, the current coordinates need to be the same in all replicas. "
how we can check of current coordinates in all replicas when LAMMPS generates replicas on it self for file-style final ?
Also, can you comment what is meaning of

error ? shouldn’t LAMMPS should initial.sivac as 0.sivac ?
please accept my best regards
Irslan Ullah Ashraf

You are mixing the documentation of two different “modes”. You can either use the “final” mode where you provide only the coordinates in the final geometry of the endpoint of the NEB chain that are different from the initial coordinates. This defines the geometries of two replica, the geometries of the remaining replica is generated from interpolation. Or you can use “each” mode, where you need to provide geometries of the changes of every replica (except the first). Or you can use “none” mode, where the different geometries are provided through different data files or per-partition scripting.

The example you are quoting was meant to be for “each” mode, but there is obviously a cut-n-paste error. I copied the wrong line, so you have to replace the “final” keyword with “each”.

1 Like

Dear Dr. Akohlmey
Thank you so much for clarifying, you’r 2nd answer actually given answer for my all questions. Since morning I was trying to extract meaning from above method.
I am following exactly the same pattern for calculation, except I am having a different system and more replicas. Everything is correct, but I am still having this PMIX error,
can you please comment on this ?
"mpirun -np 7 lmp -partition 7x1 -in in.si.vac.hop

No protocol specified

LAMMPS (20 Nov 2019)

Running on 7 partitions of processors


MPI_ABORT was invoked on rank 4 in communicator MPI_COMM_WORLD

with errorcode 1.

NOTE: invoking MPI_ABORT causes Open MPI to kill all MPI processes.

You may or may not see output from other processes, depending on

exactly when Open MPI kills them.


[IMM-PowerEdge-R7525:2964623] PMIX ERROR: UNREACHABLE in file …/…/…/src/server/pmix_server.c at line 2193

[IMM-PowerEdge-R7525:2964623] 4 more processes have sent help message help-mpi-api.txt / mpi-abort

[IMM-PowerEdge-R7525:2964623] Set MCA parameter “orte_base_help_aggregate” to 0 to see all help / error messages
please accept my best regards
Irslan Ullah Ashraf

This means that there has been an error on one of the replica. Impossible to say from remote which error. You have to look through the screen and log file for replica 4.

1 Like