Google News
logo
ml5.js - Interview Questions
What are the Methods in ml5.NeuralNetwork?
method description
.addData() adds data to the neuralNetworkData.data.raw array
.normalizeData() normalizes the data stored in neuralNetworkData.data.raw and stores the normalized values in the neuralNetwork.data.training array
.train() uses the data in the neuralNetwork.data.training array to train your model
.predict() for regression tasks, allows you to make a prediction based on an input array or JSON object.
.predictMultiple() for regression tasks, allows you to make a prediction based on an input array of arrays or array of JSON objects.
.classify() for classification tasks, allows you to make a classification based on an input array or JSON object.
.classifyMultiple() for classification tasks, allows you to make classifications based on an input array of arrays or array of JSON objects.
.saveData() allows you to save your data out from the neuralNetworkData.data.raw array
.loadData() allows you to load data previously saved from the .saveData() function
.save() allows you to save the trained model
.load() allows you to load a trained model
Advertisement