Fix minor errors of weighted sum_layer.