
448
Chapitre 11. Entraînement et déploiement à grande échelle de modèles TensorFlow
import * as tf from '@tensorflow/tfjs';
const model = await tf.loadLayersModel(
'https://example.com/tfjs/model.json');
const image = tf.fromPixels(webcamElement);
const prediction = model.predict(image);
De nouveau, pour rendre justice à ce sujet, il faudrait un livre complet. Si vous sou-
haitez en savoir plus sur TensorFlow.js, consultez l’ouvrage Practical Deep Learning for
Cloud, Mobile, and Edge (https://homl.info/tfjsbook) publié par Anirudh Koul, Siddha
Ganju et Meher Kasam aux éditions O’Reilly.
Nous allons voir à présent comment utiliser des GPU pour accélérer ...