Options
All
  • Public
  • Public/Protected
  • All
Menu

Class Layer

Parent class for layers.

Hierarchy

Index

Constructors

Protected constructor

  • new Layer(outputSize: number): Layer

Properties

Readonly connections

connections: Connection[]

All connections in this layer.

Readonly gates

gates: Connection[]

All gates in this layer.

Readonly inputNodes

inputNodes: Set<Node>

The nodes which gets connected to the previous layer.

Readonly nodes

nodes: Node[]

All nodes in this layer.

outputNodes

outputNodes: Set<Node>

The nodes which gets connected to the next layer.

Readonly outputSize

outputSize: number

The output size of the layer.

Methods

Abstract connectionTypeisAllowed

Abstract getDefaultIncomingConnectionType

Static connect

  • Connect two layers or sets of nodes.

    Parameters

    • from: Layer | Set<Node> | Node[]

      origin nodes / Layer

    • to: Layer | Set<Node> | Node[]

      destination nodes / Layer

    • Default value connectionType: ConnectionType = ConnectionType.ALL_TO_ALL

      The type of connection

    • Default value weight: number = 1

      the initial weights for all new connections

    Returns Connection[]

    all created connections

Static gate

Generated using TypeDoc