Lammps Memory Problem

Dear All,

In my Lammps input script I am trying to create many regions ( more than 200k). However, as I observed, memory used by Lammps increases linearly as the regions are being created. And after a certain memory (around 256M), the job is killed by Signal 9 due to Rank 0 on one of the processors. When I reduce the number of processors, I can increase the number of regions that can be generated, but it is still terminated because it cannot reach to total number of regions.

I tried to delete regions after their corresponded union operation. But, even I created new region Ids with union operation. If I delete one of the regions that is created before union operation, create_atoms command gidoes not work and execution is terminated. So I can not delete regions to decrease the number of regions.

How can I manage this linearly increasing memory problem? Should I change something during compilation of Lammps?

I would appreciate if you take your time to help with this issue.

Regards,
Mesut

Dear All,

In my Lammps input script I am trying to create many regions ( more than
200k). However, as I observed, memory used by Lammps increases linearly as
the regions are being created. And after a certain memory (around 256M), the
job is killed by Signal 9 due to Rank 0 on one of the processors. When I
reduce the number of processors, I can increase the number of regions that
can be generated, but it is still terminated because it cannot reach to
total number of regions.

signal 9 is a kill signal that has to come from some external entity not lammps.

I tried to delete regions after their corresponded union operation. But,
even I created new region Ids with union operation. If I delete one of the
regions that is created before union operation, create_atoms command gidoes
not work and execution is terminated. So I can not delete regions to
decrease the number of regions.

How can I manage this linearly increasing memory problem? Should I change
something during compilation of Lammps?

i cannot imagine a good reason why one would need such a large number
of regions. even if you'd get it to work it would be hugely
inefficient. there has to be a conceptual problem. what do you need
those for, anyway?

axel.

Hi Axel, thank you for your reply.

Yes, the termination is due to that Lammps absorbes all memory linearly due to large number of regions.

Unfortunately, a region created by union of 2 regions depends on its constituent regions. I mean, if you delete one of the constituent regions (after union) you can not create atoms within the resulting union region. This dependency prevent me to delete regions which are used in union operations.

At first look, large number of regions may not look reasonable, but for the generation of a complex nanostructure I really need it. Because cylindrical or cubic regions can only be generated along a x,y,z axis only, not along user-controlled oriented axis, we have limited tools to generate complex nanostructures.

Hi Axel, thank you for your reply.

Yes, the termination is due to that Lammps absorbes all memory linearly due
to large number of regions.

sorry, but you don't get a signal 9 from that. something else has to issue it.

Unfortunately, a region created by union of 2 regions depends on its
constituent regions. I mean, if you delete one of the constituent regions
(after union) you can not create atoms within the resulting union region.
This dependency prevent me to delete regions which are used in union
operations.

At first look, large number of regions may not look reasonable, but for the
generation of a complex nanostructure I really need it. Because cylindrical

no, you don't. just create a data file.

or cubic regions can only be generated along a x,y,z axis only, not along
user-controlled oriented axis, we have limited tools to generate complex
nanostructures.

nothing keeps you from writing your own region styles. but more
importantly, the structure building tools inside of LAMMPS are only
meant for be used for simple structures. for anything else, it is
orders of magnitude simpler to write a small script to generate a
suitable data file and be done with it. it is probably much easier
than what you have tried so far.

i restate my claim, that your approach is wrong.

axel.

Hi Axel, thank you for your reply.

Yes, the termination is due to that Lammps absorbes all memory linearly due
to large number of regions.

sorry, but you don't get a signal 9 from that. something else has to issue it.

Unfortunately, a region created by union of 2 regions depends on its
constituent regions. I mean, if you delete one of the constituent regions
(after union) you can not create atoms within the resulting union region.
This dependency prevent me to delete regions which are used in union
operations.

At first look, large number of regions may not look reasonable, but for the
generation of a complex nanostructure I really need it. Because cylindrical

no, you don't. just create a data file.

or cubic regions can only be generated along a x,y,z axis only, not along

oh, and that is not a correct statement either. check out move and
rotate keywords.

axel.

If you are trying to create_atoms in a region that
is the union of 200,000 sub-regions, this will be a slow
operation in LAMMPS. But there is no reason
it should not work, assuming you figure out why
the system is killing your job.

But I agree with Axel, you are probably better off

creating a data file with the coords of your initial

config, using some other mechanism to do that.

Steve