Maybe there isn't a good reason to fund mecha. It depends on the organization of your society.
For example, one could argue that Knights were a bit dumb in some cases, as an investment. From a practicality point of view, instead of taking one guy, giving him incredible equipment, and a lifetime of training, it might be better to arm and train a bunch of guys pretty well (for example, professional mercenary companies).
So perhaps your star empire (due to the difficulties of light-year distance governance) is a bit more feudal that modern society, and sending the nobility into combat is the best way to get them to fund a retinue.
Another possible driver could be an extended time of (relative) peace, but a very militaristic society. As a result, your military industrial complex - unfettered by the demands of actually waging war - might produce increasingly exotic and relatively untested gear. Perhaps the main drive has shifted from producing effective tools of war, to providing expensive toys for the nobility to look flashy while suppressing peasants. And (presumably this is important for your plot) the mecha aren't ineffective - they're just less effective than a couple thousand tanks would have been.
In the interest of generality, I want to point out that the unparalleled empire's soldiers being more suited for stuff other than war is somewhat of a well known trope. It gives a feeling of corruption/decline/oppression - who are these guys gearing up to fight? Are they really a legitimate army, if they aren't optimized to fight near peers? It also reflects some concerns that we might have with our military industrial complex.
Finally it provides either a convenient excuse for why there's only one supersoldier (for the main character to play -- I think they used this in Halo) who has to go on heroic adventures. Or it provides an excuse for why the baddies are so incompetent at war, which allows your ragtag band of heroes to beat them (possibly by combining the enemy's flashy gear with True Heroic Fighting Spirit).