UNPKG

@vladmandic/face-api

Version:

JavaScript module for Face Detection and Face Recognition Using Tensorflow/JS

8 lines 341 B
import * as tf from '@tensorflow/tfjs/dist/tf.es2017.js'; export function convLayer(x, params, padding = 'same', withRelu = false) { return tf.tidy(() => { const out = tf.add(tf.conv2d(x, params.filters, [1, 1], padding), params.bias); return withRelu ? tf.relu(out) : out; }); } //# sourceMappingURL=convLayer.js.map