Girl talks to me, ignores me, and then talks to me again?

There's this girl. She used to be a bit flirty with me, etc... and then...

...2/3 weeks later, she started ignoring me progressively. She would just greet me by the nickname she gave me a few months ago (just to point out, she gave nicknames to other guys, so the nickname doesn't mean much). Then a few days later, she straight up started ignoring my existence.. like, every time she passed by me, she was acting as if I wasn't there. She did greet the guys around me, so I know that she ignored me on purpose... So I ignored her back. I noticed that her mood seemed down, but maybe that was a false impression. She also stopped greeting me every time I came in or left.

2/3 weeks later (again), she kinda ignored me at first but then, around 20 minutes later, she greeted me in the hallway and called me by the nickname like she used to. Her mood seemed better than it was the other time. She seemed a bit more happy. She even greeted me when I left.

What could explain this behavior? Why did she start talking to me again after having ignored me completely for like 2/3 weeks?
Girl talks to me, ignores me, and then talks to me again?
Add Opinion