Upgrade to Pro — share decks privately, control downloads, hide ads and more …

JGS594 Lecture 05

JGS594 Lecture 05

Software Engineering for Machine Learning
Coding
(202201)

Javier Gonzalez-Sanchez

January 27, 2022
Tweet

More Decks by Javier Gonzalez-Sanchez

Other Decks in Programming

Transcript

  1. jgs SER 594 Software Engineering for Machine Learning Lecture 05:

    Assignment 01 Dr. Javier Gonzalez-Sanchez [email protected] javiergs.engineering.asu.edu | javiergs.com PERALTA 230U Office Hours: By appointment
  2. Javier Gonzalez-Sanchez | SER 594 | Spring 2022 | 5

    jgs Code https://github.com/javiergs/Medium/blob/main/NeuralNetwork/BasicNeuralNetwork.java
  3. Javier Gonzalez-Sanchez | SER 594 | Spring 2022 | 10

    jgs Backward Forward Propagation Error Forward Propagation Error Forward Propagation Error Main Forward Propagation Error MSE 10,000 times Backward Backward Backward Propagation
  4. Javier Gonzalez-Sanchez | SER 594 | Spring 2022 | 13

    jgs Backward Propagation (Part 1 of 2)
  5. Javier Gonzalez-Sanchez | SER 594 | Spring 2022 | 14

    jgs Backward Propagation (Part 2 of 2)
  6. Javier Gonzalez-Sanchez | SER 594 | Spring 2022 | 16

    jgs Instructions § Use the code from https://github.com/javiergs/Medium/blob/main/NeuralNetwork/BasicNeuralNetwork.java § Write a paper addressing the following questions
  7. Javier Gonzalez-Sanchez | SER 594 | Spring 2022 | 17

    jgs Questions 1. Can you reuse that code and train a neural network for identifying AND operator? What is the Error after 10,000 iterations of training? 2. Can you reuse that code and train a neural network for identifying OR operator? What is the Error after 10,000 iterations of training? 3. Compare with the provided error for XOR. Explain the difference or similarities
  8. Javier Gonzalez-Sanchez | SER 594 | Spring 2022 | 18

    jgs Questions For the error calculation. You will notice this code meanSquareError += Math.pow (err, 2)/2; double err1 = meanSquareError / (network.nodesOutputLayer+network.nodesHiddenLayer-1); 4. Is there a problem there? 5. Could you identify and explain or fix?
  9. Javier Gonzalez-Sanchez | SER 594 | Spring 2022 | 19

    jgs Questions 6. What is the size of the array arrayBias? Is that, OK? Should it or Could it Be smaller? If so, can you fix the code? It is worthy to make it smaller.
  10. Javier Gonzalez-Sanchez | SER 594 | Spring 2022 | 20

    jgs Questions 7. Plot the values of the eight W values Describe/notice how they change.
  11. Javier Gonzalez-Sanchez | SER 594 | Spring 2022 | 21

    jgs Questions 8. Express the source code from lines 64 to 75 as an equation using the names on the picture 9. Express the source code from lines 77 to 88 as equations using the names on the picture 10. Express the source code from lines 90 to 93 as equations using the names on the picture
  12. Javier Gonzalez-Sanchez | SER 594 | Spring 2022 | 22

    jgs Extra If you are familiar with derivatives, § Can you explain the equations from the previous question (where they come from) Hints: o derivative of sigmoid function; o partial derivative of error function with respect to Wi o Derivative of a constant o Derivative of (Ax + Bx + Cx + …)
  13. jgs SER 594 Software Engineering for Machine Learning Javier Gonzalez-Sanchez,

    Ph.D. [email protected] Spring 2022 Copyright. These slides can only be used as study material for the class CSE205 at Arizona State University. They cannot be distributed or used for another purpose.