Picking the locks is breaking and entering, going through an open window is illegal trespass, assuming you don't have to move any parts of the window. At least where I live. It depends on whether or not you have to use even the slightest amount of force to gain access. It also depends on your intent to commit a crime inside. If I'm looking for you because I've found your toddler wandering around outside and I open an unlocked door to call out your name, it isn't a crime. I'm not sure what happens if I pick a locked door in that situation, getting pretty contrived now. But let's say I heard your kid crying inside that you'd abandoned, it wouldn't be a crime to pick the lock and rescue him/her.