These pictures look somewhat extreme, but in general, I have been in plants packaging powder products and saw that when they are filled they are close to the top with some room to prevent spillag at which point they are weighed to ensure proper product quantity. By the time it reaches the end of the line there is already very noticeable settling that occurred and when buying it retail the container looks like it was underfilled.
Specific to spices, many companies want to keep a uniform container size and uniform pricing and simply adjust the fill to account for the differences.