It may have come to Pythagoras from the Egyptians - I don’t recall the details at the moment, but ancient Egyptian math was very complex.
Well, I cheated and read the Wiki entry. Pythoagoras did not invent jis comma, but some smart people used his mathematical principles and applied it to tuning instruments in the 16th century or so, and properly credited him.