diff --git a/python/lammps/mliap/loader.py b/python/lammps/mliap/loader.py index 284af01b05..b2d0079220 100644 --- a/python/lammps/mliap/loader.py +++ b/python/lammps/mliap/loader.py @@ -57,7 +57,7 @@ class DynamicLoader(importlib.abc.Loader): def activate_mliappy(lmp): try: library = lmp.lib - module_names = ["mliap_model_python_couple", "mliap_unifiedpy"] + module_names = ["mliap_model_python_couple", "mliap_unified_couple"] api_version = library.lammps_PYTHON_API_VERSION() for module_name in module_names: @@ -83,9 +83,9 @@ def load_model(model): def load_unified(model): try: - import mliap_unifiedpy + import mliap_unified_couple except ImportError as ie: raise ImportError("ML-IAP python module must be activated before loading\n" "the pair style. Call lammps.mliap.activate_mliappy(lmp)." ) from ie - mliap_unifiedpy.load_from_python(model) + mliap_unified_couple.load_from_python(model) diff --git a/src/ML-IAP/mliap_unified.cpp b/src/ML-IAP/mliap_unified.cpp index f4f1501675..c31cdd2c81 100644 --- a/src/ML-IAP/mliap_unified.cpp +++ b/src/ML-IAP/mliap_unified.cpp @@ -23,7 +23,7 @@ #include "memory.h" #include "lmppython.h" #include "mliap_data.h" -#include "mliap_unifiedpy.h" +#include "mliap_unified_couple.h" #include "pair_mliap.h" #include "python_compat.h" #include "utils.h" @@ -169,7 +169,7 @@ MLIAPBuildUnified_t LAMMPS_NS::build_unified(char *unified_fname, MLIAPData *dat lmp->error->all(FLERR, "Could not initialize embedded Python"); } - PyObject *unified_module = PyImport_ImportModule("mliap_unifiedpy"); + PyObject *unified_module = PyImport_ImportModule("mliap_unified_couple"); if (PyErr_Occurred()) { PyErr_Print(); diff --git a/src/ML-IAP/mliap_unifiedpy.pyx b/src/ML-IAP/mliap_unified_couple.pyx similarity index 100% rename from src/ML-IAP/mliap_unifiedpy.pyx rename to src/ML-IAP/mliap_unified_couple.pyx diff --git a/src/PYTHON/python_impl.cpp b/src/PYTHON/python_impl.cpp index 58919de977..aba8e88e10 100644 --- a/src/PYTHON/python_impl.cpp +++ b/src/PYTHON/python_impl.cpp @@ -34,7 +34,7 @@ // We could get around this with cython --capi-reexport-cincludes // However, that exposes -too many- headers. #include "mliap_model_python_couple.h" -#include "mliap_unifiedpy.h" +#include "mliap_unified_couple.h" #endif using namespace LAMMPS_NS; @@ -69,7 +69,7 @@ PythonImpl::PythonImpl(LAMMPS *lmp) : Pointers(lmp) int err = PyImport_AppendInittab("mliap_model_python_couple", PyInit_mliap_model_python_couple); if (err) error->all(FLERR, "Could not register MLIAPPY embedded python module."); - err = PyImport_AppendInittab("mliap_unifiedpy", PyInit_mliap_unifiedpy); + err = PyImport_AppendInittab("mliap_unified_couple", PyInit_mliap_unified_couple); if (err) error->all(FLERR, "Could not register MLIAPPY unified embedded python module."); #endif