bios setting is a possibliity but I think it more likely you have a outdated driver operating a component and it's causing a hard memory fault/ reset when the system sends fancy power related commands to it.
The best way to troubleshoot this over the internet is to cause you to have some blue screens so we can have a look at a memory dump file.
If you are willing to go that route (can be a bit time consuming)
Start by turning on driver verifier. Driver Verifier - Enable and Disable
(Please read all instructions for driver verifier before using as it's possible it will make the machine behave badly and you need to know how to undo it.)