Added a logger to method ruleBasedLearn().