Basis-set toolkit¶
vibe-qc ships two basis-set toolkits that cover the full lifecycle: import from the Basis Set Exchange (BSE) and other QC-program formats, validation against the canonical model, conversion to legacy formats, and export to the QVF-Basis standalone container.
Feature status
vibeqc.basis_toolkit (under python/vibeqc/basis_toolkit/) is a
production-quality prototype for modern basis-set storage, validation,
conversion, and export. vibe-basis/ is a co-located sub-project
that optimises basis-set parameters against reference calculations
(via CRYSTAL14 backends and vq transport). Both are active
development areas; the APIs are stable but the feature surface is
growing.
vibeqc.basis_toolkit – Python API¶
Import from BSE, convert between formats, and validate:
from vibeqc.basis_toolkit import (
BasisSetData, from_bse_file, to_g94, to_orca, to_nwchem,
to_qvf_json, save_qvf, load_qvf, validate_basis_file,
)
# Import from BSE JSON
bse = from_bse_file("cc-pvdz.json")
print(bse.name, bse.basis_family, bse.elements.keys())
# Export to legacy formats
g94_text = to_g94(bse)
orca_text = to_orca(bse)
nwchem_text = to_nwchem(bse)
# Save as QVF-Basis (text mode)
save_qvf_json(bse, "cc-pvdz.qvf.json")
# Save as QVF-Basis (packaged, binary-safe)
save_qvf(bse, "cc-pvdz.qvf")
# Round-trip
bse2 = load_qvf("cc-pvdz.qvf")
assert bse.name == bse2.name
Import formats¶
Format |
Function |
Notes |
|---|---|---|
BSE JSON |
|
Basis Set Exchange format |
CRYSTAL atom |
|
CRYSTAL basis-set input |
Gaussian 94 |
|
Legacy |
ORCA |
|
ORCA basis-block format |
NWChem |
|
NWChem basis format |
QVF (JSON / packed) |
|
QVF-Basis container |
Export formats¶
Format |
Function |
Notes |
|---|---|---|
Gaussian 94 |
|
With loss report via |
ORCA |
|
With loss report via |
NWChem |
|
With loss report via |
QVF JSON |
|
Human-readable text mode |
QVF packed |
|
Binary-safe package for distribution |
libint bridge |
|
Converts to vibe-qc’s native C++ |
Canonical model¶
The BasisSetData object carries a format-neutral representation:
name,basis_family,description– metadataelements: dict[str, ElementBasis]– per-element basis functionsShell/Primitive/HarmonicType– angular-momentum encodingECPEntry/ECPPotential/ECPTerm– effective core potentialsProvenance/Reference– source and citation trackingBasisRole–orbital,jkfit,mp2fit,ecp
Validation¶
from vibeqc.basis_toolkit import validate_basis_file, validate_basis_json
errors = validate_basis_file("cc-pvdz.qvf.json")
if errors:
for e in errors:
print(e)
The validator checks structural completeness, angular-momentum consistency, primitive ordering, ECP coherency, and metadata completeness.
vibeqc.basis_toolkit – CLI¶
# Validate a QVF-Basis file
python -m vibeqc.basis_toolkit.cli validate sto-3g.qvf.json
# Convert BSE JSON to QVF-Basis (text mode)
python -m vibeqc.basis_toolkit.cli convert sto-3g.bse.json -o sto-3g.qvf.json
# Convert to legacy format
python -m vibeqc.basis_toolkit.cli convert sto-3g.bse.json -o sto-3g.g94 -f g94
# Show loss report for a conversion
python -m vibeqc.basis_toolkit.cli loss -f g94 sto-3g.bse.json
# Inspect a basis set (summary)
python -m vibeqc.basis_toolkit.cli inspect sto-3g.qvf.json
vibe-basis – basis-set optimisation¶
vibe-basis/ is a co-located sub-project (separate pyproject.toml)
for optimising basis-set parameters against reference calculations.
It exposes the vb CLI:
vb --version # package version + backends
vb parse crystal14 output.out # parse energy + convergence from CRYSTAL output
Planned verbs: vb emit-test-set, vb fit, vb parity – the full
basis-optimisation workflow (generate test sets, fit exponents against
reference data, verify against published parity tables).
Transport backends¶
vibe-basis runs calculations through vq (the vibe-queue tool):
from vibe_basis.transports.vq import VQTransport
# Submit basis-parameter sweeps to a compute fleet
See vibe-queue/docs/ and docs/user_guide/queue.md for the vq
infrastructure.
Where to look in the code¶
Layer |
Path |
|---|---|
Python API (toolkit) |
|
Canonical model |
|
CLI |
|
QVF-Basis format |
|
Library management |
|
Validator |
|
vibe-basis sub-project |
|
|
|
CRYSTAL14 backend |
|
Tests (toolkit) |
|
Tests (vibe-basis) |
|
See also¶
Basis sets – using basis sets in calculations.
Design: QVF Basis format – the QVF-Basis container specification.
QVF Basis developer readme – developer-oriented format details.
Queue (vq) – the compute-transport layer vibe-basis uses.