Learn R Programming

ruta (version 1.2.0)

new_layer: Layer wrapper constructor

Description

Constructor function for layers. You shouldn't generally need to use this. Instead, consider using individual functions such as dense.

Usage

new_layer(cl, ...)

Value

A construct with class "ruta_layer"

Arguments

cl

Character string specifying class of layer (e.g. "ruta_layer_dense"), which will be used to call the corresponding methods

...

Other parameters (usually units, activation)

Examples

Run this code
my_layer <- new_layer("dense", 30, "tanh")

# Equivalent:
my_layer <- dense(30, "tanh")[[1]]

Run the code above in your browser using DataLab