deepmd.pt.model.descriptor.gaussian_lcc

Classes

DescrptGaussianLcc

Base descriptor provides the interfaces of descriptor.

Module Contents

class deepmd.pt.model.descriptor.gaussian_lcc.DescrptGaussianLcc(rcut, rcut_smth, sel: int, ntypes: int, num_pair: int, embed_dim: int = 768, kernel_num: int = 128, pair_embed_dim: int = 64, num_block: int = 1, layer_num: int = 12, attn_head: int = 48, pair_hidden_dim: int = 16, ffn_embedding_dim: int = 768, dropout: float = 0.0, droppath_prob: float = 0.1, pair_dropout: float = 0.25, attention_dropout: float = 0.1, activation_dropout: float = 0.1, pre_ln: bool = True, do_tag_embedding: bool = False, tag_ener_pref: bool = False, atomic_sum_gbf: bool = False, pre_add_seq: bool = True, tri_update: bool = True, **kwargs)[source]

Bases: torch.nn.Module, deepmd.pt.model.descriptor.base_descriptor.BaseDescriptor

Base descriptor provides the interfaces of descriptor.

rcut[source]
rcut_smth[source]
embed_dim[source]
num_pair[source]
kernel_num[source]
pair_embed_dim[source]
num_block[source]
layer_num[source]
attention_heads[source]
pair_hidden_dim[source]
ffn_embedding_dim[source]
dropout[source]
droppath_prob[source]
pair_dropout[source]
attention_dropout[source]
activation_dropout[source]
pre_ln[source]
do_tag_embedding[source]
tag_ener_pref[source]
atomic_sum_gbf[source]
local_cluster = True[source]
pre_add_seq[source]
tri_update[source]
ntypes[source]
sec[source]
nnei[source]
edge_type_embedding[source]
gaussian_encoder[source]
backbone[source]
property dim_out[source]

Returns the output dimension of atomic representation.

property dim_in[source]

Returns the atomic input dimension of this descriptor.

property dim_emb[source]

Returns the output dimension of pair representation.

compute_input_stats(merged: List[dict], path: deepmd.utils.path.DPPath | None = None)[source]

Update mean and stddev for descriptor elements.

forward(extended_coord, nlist, atype, nlist_type, nlist_loc=None, atype_tebd=None, nlist_tebd=None, seq_input=None)[source]

Calculate the atomic and pair representations of this descriptor.

Args: - extended_coord: Copied atom coordinates with shape [nframes, nall, 3]. - nlist: Neighbor list with shape [nframes, nloc, nnei]. - atype: Atom type with shape [nframes, nloc]. - nlist_type: Atom type of neighbors with shape [nframes, nloc, nnei]. - nlist_loc: Local index of neighbor list with shape [nframes, nloc, nnei]. - atype_tebd: Atomic type embedding with shape [nframes, nloc, tebd_dim]. - nlist_tebd: Type embeddings of neighbor with shape [nframes, nloc, nnei, tebd_dim]. - seq_input: The sequential input from other descriptor with

shape [nframes, nloc, tebd_dim] or [nframes * nloc, 1 + nnei, tebd_dim]

Returns:
  • result: descriptor with shape [nframes, nloc, self.filter_neuron[-1] * self.axis_neuron].
  • ret: environment matrix with shape [nframes, nloc, self.neei, out_size]