#NEWLINE# def kind_occurrence_pairs( self , lkind , rkind ) : #NEWLINE# #INDENT# eos = list ( self . get_entity_occurrences ( ) ) #NEWLINE# left = [ o for o in eos if ( o . entity . kind == lkind ) ] #NEWLINE# right = [ o for o in eos if ( o . entity . kind == rkind ) ] #NEWLINE# return [ ( l , r ) for ( l , r ) in itertools . product ( left , right ) if ( l != r ) ]