Either from the spies, or rather from common fame, for this seems to be a proverb used. in those times.
Related Commentaries of Deuteronomy 9:2
Deuteronomy 9:2
2 A people great and tall, the children of the Anakims, whom thou knowest, and of whom thou hast heard say, Who can stand before the children of Anak!