Preheat your oven to 350°F (175°C) and grease an 8x8 inch baking pan.
In a medium bowl, whisk together the flour, baking powder, baking soda, salt, and cinnamon until combined.
In another large bowl, mix the granulated sugar, brown sugar, and vegetable oil until well combined. Add in the eggs and vanilla, mixing until smooth.
Gradually add the dry ingredients to the wet ingredients, stirring until just combined.
Carefully fold in the grated carrots and chopped walnuts until evenly distributed.
Pour the batter into the prepared baking pan and spread it out evenly.
Bake in the preheated oven for 30-35 minutes, or until a toothpick inserted into the center comes out clean.
Allow the cake to cool in the pan for about 10 minutes, then transfer it to a wire rack to cool completely.