Very interesting question.
Each people has a laps of time in which he or she feels better (for me, it’s the evening), but has it an impact on creativity ? I’m not sure, but…
In cognitive searches (look on PubMed), there is a recurrent topic : is mind wandering improve or not creativity ? The answer tends toward “yes” (and as a downside, mind wandering seems also to be linked with depressive mood, which is logical in a way).
Personally I noticed than ideas come more easily with a wandering mind, maybe because in this state of mind your usual habits of thinking are loose (a good idea is often a paradoxical one).
So a similar mechanism may apply in your case : at 1-3 am, your mind is a little asleep, which allows strange ideas to pervade - and once you got it, you obviously want to explore it, so you suddenly felt very awaken (it happens sometimes to me, not often I admit).
But maybe I’m wrong and something mysterious else happens in your case ? (The visit of the idea provider of 1-3 am, for instance ? )