Pugglestein8280
I guess, it's the Auto reboot feature, maybe you are not familiar with…?
Open settings, use the search field; type in “auto” (or “auto reboot”, if it doesn't appear instantly).
You can use it to set the time after which your Pixel should restart if you do not unlock the screen in the meantime.
Depending on your threat model, you can select a longer or shorter time.
So if you are in a dangerous area or are worried that you could be robbed, then set the time to a shorter time.
If your location is not dangerous and you do not feel that you are being followed (and take care of your smartphone/never let it out of your hand!), you can select a long time such as 8 h or 12 h until the next restart.
The reason for this feature is that it is easier to crack a running but locked smartphone than a restarted one that you have not yet unlocked.