I'd say it's one of the safer mayor citiew I've been, given that you stay in the touristy parts. Centro histórico, La Condesa, Roma, Polanco and similar. Worst thing that happened to me there was when me and some friends were wasted and cops tried to shake us down, but we told them to fuck off and they did.