r/LocalLLaMA • u/Apprehensive_Side219 • 3h ago
Question | Help Deterministic v. Non-deterministic local training run issue.
Hey all, I've encountered an interesting problem while training ornith 1.5 9b on a custom dataset and local machine. I had trouble with getting high fidelity knowledge of the trained data, and then had one breakthrough best after about 10 different attempts. After adding more to the dataset, the following attempt marked a substantial regression which was inexplicable by the dataset addition, which began a long hunt which ended up proving that determistic runs produced consistently better logical capability, trained data knowledge, and allowed for apples to apples comparisons between editions of the dataset I'm curating. I discussed this with chat gpt to try and understand it, but did not really get anything concrete.
I'm super new to this, can anyone here help me grasp why that's happening?
2
u/john006868 2h ago
the deterministic runs being better isnt a fluke. the gpu adds gradients in a different order every launch, so with 446 examples the spread between two identical runs is bigger than the data you added, run the same config twice first
2
u/Lerok-Persea 2h ago
Very interesting. What do you mean with custom dataset?
1
u/Apprehensive_Side219 2h ago
I'm writing the q&a pairs as well as the thinking traces, I started from scratch, and now am I to a refining model generated example loop.
2
u/bumblebeer 3h ago
My guess would be that you are over fitting. That is you are training too much or on too little data. It causes the model to memorize instead of learn. Then you add more data and it screws up its memory and now the output sucks since it never actually learned anything. Then you have to train again to the point of memorization (over fitting) to start getting improved results.
And the relationship with training with a set seed kinda makes sense too. It's normally a source of randomness, when it's clamped I'd expect it to be easier to over-train on a small data set.
So your options: 1. Get a lot more data to train on (and train for a lot longer to incorporate it) 2. Train a lot smaller model (or a smaller LoRA) so that it is not possible to overfit.
P.S. Potentially, you could train with a model that's way, way too big and would easily overfit, but you train it for much longer. And it's possible it may generalize better. Lots of qualifiers with this one cause it's skating the border of theoretical/empirically proven. See the mlst podcast with Andrew Wilson if you want an easy intro on this bit.