Platform wheels for RDKit - a comprehensive cheminformatics and machine-learning library with Python bindings
89
A Python tool that compares molecular structures and identifies similar compounds using chemical fingerprinting.
@generates
def compute_similarity(smiles1: str, smiles2: str) -> float:
"""
Compute the similarity between two molecules represented as SMILES strings.
Args:
smiles1: SMILES string of the first molecule
smiles2: SMILES string of the second molecule
Returns:
A similarity score between 0.0 (completely different) and 1.0 (identical)
Raises:
ValueError: If either SMILES string is invalid
"""
pass
def find_similar_molecules(query_smiles: str, candidate_smiles: list[str], threshold: float = 0.7) -> list[tuple[str, float]]:
"""
Find molecules similar to a query molecule from a list of candidates.
Args:
query_smiles: SMILES string of the query molecule
candidate_smiles: List of SMILES strings representing candidate molecules
threshold: Minimum similarity score (0.0 to 1.0) for a match (default: 0.7)
Returns:
List of tuples (smiles, similarity_score) for candidates above threshold,
sorted by similarity score in descending order
Raises:
ValueError: If the query SMILES is invalid or candidate list is empty
"""
passProvides cheminformatics capabilities for molecular manipulation and analysis.
Install with Tessl CLI
npx tessl i tessl/pypi-rdkitevals
scenario-1
scenario-2
scenario-3
scenario-4
scenario-5
scenario-6
scenario-7
scenario-8
scenario-9
scenario-10