4 ms·
Wow, this is literally exactly what I was looking for. Thank you. Hopefully, it works well. From https://developer.clarifai.com/quick-start/ https://develope
by starik36 10y ago
Wow, this is literally exactly what I was looking for. Thank you. Hopefully, it works well.
From https://developer.clarifai.com/quick-start/ https://developer.clarifai.com/quick-start/
Seems simple to train
// add inputs with concepts
app.inputs.create([{
"url": "https://samples.clarifai.com/dog1.jpeg",
"concepts": [
{ "id": "cat", "value": false },
{ "id": "dog", "value": true }
]
}, {
"url": "https://samples.clarifai.com/dog2.jpeg",
"concepts": [
{ "id": "cat", "value": false },
{ "id": "dog", "value": true }
]
Then you predict what the another image is:
// predict the contents of an image by passing in a url
app.models.predict(Clarifai.GENERAL_MODEL,
'https://samples.clarifai.com/metro-north.jpg').then(
function(response) {
console.log(response);
},
function(err) {
console.error(err);
}
);