It is said that eyes are the windows into the soul. In this case more like big openings to shoot into the head.
Giant mecha robots mimic the human form very closely despite their gigantism. In media this is done for obvious reasons. You wouldn't cheer for a giant octopus thing... well, actually I might. But the most likely reason for this humanization of giant war machines is to serve as a symbol of whoever owns it. It informs the people that this here is affiliated with humans.
Here's the beloved Iron Giant as an example for my question. There's no human to compare the heights but notice that the eyes are huge (the Iron Giant is about 50 feet tall). The back of the eye sockets may be armoured as a precaution against headshots, however giant robots being blinded is very bad. You either have a radar or little hatch for a little pilot to look outside while simultaneously piloting the huge hunk of metal. Not ideal. The reason giant robots don't have facial windows is precisely because they have a pilot to protect (unmanned mechs are an exception). Even then, I'm not exactly sure why the eyes would need to be so large. I have a few theories but I'd prefer an explanation as well.