"Crazy housing prices and an insane homeless population"
Those are two facets of the same issue which is a demand much higher than the supply. SF has one of the best tech scenes in the world (to the point where it becomes stomach-churningly nauseating), and it's also just a hip metropolitan city with other thriving non-tech scenes.