The calorimetry experiment is probably trying to measure how much energy is available in a certain mass of food.
If you fully burned the substance, you would just use initial mass.
If you have not burned the whole thing, then the energy/change in temperature was a result of burning only that portion of food. So the rest of the food which remained had no role in the experiment at all.
Calculating (initial mass - final mass) will give you the mass of the food which was burned. You can use that as the