I'm wondering how to format the executeAsync tensorflow object detection executeAsync methods output so it look liks this:
My current output looks like this and is impossible to read just by browsing through:
I have been browsing through the coco-ssd.js, but for some reason it is written terribly. https://cdn.jsdelivr.net/npm/@tensorflow-models/coco-ssd of course this needs to be beautified, but after that, there is almost not a single variable called by its name, its basically the all letters in the alphabet.
This is how I get my prediction (unformated):
async function asyncCall() {
const modelUrl = 'http://192.168.0.14:8000/web_model_4/model.json';
const img = document.getElementById('img');
const imgTensor = tf.browser.fromPixels(img);
const t4d = imgTensor.expandDims(0);
const model = await tf.loadGraphModel(modelUrl).then(model => {
predictions = model.executeAsync(t4d, ['detection_classes']).then(predictions=> { //, 'detection_classes', 'detection_scores'
console.log('Predictions: ', predictions);
})
})
}
asyncCall();
Help is appreciated. I'm sure there are others having the problem training custom models with coco ssd. Thanks!