Skip to content

Instantly share code, notes, and snippets.

View cvalenzuela's full-sized avatar
🦌

Cristóbal Valenzuela cvalenzuela

🦌
View GitHub Profile
classifier.train();
classifier.addImage(puffinImage1, 'Puffin');classifier.addImage(puffinImage1, 'Puffin');
classifier.addImage(puffinImage2, 'Puffin');classifier.addImage(puffinImage2, 'Puffin');
classifier.addImage(puffinImage3, 'Puffin');classifier.addImage(puffinImage3, 'Puffin');
classifier.addImage(snowLeopardImage1, ‘Snow Leopard’);classifier.addImage(snowLeopardImage1, ‘Snow Leopard’);
classifier.addImage(snowLeopardImage2, ‘Snow Leopard’);classifier.addImage(snowLeopardImage2, ‘Snow Leopard’);
const classifier = features.classification();
let features = ml5.featureExtractor('MobileNet');
classifier.predict(gotResult);
function gotResult(results) {
console.log(results);
}
let video = createCapture(VIDEO);
let classifier = ml5.imageClassifier('MobileNet', video);
let classifier = new ml5.ImageClassifier('MobileNet');
@cvalenzuela
cvalenzuela / .screenrc
Created November 6, 2017 00:14 — forked from joaopizani/.screenrc
A killer GNU Screen Config
# the following two lines give a two-line status, with the current window highlighted
hardstatus alwayslastline
hardstatus string '%{= kG}[%{G}%H%? %1`%?%{g}][%= %{= kw}%-w%{+b yk} %n*%t%?(%u)%? %{-}%+w %=%{g}][%{B}%m/%d %{W}%C%A%{g}]'
# huge scrollback buffer
defscrollback 5000
# no welcome message
startup_message off
@cvalenzuela
cvalenzuela / mixamoAnim.js
Created September 21, 2017 23:03 — forked from juniorxsound/mixamoAnim.js
Play a Mixamo exported animation with model (converted to JSON format) in three.js
var scene,
camera,
light,
renderer,
timer,
manager;
function init(){
manager = new THREE.LoadingManager();
//Don't start rendering until you finish loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.