Would you please read up on the kinds and degrees of relationships between perpetrator and victim in the statistics? You will find that the vast majority of cases involve two people who already have a prior relationship, and typically a close relationship either in a social or business sense.
Random murders happen so rarely, you can be confident in the assumption that your family is safe unless you get involved with some sketchy people. But then, it's your responsibility to avoid those people, not the city's job to do that work for you.
I will say that I have felt more uncomfortable walking in certain parts of LA, NYC, Oakland, Chicago, and yes SF (I lived SOMA in early '90s, before the boom), than I have in Mexican cities. (Not minimizing the carnage, if you live outside of the nice parts, I'm sure it's hell.)