Skip to content

[Idea] Next generation interface  #102

@jan-janssen

Description

@jan-janssen

There are three things we learned so far:

  • using zmq simplifies the communication between the primary process and the subprocess.
  • with __getattribute__() we can overwrite the functions of a given class.
  • with cloudpickle we can even pickle ctypes

So for the next version of pylammpsmpi I guess we need much less code. Just load the LAMMPS library class and then before a function is called, interfere using __getattribute__(), cloudpickle the data that is communicated transfer it to the MPI parallel subprocess and then execute the call there. Afterwards cloudpickle the response and communicate it back up. This should drastically decrease the code base for pylammpsmpi and increase the consistency with the official LAMMPS python API.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions