Re: Ensuring symmetry in difflib.SequenceMatcher

2010-11-24 Thread John Machin
On Nov 24, 8:43 pm, Peter Otten <__pete...@web.de> wrote: > John Yeung wrote: > > I'm generally pleased with difflib.SequenceMatcher:  It's probably not > > the best available string matcher out there, but it's in the standard > > library and I've seen worse in the wild.  One thing that kind of > >

Re: Ensuring symmetry in difflib.SequenceMatcher

2010-11-24 Thread Peter Otten
John Yeung wrote: > I'm generally pleased with difflib.SequenceMatcher: It's probably not > the best available string matcher out there, but it's in the standard > library and I've seen worse in the wild. One thing that kind of > bothers me is that it's sensitive to which argument you pick as "s

Re: Ensuring symmetry in difflib.SequenceMatcher

2010-11-24 Thread Wolfgang Rohdewald
On Mittwoch 24 November 2010, John Yeung wrote: > Are there any > simple adjustments that can be made without sacrificing (too > much) performance? >>> difflib.SequenceMatcher(None,*sorted(('BYRD','BRADY'))).ratio() 0.3 -- Wolfgang -- http://mail.python.org/mailman/listinfo/pyt

Ensuring symmetry in difflib.SequenceMatcher

2010-11-23 Thread John Yeung
I'm generally pleased with difflib.SequenceMatcher: It's probably not the best available string matcher out there, but it's in the standard library and I've seen worse in the wild. One thing that kind of bothers me is that it's sensitive to which argument you pick as "seq1" and which you pick as