[SATYR PATCHv2 5/6] python: distance computation between pair of threads