Week 4 Assignment 1: Neural Network Class

Outcomes for this assignment mention implementing a neural network class, but I didn’t see that we made any classes, just functions. Am I misunderstanding?

1 Like

Thanks for the question. I just looked at the notebook and I hadn’t noticed the comments that you are referring to. You’re right: the notebook just builds a suite of functions, but does not actually construct a real “class”. Python is an OO language, but you don’t have to take advantage of those features.

I’ll make a note of this to the course developers.

Ok, no worries. Thanks Paul.

This is true. It is also true that the student-generated code used throughout these classes is not expected to take advantage of those features. Or many other features of well engineered production-ready software. Exception handling comes to mind. It seems the content developers generally went for simplicity, choosing to focus on the Deep Learning ideas. It is these ideas that we should take away from the exercises, not the manner in which they were implemented into code. NOTE @Aaron_Childress : lots of things taught early in the Specialization are implemented as Classes in the libraries and frameworks used later on (eg TensorFlow and Keras) though you will only be asked to write purely function-based code that uses them and not define new classes yourself.