Base Layers¶
-
class
npdl.layers.Layer[source]¶ The
Layerclass represents a single layer of a neural network. It should be subclassed when implementing new types of layers.Because each layer can keep track of the layer(s) feeding into it, a network’s output
Layerinstance can double as a handle to the full network.-
connect_to(prev_layer)[source]¶ Propagates the given input through this layer (and only this layer).
Parameters: prev_layer : previous layer
The previous layer to propagate through this layer.
-
forward(input, *args, **kwargs)[source]¶ Calculate layer output for given input (forward propagation).
-