Added some code related to BPredPerceptron