r/learnmachinelearning • • 1d ago

Day one of learning ML

Any advice.

226 Upvotes

18 comments sorted by

45

u/om_nama_shiva_31 1d ago

Your lines 11 and 12 aren’t doing anything. In your line 14, you’re probably wanting to use weights instead of neuron_weights. But the weights variable is a list of lists, so you need a way to handle that. You’re also mixing up the concept of layer and neuron.

3

u/Fearless-Quote-7019 1d ago

Thank you 😊 🙏 very much

104

u/Graylian 1d ago

Print screen

38

u/Sisyphus0609 1d ago

You might wanna get your python fundamentals right. Just the basics. Also, its worth it to learn numpy and implement the matrix representation of NN

6

u/IDoCodingStuffs 1d ago

+1 on Numpy, also some linear algebra refreshers. You really don't want to use Python for loops to do computation outside control flows with short lists

4

u/jmacey 1d ago

+2 :-) first thing I thought when I saw the code. This is the marimo notebook I give my students. https://molab.marimo.io/github/github.com/NCCA/SEForMedia/blob/main/Neuron/NNFromScratchSlides.py If you run and view as slides they are interactive and you can have a play with a simple nextwork.

8

u/Neither_Adeptness784 1d ago

show me day 1000

7

u/Pitiful_Tough6412 1d ago

Use .ipynb files in vs code.

5

u/Bye_Todd 1d ago

Welcome to the party

4

u/CallMeTheChris 1d ago

Your second zip isn’t doing what you think it is doing

2

u/captain_obvious_here 22h ago • Bravo

I'd get a bit more Python experience, and then play with Numpy and Pandas, before going deeper into ML.

Have fun!

4

u/vmathematicallysexy 1d ago

From implementing ML algos the biggest lesson I've taken away is that it's like 2% programming and 98% understanding mathematically and conceptually what is actually happening. Getting the code to run without errors is easy, the important part is understanding exactly what just happened, why the output is what it is, and understanding exactly why you chose the model you did

5

u/RareMuffin2278 1d ago

I understand what you mean, but this is not true. Bugs in the program are still serious killers of good intentions. The programming is not trivial to get right in certain scenarios. I agree with your broader point that knowing the underlying mathematics is important, but not 98% to 2%.

3

u/vmathematicallysexy 1d ago

I'm a bit new to it with a very strong math background, so totally willing to accept I'm wrong. Thanks for the added context!

2

u/kbr89 1d ago

Day one is a good time to decide what the first month looks like, because the common way to stall is collecting courses instead of finishing one. Others here already covered Python and NumPy, so here is what I'd add:

  1. Pick one course and finish it. Practical Deep Learning from fastai is free and has you building things from the first lesson; if you'd rather start from the theory, Andrew Ng's machine learning course is the usual first one. StatQuest on YouTube is good for the moments when a concept doesn't click.
  2. After each topic, train a small model on a real dataset yourself, starting from an empty file. Linear regression on house prices, then a classifier, then something with images. The bugs you hit there teach more than the next video.
  3. Keep a short notes file: for each model, what it assumes and when it fails. That's the page you'll reread later, much faster than rewatching.

I built beyondtube (beyondtube dot pro) for the video part: it pulls lecture videos on one topic from several YouTube channels into one place, so you can ask questions across them and see which video each answer comes from.

What's your background so far, more programming or more maths? The order shifts a bit depending on which one you already have.

1

u/mfranzwa 18h ago

great! keep doing this every day

1

u/tryna_be_bookworm 1d ago

Never knew you could make simple code very appealing just by naming the variables smartly😆

1

u/israelavila 22h ago

Welcome to this journey. 👍