Mini Net Helper Module¶
Author: Cole Howard
Helper module to create or reinstantiate a neural network. Commented out code is for training the network via Scikit dataset or original MNIST dataset. The resulting network is then pickled and saved to a file. The current uncommented code is for reading that file and reinstantiating it for testing new input against.
-
mini_net.
run_mnist
(vector, epochs=0, layers=0, neuron_count=0)¶ Builds network (or reinstantiates it) based on the MNIST Digits dataset.
Parameters: - epochs (int) – Number of iterations of the the traininng loop for the whole dataset
- layers (int) – Number of layers (not counting the input layer, but does count output layer)
- neuron_count (list) – The number of neurons in each of the layers (in order), does not count the bias term
-
mini_net.
target_values
¶ list
The possible values for each training vector
-
mini_net.
run_scikit_digits
(vector, epochs=0, layers=0, neuron_count=[])¶ Builds network (or reinstantiates it) based on the Scikit Digits dataset.
Parameters: - epochs (int) – Number of iterations of the the traininng loop for the whole dataset
- layers (int) – Number of layers (not counting the input layer, but does count output layer)
- neuron_count (list) – The number of neurons in each of the layers (in order), does not count the bias term
-
mini_net.
target_values
list
The possible values for each training vector