macOS suddenly exhibits weird mouse acceleration after idling
I've had similar issues with a Logitech MX2 &amp; Logi Options.
My bet is the Logi controller that 'forgets' what it's doing.
Tests would include:-

uninstalling their drivers &amp; see if the same happens without;
test a different mouse;
see if your G-series can be used fully with something like SteerMouse or USB Overdrive.