This festival is called the ‘Tak Baht Thaewo’ and is essentially an auspicious pindapada, almsround. It is in commemoration of the end of the Buddha’s 7th Rains retreat when he came down from the Tavatimsa heaven. The story goes that he had been teaching Abhidhamma (philosophical explanation of how mind and matter work) to his mother who I am sure you know, passed away 7 days after the Buddha’s birth. He descended from that heavenly relm via a triple staircase of Silver, Gold, and Emerald – and you can see an image of this behind the main Buddha statue in most temples.
During the Rains retreat the Buddha came back to this world each day and gave a summary of the teaching to his main disciple Sariputta, while leaving a replica of himself teaching the Devas in heaven. Apparently only Devas have the capacity to understand Abhidhamma, but Sariputta insisted that the world of men have access to the summaries. The Abhidhamma in fact is larger than the Suttas and Vinaya sections of the Tipitaka. Most scholars consider the Abhidhamma to be the work of later scholars who rearranged the teaching into, essentially, a big set of lists. It is still Buddha-Dhamma, but rearranged.
The Buddha descended from the heaven just in time to lead a procession of 100 arahant monks out on almsround about the town.
Anyhow, the ceremony on the 27th, the day after exiting the official Rains period, is in memory of this event, and lay people take food to offer the monks as they circumambulate the central chapel of each temple. One variation is the Tak Baat Phra Roy (100 monks almsround) festival which started in Pathom Thani, where the monks go almsround by boat.