deepmd.pd.utils#
Submodules#
- deepmd.pd.utils.auto_batch_size
- deepmd.pd.utils.dataloader
- deepmd.pd.utils.dataset
- deepmd.pd.utils.decomp
- deepmd.pd.utils.dp_random
- deepmd.pd.utils.env
- deepmd.pd.utils.env_mat_stat
- deepmd.pd.utils.exclude_mask
- deepmd.pd.utils.finetune
- deepmd.pd.utils.learning_rate
- deepmd.pd.utils.multi_task
- deepmd.pd.utils.neighbor_stat
- deepmd.pd.utils.nlist
- deepmd.pd.utils.preprocess
- deepmd.pd.utils.region
- deepmd.pd.utils.serialization
- deepmd.pd.utils.spin
- deepmd.pd.utils.stat
- deepmd.pd.utils.update_sel
- deepmd.pd.utils.utils
Classes#
Computes the type exclusion mask for atoms. | |
Computes the type exclusion mask for atom pairs. |
Package Contents#
- class deepmd.pd.utils.AtomExcludeMask(ntypes: int, exclude_types: list[int] = [])[source]#
Bases:
paddle.nn.LayerComputes the type exclusion mask for atoms.
- class deepmd.pd.utils.PairExcludeMask(ntypes: int, exclude_types: list[tuple[int, int]] = [])[source]#
Bases:
paddle.nn.LayerComputes the type exclusion mask for atom pairs.
- forward(nlist: paddle.Tensor, atype_ext: paddle.Tensor) paddle.Tensor[source]#
Compute type exclusion mask.
- Parameters:
- nlist
The neighbor list. shape: nf x nloc x nnei
- atype_ext
The extended aotm types. shape: nf x nall
- Returns:
maskThe type exclusion mask of shape: nf x nloc x nnei. Element [ff,ii,jj] being 0 if type(ii), type(nlist[ff,ii,jj]) is excluded, otherwise being 1.