My guess is you're putting out some vibe that losers are welcome. Unintentionally of course. I know in my past I kept finding myself in the same situation until I choose to learn from it. Maybe just don't give those losers any of your time then :)
Why do I keep running into guys like my ex? My ex from 3 years ago was emotionally abusive and lately I keep getting these creepy guys hitting on me who act just like them. I have no interest in these guys, I cut them off immediately.
You can't control the chance of meeting random people .. The world is filled with all kinds of personality types .. What you can control is how you react to them. Just keep weeding out the bad to find the good.
That type of guy looks for women who are insecure. They are easier to manipulate. So if you act shy and slouch a bit they will target you. If you stand up straight and look people in the eye and act confident in general, they will avoid you. Even if you don't feel confident, fake it. You will find people in general will treat you better overall by acting confident.
Believe it or not, you may be attracting these types to you somehow. You may be hanging around where these types hang out which will attract them to you so you may have to change some things in your life to meet a different class of guys and see what happens. Good luck