Fixing bugs introduced by storage size refactorings
Minor tweaks to the sampler