Method costs and reaction chemistry¶
Compare search methods¶
The plot-comparison command reads the verified cells.csv exports from
gpridge:sub:`repro<https://github.com/HaoZeke/gpridge_repro>`_. It pairs each comparator with GPRidge on the same accepted
reactions. The method labels retain acceptance counts for the full panels.
rgpycrumbs chemgp plot-comparison --config analysis/method_comparisons/profile.toml
The profile names the exports, panel sizes and method labels. Relative paths
are resolved from the profile directory. The reproducer supplies the full
profile and pinned requirements in analysis/figure-requirements.txt.
The output directory contains:
method_cost_frontiers.pdfand.png: Pareto means on identical shared successes, with acceptance counts on the full panels.method_acceptance_baker.pdfandmethod_acceptance_birkholz.pdf: cumulative acceptance against absolute time and force-call budgets.method_savings.pdfand.png: paired mean search calls and elapsed times.performance_profiles.pdfand.png: the fraction of all reactions whose accepted cost is within a factor of the best accepted method for that reaction. Failed checks have infinite cost; every reaction remains in the denominator.reaction_costs_baker.pdfandreaction_costs_birkholz.pdf, with PNG copies: one row per reaction, with crosses for outcomes that fail the common checks.manifest.json: input and output hashes, resolved package sources, shared reaction labels, raw totals and ratios.
The performance profiles follow Dolan and More (https://doi.org/10.1007/s101070100263). The cumulative curves provide the absolute-budget view used by cactus plots. Their denominators include every attempted reaction, including a reaction for which all methods fail.
A ratio above one means the comparator uses more calls or time. Costs exclude independent validation and shared Birkholz band preparation. Counts include endpoint evaluations and ML-FSM string construction. Each retained case has one timing measurement, so the plot does not estimate timing error bars.
Render bonds from electronic structure¶
The plot-reactions command reads CON structures through readcon, aligns
atom identities by rigid rotations, and evaluates GFN2-xTB single points.
It uses xyzrender to draw the measured Wiberg bond orders (WBOs) and electron
density. The calculation does not optimize the coordinates.
rgpycrumbs chemgp plot-reactions --config reactions.toml --xtb xtb
The xtb executable must be installed. Other command dependencies use the
standard uv dispatcher. A profile row contains four states:
[shared]
dpi = 300
[reactions]
output = "reaction-figures"
density = true
iso = 0.02
[[reactions.cases]]
id = "hcn"
title = "HCN isomerization"
charge = 0
multiplicity = 1
bonds = [[1, 3], [2, 3]]
[[reactions.cases.states]]
title = "Reactant"
path = "reactant.con"
[[reactions.cases.states]]
title = "GPRidge saddle"
path = "saddle.con"
[[reactions.cases.states]]
title = "Product"
path = "product.con"
[[reactions.cases.states]]
title = "Comparator endpoint"
path = "comparator.con"
Atom indices in bonds are one-based and follow the CON file. Without that
list, annotations select the largest endpoint distance changes among pairs
within a covalent-radius cutoff at either endpoint. Rendered connectivity
always comes from the computed WBOs. Atom order and elements must agree across
all four states; the alignment neither permutes atoms nor reflects a structure.
Colour and width encode WBO on the same scale from zero to three. Values below 0.5 are dotted and those below 0.1 are omitted. These are drawing thresholds, not universal criteria for a chemical bond. A missing xTB table entry is reported as unprinted, never as a measured zero. Density surfaces use the profile’s common isovalue in electrons per cubic Bohr.
Atom annotations use the DejaVu Sans Mono font supplied with Matplotlib. Each structure also retains an SVG for vector reuse.
The output includes reaction_geometries.pdf, reaction_density.pdf and PNG
copies, bonds.csv with distances and WBOs, and a manifest. Each numbered state
directory retains the input XYZ, xTB control file, log, WBO table, cube and
properties.json with executable and artifact hashes. A state may set broydamp to adjust SCC charge mixing
(default 0.4); the setting is retained with the calculation. The command reuses a
calculation only when its settings and artifact hashes match. A failed xTB
calculation stops figure generation and keeps its log.
Optional record and validation_key fields in a state select its retained
benchmark validation record. The panel then reports the maximum force, number
of negative modes and unresolved modes. Those quantities use the benchmark
potential. The xTB properties provide chemical interpretation and do not
replace that potential or its saddle checks.
Unfinished ML-NEB searches¶
An optional [comparison.catlearn] table names history and summary
CSV inputs from gpridge_repro/analysis/analyze_catlearn_failures.py.
The same command adds catlearn_failures.pdf and its PNG. Each reaction
compares the measured force at the selected geometry with the energy
uncertainty on its surrogate path, each divided by its own stopping
threshold. The caption must keep these two quantities distinct.
Input hashes are included in the comparison manifest.