Unfortunately sometimes there isn't much to do besides trying not to take it personally and not letting it get you down. It helps if your co-residents feel the same way so you have some support (this might be a challenge at a small program). Without sacrificing anonymity, can you be any more specific about what's going on?
I've been there. Remember that you are responsible for your behavior, not the co-resident's. Be careful not to let their behavior cause you to act in a way that is unprofessional. People that act this way may be doing so out of their own insecurity, although it can make you feel like you are the insecure one. Don't take their bait.
a lesson I learned from the military is to document serious things. Also talk to him/her and see what's up in private, because they've been acting differently. If anything they'll back off because you showed you cared to ask.