I have studied self defense for years. Self defense isn't just about the fight.
Predators of strangers isn't the most common form of violence, the most common is a amoung people who know each other.
However vulnerable people can be picked out as targets (not necessarily just on the street).
If you find someone creepy that is no indication of if they are predatory. Often is this the most ordinary seeming people.
Body language can make a differnce, I know those from personal experience of being an easy target. If you are look like you are in your own world then you are fair game to these people.
Go to your destination with purpose, make sure you know where you are going and people you know have some idea where you are Be aware of what is around you, fear can make you loose sight of that, focus more on the outside and less on the inside. If you are freaking out you have reverted to being in your own thought and not focusing on the external.
Don't wear anything that limits you peripheral vision like a hoody, don't use anything that limits you senses like headphones. Keep your arm free and out of you pockets. Don't look down, anything that will improve you confidence will improve your body language. Don't try to be aggressive scan your environment in a smooth way, non-jumpy way.
Stick to street lighting and area with enough people, but not big crowds. Don't carry anything you don't need to take, if you don't need a handbag do take it. Walking in the middle of the sidewalk is best as you don't want to be too close to either side.
You wouldn't hold 400$ in you hands and look at it while you walking, so stay off your phone (people who play with their phones while walking are a pet hate of mine as they tend to walk into people or expect other to move for them becuase the deliberately don't look where they are going). However a full charge phone is important, just keep it out of sight.
Do no lean against walls. Be aware of entry/exit points. If you feel treatend by someone near you, make sure you a not facing away, put your arms up in front of you torso and face and not by your side or behind you back . There are way of doing this that don't appear aggressive/confrontational.
If you feel some is following don't continue in the same direction unless there is people there, think of a safe way to reach other people, shops, business, CCTV and lighting a such crossing a road where appropriate. It is generally better to see them then have them behind you although avoid directly confronting them unless you have no choice. It might be that you are just scare, however better safe that sorry.
There is a lot to self deference but that is a few tips.
Very few martial arts courses teach viable self defense, to the extent I can't really give specific recommendations as to where to go. The stuff I have been recently been working on knife defense based on evidence of the commonest types of lone attacks. These tend to involve to the other hand leading use as grabbing and using a concealed blade, and the repeatedly stabbing in quick succession. This is very different from how knife defense is usually taught, becuase it is not really based from expernce, they tend to feed the blade with not real intent in single action, which doesn't simulate the frenzied and uncooperative nature of an attack and the element of surprise. The focus was on control and attack, preservation, and how an when to get away. It was not focused on fancy disarms and takedowns. Also the recent terrorist attack use large mele style weapons and vehicles, in a well planned attack with multiple people that is whole other level.
Using martial arts for self defense is a life long thing you need broad expernce. However it can help you build confidence as you learn, which can be quite useful in a lot of ways.
having said that, this sort of violence isn't a common as people perceive. It is well knwo that perception of crime is often worse than the reality, especial in a developed country. However you should not be complacent.