extract_feature_similarity function

Internal function to extract the feature distance table.