fixed a bug in tuple-based sampling