During the day I do not think you will encounter any problems or dangers. But I would be cautions at night time, ecpesially after dark and on the weekends. Oslo has one of the highest rates of rape of women in Western Europe. These are usually violant attacks by random strangers.

For me, there are certain no-go areas of the city (after dark, at night time). These are along the Akerselva, Grønland, Tøyen, Sofienbergparken, the lower parts of Grunerløkka and the lower parts of Karl Johans gate (close to the central station). I would not go here on my own at night time, even when 100 % sober.

You will probaly encounter many people who will tell you that Oslo is perfectly safe, as it is for most of the time, by Oslo also has got a serious problem with sexual violence towards women compared to the other Nordic countries, and also Western Europe.

Take precautions, stay in well lit up areas, avoid the parks, only ever take registered taxis and make sure you tell them exactly where to go. Both several of my friends (females) and myself have experienced "unpleasant" attention and threats from taxi drivers, and if you do not speak Norwegian or appear not to know the city the trip will be much more expensive than it should be.

Public transport also runs into the night, some bus lines running through the night.

http://ruter.no/en/