Hello; This happens to me from time to time, mostly following some change in my routine. In the last few weeks I have had to switch from riding a bicycle to walking for exercise. The first couple of weeks i had cramps in the back of my thigh upon comming awake. I would have to stand up right away to loosen the cramp. I have had them in my calf muscles in the past. A few weeks into my new routine my leg and thigh muscles tense upon comming awake, but now no more cramps.I woke up to an excruciating cramp at the top of my calf, ..again...wtf
Cramps in muscles have followed an injury which has forced me to move in some new way for a while.
Hydration and salt may have something to do with cramps as we are entering the hot season.