BigDL-Tutorials
BigDL-Tutorials copied to clipboard
Change the structure of notebooks directory.
sc.stop()
does the user need to restart the toree?
No. User does not need to restart Toree.
But user cannot use sc anymore in the notebook, right?
val trainSet =
DataSet.array(load(trainData, trainLabel), sc) -> BytesToGreyImg(28, 28) -> GreyImgNormalizer(trainMean, trainStd) -> GreyImgToBatch(batchSize)
val validationSet =
DataSet.array(load(validationData, validationLabel), sc) -> BytesToGreyImg(28, 28) -> GreyImgNormalizer(testMean, testStd) -> GreyImgToBatch(batchSize)
Please load the data as RDD format
//Parameters
val batchSize = 2048
val learningRate = 0.2
val maxEpochs = 15
//Network Parameters
val nInput = 784 //MNIST data input (img shape: 28*28)
val nClasses = 10 //MNIST total classes (0-9 digits)
why put this piece of code in the MNIST notebook?
Please remove the linear_regression and Logistic Regression notebooks. It's hard two review as github for notebook review is not easy to use. Let't put one notebook in one PR.
val trainData = "../datasets/mnist/train-images-idx3-ubyte"
val trainLabel = "../datasets/mnist/train-labels-idx1-ubyte"
val validationData = "../datasets/mnist/t10k-images-idx3-ubyte"
val validationLabel = "../datasets/mnist/t10k-labels-idx1-ubyte"
You need tell user put the data file in ../datasets/mnist/...
I think this is not user friendly, can you provide a utility to download the mnist dataset just like python notebook?
Yes. In this specific notebook. user cannot use sc any more. But when user switches to another notebook, it works normally.