The httk₂ tutorial¶
This tutorial showcases the current modular httk₂ APIs through a sequence of short, practical examples.
The examples use the same vocabulary as the reference documentation, with deeper details linked from each page.
Install the pieces used by the tutorial¶
The httk2 metapackage installs the core, I/O, atomistic, analysis, and
workflow modules. Database examples additionally need httk-store’s SQL extra;
ASE is used only for the two visualization/interchange steps.
python -m pip install httk2 "httk-store[db]" ase
Feature map¶
Step |
Tutorial feature |
Current route |
Main module |
|---|---|---|---|
1 |
Load and inspect a structure |
One-call loading and exact inspection |
|
2 |
Build a structure in code |
Native unit-cell construction |
|
3 |
Visualize a structure |
ASE interchange; no built-in viewer |
|
4 |
Convert to/from ASE |
Structure and ASE views |
|
5 |
Build general, orthogonal, and cubic supercells |
Exact supercell operations |
|
6 |
Store structure data in SQLite |
Representation-specific Records in SQL or MongoDB stores |
|
7 |
Search the local database |
Backend-neutral query API |
|
8 |
Prepare a VASP calculation |
Packaged templates and POSCAR preparation |
|
9 |
Generate a batch |
Instantiation parameters and campaign partitioning |
|
10 |
Send and run remotely |
Remote adapters, precheck, and runner builds |
|
11 |
Read results into the database |
Workflow collection or explicit record storage |
|
12 |
Draw a phase diagram |
Composition and convex-hull analysis |
|
13 |
Store custom data |
Frozen dataclasses |
|
14 |
Publish a project centrally |
Signed local manifests; no central publisher |
|
15 |
Query an OPTIMADE server |
Generic OPTIMADE client and structure loading |
|
- 1. Load and inspect a structure
- 2. Build a structure in code
- 3. Visualize a structure
- 4. Build with ASE and convert to httk₂
- 5. Build supercells
- 6. Store data in SQLite
- 7. Search the local database
- 8. Prepare a VASP calculation
- 9. Create a Ca–Ti–O batch
- 10. Run the batch
- 11. Collect the results
- 12. Draw the Ca–Ti–O phase diagram
- 13. Store custom data
- 14. Publish a dataset or project
- 15. Query an OPTIMADE server