deepmd.tf.utils.nlist

Module Contents

Functions

extend_coord_with_ghosts(coord, atype, cell, rcut, pbc)

Extend the coordinates of the atoms by appending peridoc images.

deepmd.tf.utils.nlist.extend_coord_with_ghosts(coord: deepmd.tf.env.tf.Tensor, atype: deepmd.tf.env.tf.Tensor, cell: deepmd.tf.env.tf.Tensor, rcut: float, pbc: deepmd.tf.env.tf.Tensor)[source]

Extend the coordinates of the atoms by appending peridoc images. The number of images is large enough to ensure all the neighbors within rcut are appended.

Parameters:
coordtf.Tensor

original coordinates of shape [-1, nloc*3].

atypetf.Tensor

atom type of shape [-1, nloc].

celltf.Tensor

simulation cell tensor of shape [-1, 9].

rcutfloat

the cutoff radius

pbctf.Tensor

whether the simulation cell is periodic or not

Returns:
extended_coord: tf.Tensor

extended coordinates of shape [-1, nall*3].

extended_atype: tf.Tensor

extended atom type of shape [-1, nall].

index_mapping: tf.Tensor

maping extended index to the local index