KIM Model name not found

Hello everyone,

I intend to use the the following potential for my simulation:
MEAM_LAMMPS_LeeLeeKim_2006_FeN__MO_432861766738_002 metal
However, I have this error message;
ERROR: KIM Model name not found (src/KIM/kim_init.cpp:234)
Last command: kim init MEAM_LAMMPS_LeeLeeKim_2006_FeN__MO_432861766738_002 metal
This my first time using OpenKIM and I test it on one of the KIM examples ( it worked smoothly.
Currently, I am running the lasted editions on both lammps (2Aug2023) and OpenKIM (2.3.0-1)
Can you please let me know what I am doing wrong?
Thank you so much!

Hi Abdo,

You most likely need to install the model first. Hopefully you used a method other than Conda to install the KIM API (currently the Conda installation does not support installing models that are not in the openkim-models package).

Try the following shell command:

kim-api-collections-management install user MEAM_LAMMPS_LeeLeeKim_2006_FeN__MO_432861766738_002
1 Like

Thank you so much!

I am operating ubuntu ubuntu linux. Is there any specific command to run openkim-models packages?

Hi Abdo,

The model you are trying to use is not in the openkim-models package, that’s why you have to install it separately using the kim-api-collections-management utility.

Were you able to run the command I gave you? If it succeeds, your LAMMPS script should work.

Hello Ilia,
when I ran your command, I got this error message:
CMake Error at CMakeLists.txt:7 (project): The CMAKE_CXX_COMPILER: /usr/bin/c++ is not a full path to an existing compiler tool.
Then I searched about this CMAKE_CXX_COMPILER error, and I found that I need to run the following command: CC=gcc-X CXX=g+±X FC=gfortran-X cmake … -DCMAKE_BUILD_TYPE=Release
However, I got another error message:
CMake Error at /usr/share/cmake-3.27/Modules/CMakeDetermineCXXCompiler.cmake:48 (message):
Could not find compiler set in environment variable CXX: g+±X.
I tried some solutions such as; sudo apt install gcc g++, but still the last message remains.
I guess there are some problems with my cmake.
Please let me know what you think of this!
Thank you so much!

Hi Abdo,

How did you install the KIM API? Did you use

sudo apt install libkim-api-dev

or some other method (such as building from source or Conda)?

I should also take a step back to point out that, if you already have the ‘openkim-models’ package installed, you should be able to use version 000 of the potential. It is included in ‘openkim-models’

The only functional difference between 000 and 002 is a bugfix that only affects some MEAM models, and the bug only occurs when multiple “kim init” commands are issued in a single script. This happens when using the ASE interface to LAMMPS, or in some specialized situations, but in general use it should not be an issue.

Dear Ilia,
Sorry for the late reply!
Thank you so much for your support!
The problem has been solved and the (MEAM_LAMMPS_LeeLeeKim_2006_FeN__MO_432861766738_002) works now.
However, when I continue running the rest of the script I received this error;
terminate called after throwing an instance of ‘std::logic_error’
what(): basic_string: construction from null is not valid
Btw, I had the same error when I ran the (MEAM_LAMMPS_LeeLeeKim_2006_FeN__MO_432861766738_000) model.
I have already test my script on Windows system (without the openkim model) and it was working fine.
Do you have any ideas regarding how to solve this issue?
Thank you for your help!

Hi Abdo,

Two questions:

  1. You say that your test script without OpenKIM is working on Windows. Is this the same machine you are running the OpenKIM version of the script on? If not, can you try without OpenKIM on your current machine?
  2. If indeed your script on the same machine works without OpenKIM, but not with OpenKIM, can you attach the entire log.lammps file of the run that results in the error?

Hello Ilia,
To answer your first question; I am currently operating on a dual SSD system. One SSD has Windows system installed and ubuntu Linux on the other. The reason why I did this is because the OpenKIM is still not available on Windows. I tried to run my script using meam potential but I encoutered an error of (Unrecognized pair style ‘meam’). Even though I tried to install the cmake correctly, I manually installed the meam via (make yes-meam) and then recompile via (make mpi), but still I have the same error.
Anyway, I am trying to use FCC iron which different than the BCC iron in the meam potential. That’s why I tried to use the OpenKIM in the first place.
Here is my input and a log.lammps files.

Thank you so much for taking the time to help me!
log.lammps (2.3 KB) (2.2 KB)

Hi Abdo,

The KIM syntax you are using is out of date (even for the relatively old version of LAMMPS that you are using:
lammps/doc/src/kim_commands.rst at 7586adbb6a61254125992709ef2fda9134cfca6c · lammps/lammps · GitHub)

You should replace the lines

pair_style kim

pair_coeff * * kim MEAM_LAMMPS_LeeLeeKim_2006_FeN__MO_432861766738_002 Fe N


kim interactions Fe N

This may fix your issue, give it a try.