I think I have declared it. As I mentioned, there is a similar function called 'extract_ip_patterns' which is used in the same program.
But, there is no problem on using this function. And, I have used the same way to use 'extract_op_patterns'.
However, it doesn't work. Maybe the problem is easier to be found with my code posted.