LinePatternRecognizer implementation