ModuleSpec

Usage

use ModuleSpec;

or

import ModuleSpec;
config const detach = true
var model : owned(Module(real(32))) = loadModel(specFile = "scripts/models/cnn/specification.json", weightsFolder = "scripts/models/cnn/", dtype = real(32))
config const numImages = 1
var images = forall i in 0..<numImages do Tensor.load("data/datasets/mnist/image_idx_" + i : string + ".chdata") : real(32)
var preds : [0..<numImages] int
config const numTimes = 1
var time : real
config const printResults = false