I was having this issue often. I did three things, not sure which helped the most, but I've not had it happen since.

#1 updated my video card driver
#2 Took a vacuum and cleaned all the dust that had accumulated around the computer's fan
#3 Moved my computer on my desk so it wasn't stuffed in the corner by the wall to give it better air flow.