Yeah the school I got kicked out of was a terrible place. The school I got transferred to afterwards opened my life up to a lot of new activities, I started exploring subjects outside of math/science like ceramics, met my first girlfriend etc. Well worth it after all was said and done.
No offense but this sounds like a nightmare. It also sounds like you did a fantastic job achieving accuracy despite the complexity of the system. That’s something to be proud of.
This is The Nightmare. Devs building systems they barely understand, complexity leaking all over the place, and someone inheriting that awful job of keeping it running without having made any bad decisions themselves.