sampler does upper bound checks