Added filters to depth-first pattern growing algorithm. All links should be connected by variables not const nodes; All leaves should not be variables.