MCPcopy Create free account

hub / github.com/ml5js/ml5-library / functions

Functions1,175 in github.com/ml5js/ml5-library

↓ 65 callersFunctioncreateCanvas
(w, h)
examples/javascript/YOLO/YOLO_webcam/sketch.js:91
↓ 58 callersFunctioncallCallback
(promise, callback)
src/utils/callcallback.js:27
↓ 48 callersMethodclassify
* Assing `value` to a cluster. * @param {array || object} value
src/KMeans/index.js:137
↓ 46 callersMethoddispose
()
src/KNNClassifier/index.js:168
↓ 23 callersMethodaddData
* addData * @param {Array | Object} xInputs * @param {Array | Object} yInputs * @param {*} options
src/NeuralNetwork/index.js:173
↓ 23 callersMethodtrain
* Retrain the model with the provided images and labels using the * models original features as starting point. * @param {function} onProgres
src/FeatureExtractor/Mobilenet.js:267
↓ 21 callersMethoddetect
* .detect() - classifies multiple features by default * @param {*} optionsOrCallback * @param {*} configOrCallback * @param {*} cb
src/FaceApi/index.js:144
↓ 21 callersMethodgenerate
* Generate a random result. * @param {String} label - A label of the feature your want to generate * @param {function} callback - A function t
src/CVAE/index.js:54
↓ 21 callersMethodpredict
* Predict the next character based on the model's current state. * @param {number} temp * @param {function} callback - Optional. A function to b
src/CharRNN/index.js:247
↓ 18 callersFunctionloadImage
(imgPath, idx)
examples/javascript/ImageClassification/ImageClassification_MultipleImages/sketch.js:49
↓ 18 callersMethodnormalizeData
* normalizeData * @param {*} _dataRaw * @param {*} _meta
src/NeuralNetwork/index.js:287
↓ 12 callersMethodinfer
(input, endpoint)
src/FeatureExtractor/Mobilenet.js:558
↓ 12 callersFunctionisInstanceOfSupportedElement
(subject)
src/utils/imageUtilities.js:137
↓ 12 callersMethodload
* Load dataset, find initial centroids, and run model. * @param {string || array || object} dataset
src/KMeans/index.js:77
↓ 12 callersMethodtransfer
* Given an canvas element, applies image-to-image translation using the provided model. Returns an image. * @param {HTMLCanvasElement} inputElement
src/Pix2pix/index.js:46
↓ 11 callersFunctionmap
(n, start1, stop1, start2, stop2)
examples/javascript/PitchDetection/PitchDetection_Game/sketch.js:40
↓ 11 callersMethodsegment
(inputOrCallback, cb)
src/UNET/index.js:49
↓ 10 callersMethodclassifySync
* synchronous classify * @param {*} _input
src/NeuralNetwork/index.js:832
↓ 10 callersMethodspeak
(_phrase)
examples/javascript/KNNClassification/KNNClassification_VideoSound/sketch.js:31
↓ 9 callersMethodcheckUndefined
* Check if the given _param is undefined, otherwise return the _default * @param {*} _param * @param {*} _default
src/FaceApi/index.js:355
↓ 8 callersMethodaddExample
* Adding an example to a class. * @param {*} input - An example to add to the dataset, usually an activation from another model. * @param {numbe
src/KNNClassifier/index.js:31
↓ 8 callersMethodcheckP5
* This function will check if the p5 is in the environment * Either it is in the p5Instance mode OR it is in the window * @returns {boolean} if
src/utils/p5Utils.js:49
↓ 8 callersMethodclearAllLabels
()
src/KNNClassifier/index.js:120
↓ 8 callersMethodgetCountByLabel
* Get the example count for each label. It returns an object that maps class label to example count for each class. * @returns {Number}
src/KNNClassifier/index.js:129
↓ 8 callersMethodgetNumLabels
* It returns the total number of labels. * @returns {String}
src/KNNClassifier/index.js:164
↓ 7 callersMethodaddImage
* Adds a new image element to Mobilenet * @param {HTMLVideoElement || p5.Video || String} inputOrLabel * @param {String || function} labelOrCal
src/FeatureExtractor/Mobilenet.js:190
↓ 7 callersFunctionimgToTensor
(input, size = null)
src/utils/imageUtilities.js:125
↓ 7 callersMethodreset
* Reset the model state.
src/CharRNN/index.js:211
↓ 6 callersMethodclassify
(img, topk = 3)
src/ImageClassifier/darknet.js:84
↓ 6 callersMethodclearLabel
* Clear all examples in a label. * @param {number||number} labelIndex - The class index or label, a number or a string.
src/KNNClassifier/index.js:108
↓ 6 callersMethodconvLayer
(input, strides, relu, id)
src/StyleTransfer/index.js:82
↓ 6 callersMethoddispose
* dispose and release the memory for the model
src/NeuralNetwork/NeuralNetwork.js:280
↓ 6 callersFunctiondrawPart
(feature, closed)
examples/p5js/FaceApi/FaceApi_Video_Landmarks/sketch.js:86
↓ 6 callersFunctiondrawPart
(feature, closed)
examples/p5js/FaceApi/FaceApi_Video_Landmarks_LocalModels/sketch.js:90
↓ 6 callersFunctiondrawPart
(feature, closed)
examples/javascript/FaceApi/FaceApi_Video_Landmarks/sketch.js:91
↓ 6 callersFunctiondrawPart
(feature, closed)
examples/javascript/FaceApi/FaceApi_Video_Landmarks_LocalModels/sketch.js:94
↓ 6 callersMethodgetPitch
* Returns the pitch from the model attempting to predict the pitch. * @param {function} callback - Optional. A function to be called when the model
src/PitchDetection/index.js:129
↓ 6 callersFunctionsaveBlob
(data, name, type)
src/utils/io.js:8
↓ 5 callersFunctionaddClusterButton
(currentClusterCount)
examples/d3/KMeans/KMeans_GaussianClusterDemo/sketch.js:98
↓ 5 callersFunctionaddClusterButton
(eps, minPts = 3)
examples/d3/DBSCAN/DBSCAN_Cluster/sketch.js:104
↓ 5 callersMethodconvertToP5Image
* Returns a p5Image * @param {*} tfBrowserPixelImage
src/BodyPix/index.js:85
↓ 5 callersMethodcreateNetworkLayers
* add custom layers in options
src/NeuralNetwork/index.js:600
↓ 5 callersMethoddetect
* Detect objects that are in video, returns bounding box, label, and confidence scores * @param {HTMLVideoElement|HTMLImageElement|HTMLCanvasElemen
src/ObjectDetector/YOLO/index.js:96
↓ 5 callersMethoddispose
* dispose and release memory for a model
src/NeuralNetwork/index.js:1182
↓ 5 callersMethodmutate
()
examples/p5js/NeuralNetwork/NeuroEvolution_FlappyBird/bird.js:44
↓ 5 callersMethodnormalizeArray
(inputArray, options)
src/NeuralNetwork/NeuralNetworkData.js:387
↓ 5 callersMethodpredict
(inputOrCallback, cb)
src/FeatureExtractor/Mobilenet.js:408
↓ 5 callersMethodpredict
* Will be deprecated soon in favor of ".classify()" - does the same as .classify() * @param {HTMLImageElement | HTMLCanvasElement | object | functi
src/ImageClassifier/index.js:256
↓ 5 callersMethodresidualBlock
(input, id)
src/StyleTransfer/index.js:91
↓ 4 callersFunctionaddExample
(label)
examples/p5js/KNNClassification/KNNClassification_VideoSquare/sketch.js:53
↓ 4 callersFunctionaddExample
(label)
examples/javascript/KNNClassification/KNNClassification_VideoSquare/sketch.js:61
↓ 4 callersFunctionarray3DToImage
(tensor)
src/utils/imageUtilities.js:27
↓ 4 callersMethodblobToP5Image
* Convert Blob to P5.Image * @param {Blob} blob * Note: may want to reject instead of returning null. * @returns {Promise<p5.Image | null>}
src/utils/p5Utils.js:116
↓ 4 callersFunctioncreateExampleList
(_example, _sectionDiv, _sectionTitle, _exampleKey)
examples/assets/sketch.js:45
↓ 4 callersMethodfeed
* Feed a string of characters to the model state. * @param {String} inputSeed - A string to feed the charRNN model state. * @param {function} ca
src/CharRNN/index.js:281
↓ 4 callersMethodformatInputsForPredictionAll
* formatInputsForPredictionAll * @param {*} _input * @param {*} meta * @param {*} inputHeaders
src/NeuralNetwork/index.js:417
↓ 4 callersMethodgetVariableName
(id)
src/StyleTransfer/index.js:164
↓ 4 callersMethodisAbsoluteURL
(str)
src/DCGAN/index.js:146
↓ 4 callersFunctionmockFunction
src/utils/callcallback_test.js:17
↓ 4 callersMethodrawToBlob
* convert raw bytes to blob object * @param {number[] | Uint8ClampedArray | ArrayLike<number>} raws * @param {number} width * @param {number}
src/utils/p5Utils.js:93
↓ 4 callersMethodsave
* Download the whole dataset as a JSON file. It's useful for saving state. * @param {String} name - Optional. The name of the JSON file that will b
src/KNNClassifier/index.js:176
↓ 4 callersMethodsegmentWithParts
* Segments the image with partSegmentation * @param {HTMLImageElement | HTMLCanvasElement | object | function | number} optionsOrCallback -
src/BodyPix/index.js:231
↓ 4 callersMethodshow
()
examples/p5js/NeuralNetwork/NeuroEvolution_FlappyBird/pipe.js:26
↓ 3 callersFunctionaddExample
(label)
examples/p5js/KNNClassification/KNNClassification_Video/sketch.js:32
↓ 3 callersFunctionaddExample
(label)
examples/javascript/KNNClassification/KNNClassification_Video/sketch.js:40
↓ 3 callersMethodaddLayer
* addLayer * @param {*} options
src/NeuralNetwork/index.js:593
↓ 3 callersFunctionclassifyVideo
()
examples/javascript/ImageClassification/ImageClassification_VideoScavengerHunt/sketch.js:90
↓ 3 callersFunctionclearLabel
(label)
examples/p5js/KNNClassification/KNNClassification_Video/sketch.js:157
↓ 3 callersFunctionclearLabel
(label)
examples/javascript/KNNClassification/KNNClassification_Video/sketch.js:165
↓ 3 callersMethodcompile
* compile the model * @param {*} _options
src/NeuralNetwork/index.js:753
↓ 3 callersMethodconv2d
(inputCon, filterCon)
src/Pix2pix/index.js:141
↓ 3 callersMethodconvertToP5Image
(tfBrowserPixelImage)
src/UNET/index.js:87
↓ 3 callersMethodcreateMetadata
* create the metadata from the data * this covers: * 1. getting the datatype from the data * 2. getting the min and max from the data *
src/NeuralNetwork/NeuralNetworkData.js:77
↓ 3 callersFunctioncreateSections
(data)
examples/assets/sketch.js:66
↓ 3 callersMethodcrossover
* create a new neural network with crossover * @param {*} other
src/NeuralNetwork/index.js:1207
↓ 3 callersMethoddetectSingle
* .detecSinglet() - classifies a single feature with higher accuracy * @param {*} optionsOrCallback * @param {*} configOrCallback * @param {*
src/FaceApi/index.js:250
↓ 3 callersMethodfit
* Run K-Means algorithm.
src/KMeans/index.js:96
↓ 3 callersMethodformatInputsForPrediction
* format the inputs for prediction * this means applying onehot or normalization * so that the user can use original data units rather * than
src/NeuralNetwork/index.js:388
↓ 3 callersFunctionfreqToMidi
(f)
examples/javascript/PitchDetection/PitchDetection_Game/sketch.js:34
↓ 3 callersFunctiongetCanvas
()
src/ImageClassifier/index_test.js:33
↓ 3 callersFunctiongetImage
()
src/ImageClassifier/index_test.js:23
↓ 3 callersFunctiongetReferences
(_examplesRoot, _rootName, _webEditorURL = null)
scripts/update-examples-json.js:31
↓ 3 callersFunctionimageClassifier
(modelName, videoOrOptionsOrCallback, optionsOrCallback, cb)
src/ImageClassifier/index.js:261
↓ 3 callersMethodloadJSON
* loadJSON * @param {*} _dataUrlOrJson * @param {*} _inputLabelsArray * @param {*} _outputLabelsArray
src/NeuralNetwork/NeuralNetworkData.js:612
↓ 3 callersMethodloadVideo
* Copies the stream from the source video into a new video element. * The copied element is set to property `this.video` and is also returned by th
src/utils/Video.js:50
↓ 3 callersMethodprepareForTraining
* Prepare data for training by applying oneHot to raw * @param {*} dataRaw
src/NeuralNetwork/index.js:273
↓ 3 callersMethodsearchAndFormat
* search though the xInputs and format for adding to data.raws * @param {*} input
src/NeuralNetwork/index.js:327
↓ 3 callersMethodsinglePose
(inputOr, cb)
src/PoseNet/index.js:162
↓ 3 callersFunctiontransfer
()
examples/p5js/Pix2Pix/Pix2Pix_callback/sketch.js:89
↓ 3 callersFunctiontransfer
()
examples/javascript/Pix2Pix/Pix2Pix_callback/sketch.js:131
↓ 3 callersMethodunnormalizeValue
(value, min, max)
src/NeuralNetwork/NeuralNetworkUtils.js:24
↓ 3 callersMethodupdate
()
examples/p5js/NeuralNetwork/NeuroEvolution_FlappyBird/pipe.js:33
↓ 3 callersFunctionupdateCounts
()
examples/p5js/KNNClassification/KNNClassification_PoseNet/sketch.js:133
↓ 3 callersFunctionupdateCounts
()
examples/p5js/KNNClassification/KNNClassification_VideoSquare/sketch.js:158
↓ 3 callersFunctionupdateCounts
()
examples/p5js/KNNClassification/KNNClassification_Video/sketch.js:148
↓ 3 callersFunctionupdateCounts
()
examples/javascript/KNNClassification/KNNClassification_PoseNet/sketch.js:145
↓ 3 callersFunctionupdateCounts
()
examples/javascript/KNNClassification/KNNClassification_VideoSquare/sketch.js:166
↓ 3 callersFunctionupdateCounts
()
examples/javascript/KNNClassification/KNNClassification_Video/sketch.js:156
↓ 2 callersMethodaddDefaultLayers
* addDefaultLayers * @param {*} _task
src/NeuralNetwork/index.js:660
↓ 2 callersFunctionaddExample
(label)
examples/p5js/KNNClassification/KNNClassification_PoseNet/sketch.js:49
next →1–100 of 1,175, ranked by callers