• Join over 1.2 million students every month
  • Accelerate your learning by 29%
  • Unlimited access from just £6.99 per month

A C++ Neural Network that Learns to Recognise Diagrams

Extracts from this document...

Introduction

Biomimetics Assignment 2:

A C++ Neural Network that Learns to Recognise Diagrams

Author: Daniel Rose                                                Date: 4/12/02

F. A. O: Dr A. Bowyer

Summary

An investigation was carried out to ascertain the usefulness of Artificial Neural Networks.  A program written in C++ was used to model a simple feed forward back propagation network.  Experiments were carried out to test the systems ability to cope with noise, the effect of training it more than once on a particular set of noise levels, and the ability to recognise different patterns.  The network performed well on data at moderate noise levels and was not really affected much by the amount of training it received, as long as it received some. It proved very good at recognising different patterns; there is no reason why it can’t be trained to recognise any pattern at all.

Introduction

An investigation has been carried out on the usefulness of Neural Networks.  Only one particular network has been studied, which was modelled in the C++ programming language by Daniel Franklin; it is used to recognise diagrams or patterns.  The network is known as a three layer back propagation type; the meaning of this is explained later.  As part of the investigation, the network was trained, using a random noise generating function to vary the pattern slightly each time.

...read more.

Middle

                  {

                                set_stripes(j);

                                noise(n);

                                if(recognize()==j) total++;

                  }

          }

          return(total/300.0);

        }

The function success_graph uses the how_successful function to obtain results for a range of noise levels (currently between 0 and 100) which are outputted to a file:

void success_graph()

{

        ofstream grf("graph.dat");

                for (int n=0;n<100;n++)

                {

                        float hs=how_successful(n);

                        grf<<n<<","<<hs<<endl;

                }

}

The network was initially trained on perfect data (i.e. with a noise level of zero).  A graph of the results was plotted and analysed, then the network was trained with noise, plotting graphs for each noise level tested.

  1. The second stage was to change the program to produce a series of results automatically for different amounts of training.  Another function was added to achieve this:

void autotraining()

{

        ofstream grf("graph.dat");

          for (int i=0;i<10;i++)

          {

                  success_graph(grf);

                  loop_train(i);

          }

          grf.close();

}

The number of times the neural network was trained was varied from nothing to nine times.

A section was taken out of loop_train, as the input of data from the user becomes unnecessary.

  1. Lastly the program was altered to read in some patterns from a file.  Two pattern files were created, representing the digits 0 and 1.
...read more.

Conclusion

Conclusion

Artificial Neural Networks are generally very good at recognising patterns.  A network can be trained with a relatively small amount of data to recognise patterns which have quite a large amount of noise.  It starts to get worse at a noise level of 20.  The network can recognise noisy images, even if the training patterns do not include any noise at all, demonstrating the systems inherent robustness.  If the network is trained on slightly noisy data its performance will slightly improve.  If it is trained on very noisy data its performance gets worse because the images no longer represent the original pattern, so the network I trying to recognise something that isn’t there.  The more times you train a network up to a particular noise level, the better it gets.  It is almost pointless in training this network more than twice on a set of noise levels because it hardly gets any better after that.  The network can recognise different patterns, it had no problem recognising the digits 1 and 0, and there is no reason why it couldn’t be trained to recognise any image.

References

  1. Evans, D (2002). Introduction to Artificial Neural Networks. (Lecture Notes).
  1. http://www.generation5.org/perceptron.shtml

...read more.

This student written piece of work is one of many that can be found in our University Degree Computer Science section.

Found what you're looking for?

  • Start learning 29% faster today
  • 150,000+ documents available
  • Just £6.99 a month

Not the one? Search for your essay title...
  • Join over 1.2 million students every month
  • Accelerate your learning by 29%
  • Unlimited access from just £6.99 per month

See related essaysSee related essays

Related University Degree Computer Science essays

  1. The project explains various algorithms that are exercised to recognize the characters present on ...

    { max_difference = row_difference[x]; } else{} } for (int x = 0; x < total_row ; x++) { if ((max_difference - row_difference[x]) < 10) { new_row_no1[new_total_row] = row_no1[x]; new_row_no2[new_total_row] = row_no2[x]; new_total_row = new_total_row + 1 ; } else {} } //------------------------------------------------------------------------------------------------------- // till here plate processed, divided horizontally and

  2. Information systems development literature review. Since the 1960s Methodologies, Frameworks, Approaches and CASE ...

    Strengths: A brief outline of the seven stages involved within SSM was explained distinguishing why this framework was employed. This aspect assisted with my understanding of the framework and its purpose. The application of this framework relates to the motive behind its use within the case study, as restructuring and new user required are to be identified and implemented.

  1. Network report for Middlesex University. The current network design is a star topology with ...

    * Load Balancing - Load balancing allows the 'full' use of bandwidth with the presence of redundant paths and in some way, allows to effectively doubling the bandwidth. * Cost - This is an important factor when considering the design of any network as budgetary constraints are always present.

  2. Entering Compiling and Running C Programs ...

    /****************** *Problem Number 4* ****************** #include<stdio.h> void main() { int i; int s=0; clrscr(); i=1; do { s=s+i; i=i+1; }while(i<=25); printf("The Sum=%d\n",s); getch(); } Output of the program Modify the program to determine the Sum S==5+6+...........+20=? /****************** *Problem Number 4* ****************** #include<stdio.h> void main()

  1. IP network design

    For example, while wide area IP routing may not be particularly interesting to the school, it will certainly be interested in considering how it wishes to make use of e-mail and web services. Different choices in these areas will have a high impact on the level of effort that the

  2. Ubiquitous sensing spatial sensor networks

    It is a way of identifying an object using its identity code, thus making it easy for users to relate with its data pictures through a visual barcode. (David Ley 2007) Visual barcodes are found on product, business cards, advertising etc.

  1. So in order to understand what the main areas where organisation should be aware ...

    Other tools: Nmap and Hping6 are tools that support TCP Sweep, both for the Unix platform. An example with nmap: [root@mia /root] ./nmap -sP -PT80 192.168.2.0/24 TCP probe port is 80 Starting nmap V. 2.2-BETA4 by Fyodor (fyodor@dhp.com, www.insecure.org/nmap/) Host host1.MyDomain.com (192.168.2.0)

  2. Why has the operation of the WTO dispute settlement procedure become politically contentious?

    short history of the system."5 When two parties such as the US and the EU come together on opposite sides of a trade dispute they can prolong the proceedings by locking horns via legal bickering. When one party is determined enough not to agree to comply, there is only so much the DSB can do to enforce itself.

  • Over 160,000 pieces
    of student written work
  • Annotated by
    experienced teachers
  • Ideas and feedback to
    improve your own work