Skip to content

Running MaTEx TensorFlow (Old)

Charles Siegel edited this page Mar 28, 2017 · 1 revision

Examples

The following examples show how to train LeNet-3 with MNIST, a convolution network for CIFAR10 respectively, and to train from a dataset.csv file:

mpirun -n 2 python mpi-tensorflow.py --data MNIST --conv_layers 20 50 --full_layers 500 --epochs 13 --train_batch 32

mpirun -n 2 python mpi-tensorflow.py --data CIFAR10 --conv_layers 32 32 64 --full_layers 64 --epochs 12 --train_batch 32

mpirun -n 2 python mpi-tensorflow.py --data CSV --filename dataset.csv --full_layers 500 400 300 --epochs 30 --train_batch 32

By default, the script downloads the MNIST dataset automatically and executes 30 epochs for training using a single hidden layer of 30 neurons:

mpirun -n 2 python mpi-tensorflow.py

The first time the MNIST, CIFAR10, or CIFAR100 datasets are used, they will be downloaded. Subsequent runs will reuse the downloaded data and only extract it.

User-specified data is given by the --data CSV and --data PNETCDF command-line parameters. CSV also requires --filename <file.csv> where is a CSV file with the class label in the first column. It will be partitioned into a training, validation and testing set using --valid_pct and --test_pct, respectively. PNetCDF requires --filename <file1.nc> and --filename2 <file2.nc> where and are NetCDF files corresponding to training and testing data, respectively.

Clone this wiki locally