Me too, I've spent a fair amount of time either living adjacent to or walking through hoods like this. Not a single problem, although when I shared a loft with a bunch of people, literally everyone else but me got mugged, or even robbed at gun or knife point, and I had to visit one of my loftmates in the ER because he got stabbed (this was not the only time and it was because whenever anyone tried to mug him he just told them to fuck off and kept walking).
And I don't look particularly intimidating so it's not like I have some magic badassery that scares off thugs.
Main tips, walk fast. Look like you know where you're going, even if you don't. Better yet, do know exactly where you're going at all times. The predators are looking for people who are lost and confused. Given a choice, they'll pick someone else. It's sort of like silly things like The Club for cars. Experienced car thieves can get past one of those in a couple minutes, but why would they bother when there's a car one space over without one?
Another. There are places in every city with any degree of urban decay you shouldn't even be going in daylight. Stay out of them, period. If you got street smarts, use them. If not, look at the crime maps. Are there a few bits in this nice city you just moved to that are nothing but red? Stay the FUCK out of those places. One of my law school profs was giving a tour of the general neighborhood around the school and just bluntly said, while pointing: "The further you go that way, the dumber you are." He was pointing at a particularly, shall we say, "urban" area, where people often got shot in broad daylight for no reason at all.
Another. Pay attention. Pay attention to who is paying attention to you, too. If you're in a ghetto type area, if you just flip out any time you see a black guy, you're going to live a life of paranoia. So don't do that. In most urban environments, any time you see someone, you can see they're up to something. They're moving something. They're buying something. They're selling something. (And if it's drugs ignore that shit it is none of your goddamn business.)
But sometimes, someone, or more than one someone, aren't doing something you can figure out. Sometimes, their attention appears to be on you. At that point, you tap the fuck out, and absolutely avoid those people. This is not a time to pretend to be a hero, or to pretend you aren't a racist by walking into a situation where you're getting stomped. You just dodge that, abandon any plans you had, and usually, this just involves walking briskly back to a safe part of town and taking the longer way home.
This is my chickenshit pussy white boy guide to how to deal with the hood without getting your ass kicked, or stabbed, or shot, unlike the rest of the idiots you know who did get their asses kicked, or stabbed, or shot. Thanks for attending my TED talk.