Part 1.
Write the pattern file
The pattern file is what the program uses to train the network. To create this file, you need to
encode the input and output, and then put the data into a format that the program can
analyze.
a. Encode the input (the seven segment display) in a binary format that the program
can recognize. This can be done many ways, but I suggest making a seven-element
vector with each index representing one location in the display.
b. Encode the output in a binary format. Since the program requires binary input and
output, the values need to be converted into binary. Again, any mapping would work
here, but I suggest using the ASCII values for each character. In general, you can look
these up in an ASCII table, but for this assignment, the relevant codes are listed
below.
c. Create a text file to use for training the network. This file should be in the
following format:
Number of patterns = 17
Number of inputs = 7
Number of outputs = 7
[patterns]
1111110 0110000
0110000 0110001
1101101 0110010
1111001 0110011
0110011 0110100
1011011 0110101
1011111 0110110
1110000 0110111
1111111 0111000
1111011 0111001
1110111 1000001
0011111 1000010
1001110 1000011
0111101 1000100
1001111 1000101
1000111 1000110
0110111 1001000
Part 2. Create the network
a. Configure the network by going to the Network menu and choosing Configure
Network from the list of options
b. Train the network by loading in your pattern file. This can be done by going to the
Patterns dropdown menu and choosing Load Patterns. Then choose the file that you
created from part 1.
The number of training steps
c. Test the model by choosing individual patterns and Clicking the Test One button.
All pattern where tested and approved
The image above is from my first trial whie the image below is from my second trial
Following the initial training with 5000 learning steps, the average error per pattern was found
to be 0.10384692870724645, which is considered acceptable but not optimal. Subsequently, I
conducted three additional training runs, each with a total of 20000 learning steps, resulting in
a reduced error of 0.03875318548874641. Further training with 50000 steps decreased the
error to 0.022835189551045278. This level of error is satisfactory.