San Francisco is a beautiful city with lots of great neighbourhoods for walking around. (I've been there quite a few times, and lived there once for 6 weeks).
If your hotel is east of Union Square, the area should be fine, as the Tenderloin starts about 4 blocks west of Union Square around...