Heat oven to 180C/fan 160C/gas 4. Rinse and soak the rice for 10 mins. Heat a large, ovenproof saucepan. Add the oil, then the onion, garlic and ginger. Cook on a low heat until the onion is soft. Add the cloves, cinnamon and cardamom pods and cook for a further 2 mins on a low heat. Add the curry powder and cook for a further 2 mins, then stir.
Drain the rice and add it to the saucepan. Stir so that the rice is coated in the oil and spices. Add the peas, sweetcorn and half the flaked almonds, if using. Pour over the stock and stir.
Cover the pan with a lid or with a sheet of foil, then cook in the oven for 15-20 mins. Remove from the oven, scatter with the remaining almonds, if using, and serve.