chainer_chemistry.models.WeaveNet

class chainer_chemistry.models.WeaveNet(weave_channels=None, hidden_dim=16, n_atom=20, n_sub_layer=1, n_atom_types=117, readout_mode='sum')[source]

WeaveNet implementation

Parameters:
  • weave_channels (list) – list of int, output dimension for each weave module
  • hidden_dim (int) – hidden dim
  • n_atom (int) – number of atom of input array
  • n_sub_layer (int) – number of layer for each AtomToPair, PairToAtom layer
  • n_atom_types (int) – number of atom id
  • readout_mode (str) – ‘sum’ or ‘max’ or ‘summax’
__init__(weave_channels=None, hidden_dim=16, n_atom=20, n_sub_layer=1, n_atom_types=117, readout_mode='sum')[source]

Initialize self. See help(type(self)) for accurate signature.

Methods

__init__([weave_channels, hidden_dim, …]) Initialize self.
add_link(name, link) Registers a child link to this chain.
add_param(name[, shape, dtype, initializer]) Registers a parameter to the link.
add_persistent(name, value) Registers a persistent value to the link.
addgrads(link) Accumulates gradient values from given link.
children() Returns a generator of all child links.
cleargrads() Clears all gradient arrays.
copy() Copies the link hierarchy to new one.
copyparams(link) Copies all parameters from given link.
disable_update() Disables update rules of all parameters under the link hierarchy.
enable_update() Enables update rules of all parameters under the link hierarchy.
init_scope() Creates an initialization scope.
links([skipself]) Returns a generator of all links under the hierarchy.
namedlinks([skipself]) Returns a generator of all (path, link) pairs under the hierarchy.
namedparams([include_uninit]) Returns a generator of all (path, param) pairs under the hierarchy.
params([include_uninit]) Returns a generator of all parameters under the link hierarchy.
register_persistent(name) Registers an attribute of a given name as a persistent value.
serialize(serializer) Serializes the link object.
to_cpu() Copies parameter variables and persistent values to CPU.
to_gpu([device]) Copies parameter variables and persistent values to GPU.
zerograds() Initializes all gradient arrays by zero.

Attributes

update_enabled True if at least one parameter has an update rule enabled.
within_init_scope True if the current code is inside of an initialization scope.
xp Array module for this link.