You have a piston with a little too much skirt clearance. Once the engine reaches operating temp, the piston slap goes away due to heat expansion. While it's knocking, disconnect the spark plug wires one at a time. When you find the cylinder with the knock, it will either disappear, or change to a double noise if it's loose enough, kind of a "Ka-thunk" sound as the piston flops around without any combustion pressure keeping it pressed tight against the cylinder on the down stroke. I'm betting the noise will stop since it self-corrects when warm. Use a long screwdriver or a broomstick held to your ear as a stethoscope and the noise should be pretty easy to locate.
Jerry