Performance Profiling
This document summarizes profiling results and expected hot paths for large systems.
Profiling Script
Run the profiling script against a large PDB file:
python benchmarks/profile_partitioning.py
Expected Hot Paths
Distance calculations (pairwise distance checks during bond inference).
Neighbor finding (graph traversal for connectivity).
Rule matching (fragmentation rule evaluation).
Bond detection (covalent radius checks).
Graph partitioning (min-cut or community detection algorithms).
Baseline Notes
Large system profiling should focus on PDBs in the 10k–100k atom range.
Store your baseline output in version control if the dataset is stable.
Use
line_profilerandmemory_profilerfor deeper inspection.
Suggested Commands
pip install line_profiler memory_profiler
kernprof -l -v benchmarks/profile_partitioning.py
python -m memory_profiler benchmarks/profile_partitioning.py