added sample weighting functionality for cross validation splitting