annotated-Module20Assignment-1

pdf

School

Rice University *

*We aren’t endorsed by this school

Course

642

Subject

Computer Science

Date

Feb 20, 2024

Type

pdf

Pages

2

Uploaded by BailiffWillpower14432

Report
On my honor, I have neither given nor received any unauthorized aid on this Assignment. - Daniel Leeds Daniel Leeds COMP 642 Module 8 Assignment 1. (4*5)+(5*3)+3 = 20+15+3 = 38 2. I completed the prescribed steps and included my .ipynb files with my submission. 3. I completed the prescribed steps and included my .ipynb files with my submission. There was an error I was getting in the Solver.py portion of the hw_8_updated code. All of my methods return the expected output and my class implementations work. I also went to office hours regarding this issue and there was no problem found with my code. After working examining optim.py and the error I was getting, I made a simple change and no longer get the error. In optim.py there is a line of code “theta -= config['learning_rate'] * dtheta”. I split this into two steps: test = theta - (config['learning_rate'] * dtheta) and theta = test. This solved the problem I was running into! a. Question 1: With hyperparameter tuning, I discovered using the Adam optimizer with a value of 0.0001 performed better than larger and smaller values ranging from 0.001 to 0.00001. After trying a large variety of activation functions for my hidden layers, I found a linear activation function for the first hidden layer and gelu activation for the two following hidden layers to have the best performance. I also tested different dropout values, and found a dropout value of 0.25 works best.There is variability in performance as the data set is split differently and we measure after a small number of epochs. Resources: Multi-Layer Perceptrons Explained and Illustrated | by Dr. Roi Yehoshua | Towards Data Science Multilayer Perceptron Explained with a Real-Life Example and Python Code: Sentiment Analysis | by Carolina Bento | Towards Data Science Understanding Backpropagation Algorithm | by Simeon Kostadinov | Towards Data Science From Basic Gates to Deep Neural Networks: The Definitive Perceptron Tutorial | by Joseph Robinson, Ph.D. | Towards Data Science Neural Networks: Forward pass and Backpropagation | by Ritwick Roy | Towards Data Science Gradient Descent Algorithm — a deep dive | by Robert Kwiatkowski | Towards Data Science
A Comprehensive Guide to the Backpropagation Algorithm in Neural Networks (neptune.ai) numpy.reshape — NumPy v1.26 Manual numpy.linspace — NumPy v1.26 Manual numpy.prod — NumPy v1.26 Manual numpy.random.normal — NumPy v1.26 Manual numpy.matmul — NumPy v1.26 Manual tf.keras.Sequential | TensorFlow v2.14.0
Your preview ends here
Eager to read complete document? Join bartleby learn and gain access to the full version
  • Access to all documents
  • Unlimited textbook solutions
  • 24/7 expert homework help