| 25 | let tf; |
| 26 | |
| 27 | function parseArgs() { |
| 28 | const parser = new argparse.ArgumentParser({ |
| 29 | description: 'TensorFlow.js Quantization Example: Training an MLP for the ' + |
| 30 | 'California Housing Price dataset.', |
| 31 | addHelp: true |
| 32 | }); |
| 33 | parser.addArgument('modelSavePath', { |
| 34 | type: 'string', |
| 35 | help: 'Path at which the model to be evaluated is saved.' |
| 36 | }); |
| 37 | parser.addArgument('--gpu', { |
| 38 | action: 'storeTrue', |
| 39 | help: 'Use tfjs-node-gpu for training (requires CUDA-enabled ' + |
| 40 | 'GPU and supporting drivers and libraries.' |
| 41 | }); |
| 42 | return parser.parseArgs(); |
| 43 | } |
| 44 | |
| 45 | async function main() { |
| 46 | const args = parseArgs(); |