I wouldn't diagnose people online, but something tells me you are showing some signs of depression? I know you can't see a t right now but please see your doctor.
Some girl especially the one that's not interested isn't going to save you. It could be that change of scenery will help you such as moving but there is no guarantee. When will you be done with school?
I can relate to being extremely preoccupied with the person. I was preoccupied with men couple of times in my life. It could get difficult. But it didn't interfere with my ability to study or work. But if this prevents you from succeeding in your career or even simply work, then something needs to happen to stop the obsession.
I am sorry you are struggling right now

Sent from my iPhone using Tapatalk