TCP timeout - How to set the the timeout value for tcp retransmission

I am using python socket programming to establish tcp/ip connection via ethernet cable. Via my program I am sending the packet and receiver should acks the packet within 10ms. The logging is done via wireshark. To check if my ack timeout works fine or not i want to make fail case to reduce ack timeout in my sender pc to 1ms so that retransmission occurs how to make this to work in windows? Because in windows how to set the retransmission and ack timeout?

Those timeouts are controlled by the OS usually not applications.

If you have specific application time limits I would implement over TCP in the application protocol handling code.