Update all_pairs_pattern.py

Changed the names of the methods according to Ole's suggestions