Specifies the ndim, dtype and shape of every input to a layer.

Every layer should expose (if appropriate) an inputSpec attribute: a list of instances of InputSpec (one per input tensor).

A null entry in a shape is compatible with any dimension, a null shape is compatible with any shape.

Properties

axes?: {
    [axis: number]: number;
}

Dictionary mapping integer axes to a specific dimension value.

Type declaration

  • [axis: number]: number
dtype?: keyof DataTypeMap

Expected datatype of the input.

maxNDim?: number

Maximum rank of the input.

minNDim?: number

Minimum rank of the input.

ndim?: number

Expected rank of the input.

shape?: Shape

Expected shape of the input (may include null for unchecked axes).

Generated using TypeDoc