Example - MNIST Softmax Classifier.ipynb
.mnist_softmax.dml
mnist_softmax-train.dml
mnist_softmax-predict.dml
Example - MNIST LeNet.ipynb
.mnist_lenet.dml
mnist_lenet-train.dml
mnist_lenet-predict.dml
To run the examples, please first download and unzip the project via GitHub using the “Clone or download” button on the homepage of the project, or via the following commands:
git clone https://github.com/dusenberrymw/systemml-nn.git
Then, move into the systemml-nn
folder via:
cd systemml-nn
get_mnist_data.sh
to download the data separately.These examples contain scripts written in SystemDS's R-like language (*.dml
), as well as PySpark Jupyter notebooks (*.ipynb
). The scripts contain the math for the algorithms, enclosed in functions, and the notebooks serve as full, end-to-end examples of reading in data, training models using the functions within the scripts, and evaluating final performance.
Notebooks: To run the notebook examples, please install the SystemDS Python package with pip install systemds
, and then startup Jupyter in the following manner from this directory (or for more information, please see this great blog post):
PYSPARK_DRIVER_PYTHON=jupyter PYSPARK_DRIVER_PYTHON_OPTS="notebook" pyspark --master local[*] --driver-memory 3G --driver-class-path SystemDS.jar --jars SystemDS.jar
Note that all printed output, such as training statistics, from the SystemDS scripts will be sent to the terminal in which Jupyter was started (for now...).
Scripts: To run the scripts from the command line using spark-submit
, please see the comments located at the top of the -train
and -predict
scripts.