fix indexing in samplerEval