The most closely linked legend I can find is Shiva. Shiva is a hindu deity who has three eyes and is worshiped by people in the region that Pai is from.
Third eye: (Trilochana) Shiva is often depicted with a third eye, with which he burned Desire (Kāma) to ashes, called "Tryambakam" (Sanskrit: त्र्यम्बकम् )(Tamil :நெற்றிக்கண்), which occurs in many scriptural sources. In classical Sanskrit, the word ambaka denotes "an eye", and in the Mahabharata, Shiva is depicted as three-eyed, so this name is sometimes translated as "having three eyes". However, in Vedic Sanskrit, the word ambā or ambikā means "mother", and this early meaning of the word is the basis for the translation "three mothers". These three mother-goddesses who are collectively called the Ambikās. Other related translations have been based on the idea that the name actually refers to the oblations given to Rudra, which according to some traditions were shared with the goddess Ambikā. It has been mentioned that when Shiva loses his temper badly, his third eye opens which can destroy most of the things to ashes.
This is the best three eyed deity of the correct region I could find. I think that 3x3 eyes may have taken part of the legend as inspiration and then ran with it.