I would imagine that you're losing the stirrup because you're gripping with your knees/thighs or tipping forwards a bit, these are usually what cause not having enough weight in your legs.
If you have mobility probs (you'll have to excuse me if this isn't applicable to you) would it be worth having some lunge lessons so that you can focus on having the weight and balance in your seat? You could start by holding the front of the saddle then try just holding on with one etc, by balancing more with your seat the legs just follow suit. Unstable legs usually mean unstable seat.
again apologies if this isn't really applicable to your situation but I hope it helps