jrsimuix commited on
Commit
c0a7224
1 Parent(s): e1ff6a2

export labels

Browse files
Files changed (1) hide show
  1. nodejs/generate_model.js +1 -0
nodejs/generate_model.js CHANGED
@@ -55,6 +55,7 @@ async function trainModel() {
55
 
56
  await model.fit(images, labels, { epochs: 5 });
57
  await model.save('file://./saved-model'); // Save in TensorFlow.js format
 
58
  console.log('Model saved as TensorFlow.js format');
59
  }
60
 
 
55
 
56
  await model.fit(images, labels, { epochs: 5 });
57
  await model.save('file://./saved-model'); // Save in TensorFlow.js format
58
+ fs.writeFileSync('./labelMap.json', JSON.stringify(dataset.labelMap));
59
  console.log('Model saved as TensorFlow.js format');
60
  }
61