-
-
Notifications
You must be signed in to change notification settings - Fork 612
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Remove usage of global variables in linear and logistic regression tutorial training functions #2537
Conversation
Thanks! I'm in favour of 1, as I remember this being confusing. What the names should be I don't know, as having too many names for the same thing also gets messy. Probably Not sure about 2. It's a bit weird to put |
What about |
I'm not so worried about length, as about obscuring the relation between the locals and the globals. One idea is to call globals full words like |
I agreed with you until I started making the changes and realized that the globals are named that way to match with the mathematical definitions from the tutorial, so I think they should remain as-is and we change the custom training function arguments to be a slightly more verbose term that aligns with their definition. Coming from a CS background, seeing that See my latest commit and let me know what you think. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ok, good point about matching the equations. Then this is fine, I think.
Based off Slack "thread".
I think we should bikeshed the following:
return
to make it clear that no output is expected from thetrain_<something>!()
functions.Personally, I think we should definitely do 1., and probably do 2.