The Nine Emperor Gods are the sons of Father Emperor Zhou Yu Dou Fu Yuan Jun (斗父周御國王天尊) and the North Star Dou Mu Yuan Jun (斗母元君).
They are the seven (visible) stars that make up the Big Dipper, plus another two (invisible) ‘assistant’ stars.
The Nine Emperor Gods are often wrongly conflated with folk heroes like the sea pirates of the Ming dynasty who plotted to overthrow the Qing dynasty. They are actually high ranking Star Lords who preside over the movement of planets and coordinate mortal Life and Death issues.
Their parents, Dou Fu and Dou Mu, hold the Registrar of Life and Death.
The festival for the Emperor Gods lasts nine days, from the eve of the ninth lunar month.
A couple of years ago, when I was on one of my wanders around George Town, Penang, I came across a part of town flying yellow banners as there was a temple there dedicated to the nine gods. That visit was a rainy one and apparently it tends to rain a lot during the Emperor Gods festival. Here’s the boat that would have been carried in a procession to the sea at the climax of the festival:
During that visit I also visited the Lee Clan Jetty and saw this offering and flag at the end of the walkway:
I’ve been planning to go back to witness the procession at the end of the festival, but life has got in the way and, this year, Covid-19.
There is a temple (Kau Ong Ya) dedicated to the nine gods in Ampang (just on the outskirts of Kuala Lumpur), but I have never got around to going for the festival although I did visit once, on a Datuk Gong hunting expedition. If I can find the pictures I took, I will post them.