The only reliable tool to do traceroute between them. Or ping who responded faster, the closer. Or measure the time between SYN and SYN ACK. In General, to conduct some sort of measurement.
The Internet is a decentralized thing... you Can find a list of prefixes for each AS, but information about the current topology will be obtained only through a looking glass s and is not suitable for p2p systems. And information that are relevant now may be irrelevant in a couple of minutes, when the provider wants to change the route policy. Well, to make a customer tossing full view — in my opinion overkill.