DevConnectDevConnect
Sign up · Log in
← back to the feed
2

My first project in Cheminformatics

Last weekend, I stepped outside my usual software engineering lane and got into machine learning for molecular toxicity prediction using the Tox21 dataset. The model itself wasn't the interesting part. The data prep was. First lesson: you can't just find nulls, drop rows, and move on here. Tox21 has multiple toxicity endpoints, and not every compound was tested against every single one. If I'd dropped any row with a null anywhere, I'd have thrown away perfectly good data. So instead, I handled missing values per endpoint, using only compounds that had results for the specific assay I was modeling. Small shift, but it changed how I think about cleaning data in general: null doesn't always mean "bad"; sometimes it just means "not applicable here." Second, and probably my favorite part: I used RDKit for the first time. I'd seen SMILES strings before but never really got what they were; turns out they're just a compact text representation of molecular structure. Using RDKit, I could take a SMILES string and pull out actual molecular descriptors: molecular weight, LogP, TPSA, H-bond donors/acceptors, rotatable bonds, aromatic rings. So instead of feeding a model a raw string like CCO and hoping for the best, I could hand it numbers that actually mean something chemically. From there: Logistic Regression pipeline, feature scaling, class balancing, evaluated across 12 toxicity endpoints. Best result was SR-MMP at ~0.83 ROC-AUC; my original target, NR-AR, landed at ~0.74. But the real takeaway wasn't the score. It was realizing ML actually starts way before .fit(), in understanding the data, understanding what your features represent, understanding why things are missing, and choosing a cleaning + evaluation strategy that respects the domain instead of fighting it. This felt like my first real step into cheminformatics, and I'm starting to see how the chemistry background actually connects to the AI/ML side of what I do. Still learning, still experimenting.
Add a comment
0/2000