Mash or process the cooked yams until smooth. Set aside.
Fry half the onions and half the tomatoes in 1/4 cup of the oil until onions are limp. Add thyme and salt and mix well.
Scrape the mixture into a bowl, dump in the remaining onions and tomatoes, and the yams. Mix well and beat the eggs. Turn the mixture out onto a floured surface. With greased hands, shape spheres about the size of golf balls. Heat the remaining oil to a temperature of between 350 degrees and 375 degrees, and fry balls until they are golden brown all around--about 4 or 5 minutes each. Drain on clean, absorbent cloths and serve immediately.