Coder Social home page Coder Social logo

pritomdas175's Projects

neural-network- icon neural-network-

implement a two-layer neural network (i.e. one hidden layer). You will use this network to perform handwritten digit recognition task using the Semeion digit dataset. This digit archive is available here: https://archive.ics.uci.edu/ml/datasets/Semeion+Handwritten+Digit Neural Network structure: Your NN (neural network) will have one hidden layer with n hidden units (n should be a parameter of your program function) and 10 output units. The network should be fully connected. Activation function: Hidden and output units should use the sigmoid activation function. Bias unit: Every hidden and output unit should have a weighted connection from bias unit, whose value should be set to 1. Output: The output units should correspond to one of 10 classes (1 to 9). Set the target value t k for output unit k to 0.9 if input class is the kth class, 0.1 otherwise. Training: Use backpropagation with SGD to train the network. Set the learning rate to 0.1. Question 1: Experiment with varying the number of hidden units. (Each sub- question below is worth 10 points = 50 points total) 1a. Conduct experiments with n = 20, 50 and 100. (Hint: remember to include bias unit weights). Train your network for 50 epochs. After each epoch, record your accuracy on training set AND test set for your network. After training is complete, create a confusion matrix for each of your trained networks, summarizing results on the test set. 1b. Give a plot of both training and test accuracy as a function of epoch number (graph both of these on sample plot). 1c. Discuss your results. How does number of hidden units affect the final accuracy on the test data? 1d. Discuss your results. How does number of hidden units affect number of epochs needed for training to converge? 1e. Is there any evidence that any of your networks overfit to the training data? If so, what is the evidence? Question 2: Experiment with varying the amount of training data. (Each subquestion below is worth 10 points = 50 points total) 2a. Conduct experiments by fixing your number of hidden units to 100. Instead of using all of the training examples, train two networks, using respectively one quarter and one half of the training examples for training. Make sure that in each case your training data is approximately balanced among the 10 different classes. Train your network for 50 epochs. After each epoch, record your accuracy on training set AND test set for your network. After training is complete, create a confusion matrix for each of your trained networks, summarizing results on the test set. 2b. Give a plot of both training and test accuracy as a function of epoch number (graph both of these on sample plot). 2c. Discuss your results. How does size of training data affect the final accuracy on the test data? 2d. Discuss your results. How does size of training data affect number of epochs needed for training to converge? 2e. Is there any evidence that any of your networks overfit to the training data? If so, what is the evidence?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.