!. Do you have anything set up as a 'schedule' in your "Energy Saver" System Pref?
2. Might I ask how you know the Mac restarted? I assume it's because you had to sign in? Or was it simply that any previously opened apps were closed?
3. Have you ever used "Console"? It's in your Utilities folder.
Not sure which OS you're using (it would be great if you would update the info that appears under your name/avatar when you post here). Apple dumbed down the app in macOS 10.12 Sierra, but you should still be able to find "crash" reports.
Let us know if you need help using Console.