Posterior view of a male legs with musculature highlighted. The focus of this image are the hamstring muscles of the upper leg. The hamstring muscles are any of three muscles at the back of the thigh that function to flex and rotate the leg and extend the thigh.