Olympic athletes are visitors from other countries, representing those countries and often providing these countries with a major view into their host country. It reflects incredibly poorly on the host country when an Olympic athlete can be robbed, or in the case of a certain Grindr incident, have their privacy violated.
Olympic athletes should be responsible for their own safety when outside of the Olympic village. The amount of security personnel that would be necessary in order to provide each athlete additional safety is tremendous and expensive. As with spectators, athletes should be aware of their surroundings and ensure their own personal safety.
If the host country's crime rate are high, athletes need bodyguard or at least a guide to escort certain area (ex; nightclub). However, the money should be paid by the team because host country are paying enough for other security matter. Have some "fun" place in the village for those who cannot afford security.
Olympic athletes should be able to make their own choices. If they're concerned about their safety, they should hire security. If not, they shouldn't have to. Forcing them to have security seems like an overreaction, and a costly one, considering how many athletes there are at the Olympics. It would be expensive and difficult to have every athlete have security with them at all times outside of the village.