Preheat the oven to 350°F. Grease a 9-inch round cake pan and dust it with flour, or line it with parchment paper.
In a large bowl, beat the eggs with the granulated sugar using an electric mixer on medium–high speed for 3–4 minutes, until pale and fluffy.
Gradually pour in the vegetable oil, beating until fully incorporated.
In a separate bowl, whisk together the all-purpose flour, baking powder, ground cinnamon, ground nutmeg (if using), and a pinch of salt.
Add the dry ingredients to the egg mixture in two or three batches, folding gently with a spatula just until no streaks of flour remain.
Fold in the grated carrots until evenly distributed.
Pour the batter into the prepared pan and bake for 40–45 minutes, or until a toothpick inserted into the center comes out clean.
Let the cake rest in the pan for 10 minutes, then remove it and transfer to a wire rack to cool completely.
To make the frosting, beat the unsalted butter with the powdered sugar in a bowl until smooth.
Add the cold cream cheese and beat on low–medium speed just until combined.
Spread the frosting over the cooled cake and, if desired, garnish with a sprinkle of cinnamon or chopped walnuts.