tfjs-examples/custom-layer
..
README.md
cat.jpg
custom_layer.js
index.html
index.js
package.json
yarn.lock

README.md

TensorFlow.js Example: Custom Layer

This example demonstrates how to write a custom layer for tfjs-layers.

We build a custom activation layer called 'Antirectifier' which outputs two channels for each input, one with just the positive signal, and one with just the negative signal. The example shows exercises the call and computeOutputShape overrides of the Layer.

See this example live!