Knock sensor does not detect mechanical knock. It only detects the frequency of ignition knock or pinging. This will usually happen at high load and moderate rpm, if it happens at idle then it would be pinging at all loads and speeds.
A mechanical knock that only happens when warm is usually bad news. Check oil level and dig out the receipts for oil changes. Sounds like it's going to be a big end. Rev engine in neutral to about 2.5K and then take foot off throttle, if it knocks as it slows down on the overrun then it's almost 100% certain to be big end(s). Main bearings rumble as they all help each other. Tappets will rattle when cold before they rattle warm. Cams like mains all the journals help support the shaft so they won't knock as such. But it could just be something lose like a heat shield or engine mount.