Skip to content

Add DCLV 3D descriptors - #373

Merged
scal444 merged 6 commits into
NVIDIA-BioNeMo:mainfrom
scal444:feat/dclv-descriptors-ready
Oct 23, 2026
Merged

scal444 merged 6 commits into
NVIDIA-BioNeMo:mainfrom
scal444:feat/dclv-descriptors-ready

Conversation

@scal444

@scal444 scal444 commented Oct 22, 2026

Copy link
Copy Markdown
Collaborator

No description provided.

Port RDKit's DoubleCubicLatticeVolume (Double Cubic Lattice Method surface
area and volume) as seven scalar properties in a new Dclv family, one per
getter: DCLVSurfaceArea, DCLVPolarSurfaceArea, DCLVVolume, DCLVVDWVolume,
DCLVPolarVolume, DCLVCompactness and DCLVPackingDensity. Any selection
shares one kernel launch.

One warp per conformer centers the coordinates on RDKit's centre of
gravity in float64, then per atom gathers neighbors in shared memory
(falling back to a full scan past 128) and tests RDKit's 320 dots. The
probe-expanded dots serve every property but DCLVVDWVolume and the bare
van der Waals dots serve DCLVVDWVolume and DCLVPackingDensity; each set
is tested only when a requested property needs it.

DclvOptions exposes probeRadius, includeSandP and includeHs. Custom
radii, isProtein and includeLigand are not supported. Conformers with a
dummy atom (radius 0), on which RDKit crashes, and rows with non-finite
coordinates produce NaN.

On 484 ChEMBL conformers FULL matches RDKit to 3e-15 relative and SINGLE
to 1.2e-6 relative with no surface-dot flips, so the kernel computes in
the requested precision apart from the existing float64 centering.
@greptile-apps

greptile-apps Bot commented Oct 22, 2026 •

Copy link
Copy Markdown
Contributor

RetriggerView in GreptileConfidence Score: 5/5

[Medium impact] The reviewed changes appear safe to merge; no actionable issues remain.

Summary

Adds seven DCLV 3D descriptors with shared GPU calculations and configurable probe radius and polar-atom choices.

  • Callers can request seven DCLV measurements for each conformer.

Reviews (5) · Last reviewed commit: "Pass explicit DCLV radii in the Python r..." · Reviewed by Greptile

Comment thread benchmarks/descriptors3d_bench.py Outdated
@scal444
scal444 requested a review from evasnow1992 October 22, 2026 20:32
Comment thread nvmolkit/tests/test_descriptors3d.py Outdated
rows = []
for mol in mols:
for conf in mol.GetConformers():
dclv = rdMolDescriptors.DoubleCubicLatticeVolume(mol, probeRadius=options.probeRadius, confId=conf.GetId())

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The reference here uses the default-radii constructor, which RDKit 2025.09.1 doesn't have. Since 2025.09.1 is the documented minimum, may consider passing the radii explicitly. Same at descriptors3d_bench.py:146 and test_descriptors3d_dclv_bench.py

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed

@evasnow1992 evasnow1992 left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

One rdkit version specific issue on the test and benchmark files. Other changes look good to me.

RDKit 2025.09.1's Python DoubleCubicLatticeVolume has no default-radii
constructor. The Python test reference, descriptors3d_bench.py and its
tests now pass per-atom van der Waals radii from the periodic table, which
match the defaults of later RDKit releases exactly.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@scal444
scal444 merged commit f951e49 into NVIDIA-BioNeMo:main Oct 23, 2026
15 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants