optimizing and sampling several chunks