Cutting-out using pattern grading