tensor-safe-0.1.0.0: Create valid deep neural network architectures

Safe HaskellNone
LanguageHaskell2010

TensorSafe.Layer

Description

This module defines the Layer class from which all Layers should have instances of.

Synopsis

Documentation

type InputShape = Maybe String Source #

Auxiliary type for Input Shape parameter

class Layer x Source #

Defines that a type is a Layer Each layer can be compilated into a specific CNetwork expression which can later be used to generate code to a specific backend.

Minimal complete definition

compile, layer

Instances
Layer Flatten Source # 
Instance details

Defined in TensorSafe.Layers.Flatten

Layer Relu Source # 
Instance details

Defined in TensorSafe.Layers.Relu

Layer Sigmoid Source # 
Instance details

Defined in TensorSafe.Layers.Sigmoid

(KnownNat input, KnownNat output) => Layer (Dense input output) Source # 
Instance details

Defined in TensorSafe.Layers.Dense

Methods

layer :: Dense input output Source #

compile :: Dense input output -> InputShape -> CNetwork Source #

(KnownNat rate, KnownNat seed) => Layer (Dropout rate seed) Source # 
Instance details

Defined in TensorSafe.Layers.Dropout

Methods

layer :: Dropout rate seed Source #

compile :: Dropout rate seed -> InputShape -> CNetwork Source #

KnownNat units => Layer (LSTM units b) Source # 
Instance details

Defined in TensorSafe.Layers.LSTM

Methods

layer :: LSTM units b Source #

compile :: LSTM units b -> InputShape -> CNetwork Source #

ValidNetwork ls ss => Layer (INetwork ls ss) Source #

This instance of INetwork as a Layer makes possible nesting INetworks

Instance details

Defined in TensorSafe.Network

(KnownNat kernelRows, KnownNat kernelColumns, KnownNat strideRows, KnownNat strideColumns) => Layer (MaxPooling kernelRows kernelColumns strideRows strideColumns) Source # 
Instance details

Defined in TensorSafe.Layers.MaxPooling

Methods

layer :: MaxPooling kernelRows kernelColumns strideRows strideColumns Source #

compile :: MaxPooling kernelRows kernelColumns strideRows strideColumns -> InputShape -> CNetwork Source #

(KnownNat channels, KnownNat filters, KnownNat kernelRows, KnownNat kernelColumns, KnownNat strideRows, KnownNat strideColumns) => Layer (Conv2D channels filters kernelRows kernelColumns strideRows strideColumns) Source # 
Instance details

Defined in TensorSafe.Layers.Conv2D

Methods

layer :: Conv2D channels filters kernelRows kernelColumns strideRows strideColumns Source #

compile :: Conv2D channels filters kernelRows kernelColumns strideRows strideColumns -> InputShape -> CNetwork Source #

compile :: Layer x => x -> InputShape -> CNetwork Source #

Given the layer and a optional inputShape generates a CNetwork structure

layer :: Layer x => x Source #

The layer type