bugfix in SimilarityMatrix.invert(): some indices in symmetric matrices were inverted twice