tested weight method with random seed