rdkit.ML.Neural.NetNode module — The RDKit 2016.09.1 documentation

# rdkit.ML.Neural.NetNode module

Contains the class _NetNode_ which is used to represent nodes in neural nets

Network Architecture:

> A tacit assumption in all of this stuff is that we’re dealing with feedforward networks.

> The network itself is stored as a list of _NetNode_ objects. The list is ordered in the sense that nodes in earlier/later layers than a given node are guaranteed to come before/after that node in the list. This way we can easily generate the values of each node by moving sequentially through the list, we’re guaranteed that every input for a node has already been filled in.

> Each node stores a list (_inputNodes_) of indices of its inputs in the main node list.

class `rdkit.ML.Neural.NetNode.` `NetNode`(nodeIndex, nodeList, inputNodes=None, weights=None, actFunc=<class 'rdkit.ML.Neural.ActFuncs.Sigmoid'>, actFuncParms=())

  Bases: `object`

  a node in a neural network

  `Eval`(valVect)

    Given a set of inputs (valVect), returns the output of this node

    Arguments

    > - valVect: a list of inputs

    Returns

    > the result of running the values in valVect through this node

  `GetInputs`()

    returns the input list

  `GetWeights`()

    returns the weight list

  `SetInputs`(inputNodes)

    Sets the input list

    Arguments

    > - inputNodes: a list of _NetNode_s which are to be used as inputs

    Note

    > If this _NetNode_ already has weights set and _inputNodes_ is a different length, this will bomb out with an assertion.

  `SetWeights`(weights)

    Sets the weight list

    Arguments

    > - weights: a list of values which are to be used as weights

    Note

    > If this _NetNode_ already has _inputNodes_ and _weights_ is a different length, this will bomb out with an assertion.