Actually I meant best performance of the remote but now I'm not so sure. 'Auto' required 2 USB on/off cycles to stop the script. 'M' and 'P' only required one when I briefly tested the script. Just now I tested all 3 modes and they all worked with just one cycle. However, earlier I ran the script for about 10 minutes using 'M' mode and it required 2 cycles to stop. So I don't know now if there is any benefit. BTW I set the interval to 0 if that matters.
With the interval at zero, the camera will be really busy taking pictures, processing the images, and writing to the SD card. M and P mode might take less processing by the camera. But it's quite possible it will "miss" the occasional USB remote press. I might be able to improve on that if I get a little spare time (haha).
Did you try holding the USB switch down until you see the video stop?
Edit : I updated the script but have no way to test it today. Simple change should work better than the previous script ("famous last words"). Give it a shot and let me know?