readcon-db 0.2.0__tar.gz → 0.2.2__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {readcon_db-0.2.0 → readcon_db-0.2.2}/.github/workflows/ci_mpi.yml +5 -1
- readcon_db-0.2.2/.github/workflows/lint.yml +47 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/CHANGELOG.md +24 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/CITATION.cff +3 -1
- {readcon_db-0.2.0 → readcon_db-0.2.2}/Cargo.lock +4 -3
- {readcon_db-0.2.0 → readcon_db-0.2.2}/Cargo.toml +2 -2
- {readcon_db-0.2.0 → readcon_db-0.2.2}/PKG-INFO +8 -1
- {readcon_db-0.2.0 → readcon_db-0.2.2}/README.md +7 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/docs/orgmode/contributing/index.org +2 -2
- {readcon_db-0.2.0 → readcon_db-0.2.2}/docs/orgmode/cooked-soa.org +14 -10
- {readcon_db-0.2.0 → readcon_db-0.2.2}/docs/orgmode/explanation/architecture.org +8 -1
- readcon_db-0.2.2/docs/orgmode/howto/atom-order.org +87 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/docs/orgmode/howto/campaign.org +1 -1
- {readcon_db-0.2.0 → readcon_db-0.2.2}/docs/orgmode/howto/howto.org +22 -13
- {readcon_db-0.2.0 → readcon_db-0.2.2}/docs/orgmode/howto/install.org +7 -5
- readcon_db-0.2.2/docs/orgmode/howto/migration.org +38 -0
- readcon_db-0.2.2/docs/orgmode/howto/streaming.org +149 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/docs/orgmode/index.org +12 -5
- {readcon_db-0.2.0 → readcon_db-0.2.2}/docs/orgmode/reference/c.org +4 -2
- {readcon_db-0.2.0 → readcon_db-0.2.2}/docs/orgmode/reference/fortran.org +3 -1
- readcon_db-0.2.2/docs/orgmode/reference/python-api.org +14 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/docs/orgmode/reference/python.org +12 -2
- {readcon_db-0.2.0 → readcon_db-0.2.2}/docs/orgmode/reference/rust.org +18 -3
- {readcon_db-0.2.0 → readcon_db-0.2.2}/docs/orgmode/tutorials/getting-started.org +8 -5
- readcon_db-0.2.2/docs/orgmode/tutorials/tutorial-run.log +40 -0
- readcon_db-0.2.2/docs/orgmode/tutorials/tutorial-run.sh +48 -0
- readcon_db-0.2.2/docs/orgmode/tutorials/tutorial.org +168 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/docs/source/conf.py +32 -3
- {readcon_db-0.2.0 → readcon_db-0.2.2}/fortran/README.md +2 -1
- {readcon_db-0.2.0 → readcon_db-0.2.2}/fortran/ReadConDb/fpm.toml +3 -1
- {readcon_db-0.2.0 → readcon_db-0.2.2}/include/readcon-db.h +61 -18
- {readcon_db-0.2.0 → readcon_db-0.2.2}/meson.build +1 -1
- {readcon_db-0.2.0 → readcon_db-0.2.2}/pixi.toml +3 -1
- {readcon_db-0.2.0 → readcon_db-0.2.2}/pyproject.toml +1 -1
- {readcon_db-0.2.0 → readcon_db-0.2.2}/python/pyproject.toml +1 -1
- readcon_db-0.2.2/python/tests/test_atom_order.py +58 -0
- readcon_db-0.2.2/python/tests/test_catalog_claims.py +132 -0
- readcon_db-0.2.2/python/tests/test_stream_and_random.py +69 -0
- readcon_db-0.2.2/python/tests/test_streaming_guide.py +37 -0
- readcon_db-0.2.2/scripts/build-docs.sh +136 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/scripts/check-cxx-dist.sh +1 -0
- readcon_db-0.2.2/scripts/check_version_lockstep.py +208 -0
- readcon_db-0.2.2/scripts/crate_version.py +29 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/scripts/package-cxx.sh +1 -1
- {readcon_db-0.2.0 → readcon_db-0.2.2}/scripts/release-prep.sh +1 -1
- readcon_db-0.2.2/scripts/set-version.sh +14 -0
- readcon_db-0.2.2/scripts/sync-version.py +41 -0
- readcon_db-0.2.2/scripts/test_check_version_lockstep.py +90 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/src/bin/readcon-db.rs +31 -0
- readcon_db-0.2.2/src/canonical.rs +206 -0
- readcon_db-0.2.2/src/catalog.rs +829 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/src/cooked_soa.rs +6 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/src/corpus.rs +760 -141
- readcon_db-0.2.2/src/error.rs +60 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/src/export_h5md.rs +67 -2
- {readcon_db-0.2.0 → readcon_db-0.2.2}/src/export_xyz.rs +1 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/src/ffi.rs +140 -20
- {readcon_db-0.2.0 → readcon_db-0.2.2}/src/keys.rs +8 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/src/lib.rs +17 -1
- {readcon_db-0.2.0 → readcon_db-0.2.2}/src/mpi_ingest.rs +441 -137
- readcon_db-0.2.2/src/mpi_wire.rs +257 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/src/python.rs +465 -20
- {readcon_db-0.2.0 → readcon_db-0.2.2}/src/select.rs +59 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/src/shard.rs +46 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/src/topology.rs +20 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/src/units_canon.rs +172 -0
- readcon_db-0.2.2/tests/atom_order.rs +231 -0
- readcon_db-0.2.2/tests/catalog_claims.rs +633 -0
- readcon_db-0.2.0/.github/workflows/lint.yml +0 -24
- readcon_db-0.2.0/docs/orgmode/tutorials/tutorial.org +0 -82
- readcon_db-0.2.0/scripts/build-docs.sh +0 -43
- readcon_db-0.2.0/scripts/check_version_lockstep.sh +0 -43
- readcon_db-0.2.0/scripts/set-version.sh +0 -18
- readcon_db-0.2.0/src/error.rs +0 -26
- readcon_db-0.2.0/tests/ci_gates.rs +0 -24
- {readcon_db-0.2.0 → readcon_db-0.2.2}/.github/workflows/c_lib_tarball.yml +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/.github/workflows/ci.yml +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/.github/workflows/ci_cxx.yml +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/.github/workflows/ci_docs.yml +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/.github/workflows/ci_prek.yml +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/.github/workflows/crates_publish.yml +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/.github/workflows/cxx_tarball.yml +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/.github/workflows/pages.yml +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/.github/workflows/python-wheels.yml +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/.gitignore +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/CMakeLists.txt +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/CODE_OF_CONDUCT.md +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/CONTRIBUTING.md +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/LICENSE +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/SECURITY.md +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/assets/logo/BRAND.md +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/assets/logo/readcon-db-logo-512.png +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/assets/logo/readcon-db-logo-raster.jpg +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/assets/logo/readcon-db-logo.svg +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/assets/logo/readcon-db-wordmark.svg +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/bench/gen_con.py +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/bench/mpi_bench.sh +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/bench/vary_con.py +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/cmake/readcon-db-config-version.in.cmake +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/cmake/readcon-db-config.in.cmake +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/cmake/readcon-db.pc.in +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/cmake/tempdir.cmake +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/cog.toml +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/docs/Makefile +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/docs/_static/logo.svg +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/docs/orgmode/changelog.org +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/docs/orgmode/explanation/design.org +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/docs/orgmode/explanation/faq.org +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/docs/orgmode/explanation/overview.org +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/docs/orgmode/howto/mpi.org +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/docs/orgmode/howto/topology.org +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/docs/orgmode/howto/workflows.org +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/docs/orgmode/readme.org +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/docs/orgmode/reference/citation.org +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/docs/requirements.txt +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/docs/source/_static/custom.css +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/docs/source/_static/favicon.svg +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/docs/source/_static/logo-nav-dark.svg +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/docs/source/_static/logo-nav-light.svg +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/docs/source/_static/logo.svg +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/docs/source/_static/mark.svg +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/docs/source/_templates/partials/extra-foot.html +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/docs/source/_templates/partials/extra-head.html +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/docs/source/_templates/partials/site-foot.html +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/docs/source/_templates/partials/webfonts.html +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/examples/bench_corpus_ops.rs +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/examples/bench_vs_ase_prep.py +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/examples/benchmarks/ase_db_bench.json +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/examples/benchmarks/ase_fair_campaign_1.json +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/examples/benchmarks/bench_ase_db.py +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/examples/benchmarks/db_vs_ase_table.md +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/examples/benchmarks/fair_campaign.py +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/examples/benchmarks/fair_db_vs_ase_table.md +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/examples/benchmarks/readcon_db_bench.json +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/examples/benchmarks/results_merged.json +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/examples/benchmarks/test_fair_select_parity.py +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/examples/ingest_select.rs +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/examples/mpi_bcast_frame.c +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/examples/mpi_bcast_frame.f90 +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/examples/mpi_bcast_frame.py +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/examples/mpi_ingest_check.rs +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/examples/mpi_read_check.rs +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/examples/shard_gate.rs +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/examples/workflows/metatrain_from_con.md +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/examples/workflows/options.metatrain.snippet.yaml +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/fortran/ReadConDb/src/readcon_db.f90 +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/include/readcon-db-mpi.h +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/lychee.toml +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/meson_options.txt +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/packaging/wrapdb/README.md +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/packaging/wrapdb/readcon-db.wrap.in +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/paper/cpc/freeze/ase_fair_campaign_1.json +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/paper/cpc/freeze/fair_db_vs_ase_table.md +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/paper/cpc/readme.org +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/paper/cpc/scripts/gen_fair_table.py +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/paper/cpc/src/appendix-fair-campaign.org +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/paper/cpc/src/figures/generated/fair_campaign_table.tex +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/pixi.lock +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/pr-text.md +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/prek.toml +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/python/tests/test_export_h5md.py +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/python/tests/test_ingest_memory.py +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/resources/test/eon36_lj_dimer.convel +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/resources/test/sulfolene.con +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/resources/test/tiny_cuh2.con +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/resources/test/tiny_cuh2.convel +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/resources/test/tiny_cuh2_forces.con +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/resources/test/tiny_cuh2_vel_forces.con +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/resources/test/tiny_multi_cuh2.con +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/scripts/assemble-site.sh +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/scripts/check-clib-dist.sh +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/scripts/check-cpc-freeze.sh +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/scripts/export-landing.sh +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/scripts/meson_cargo_build.py +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/scripts/package-clib.sh +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/src/archive.rs +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/src/frame_codec.rs +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/src/frame_scalars.rs +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/src/mpi_read.rs +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/tests/canonical_dump.rs +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/tests/cli_refuse.rs +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/tests/cmake-project/CMakeLists.txt +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/tests/cmake-project/main.c +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/tests/cooked_soa_authority.rs +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/tests/meson-wrap/main.c +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/tests/meson-wrap/meson.build +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/tests/mpi-c/ingest_smoke.c +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/tests/topology_cli.rs +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/website/assets/logo.svg +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/website/assets/wordmark.svg +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/website/css/site.css +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/website/export.el +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/website/index.html +0 -0
- {readcon_db-0.2.0 → readcon_db-0.2.2}/website/index.org +0 -0
|
@@ -41,7 +41,11 @@ jobs:
|
|
|
41
41
|
mpich_4.2.0-5.1_amd64.deb \
|
|
42
42
|
libmpich-dev_4.2.0-5.1_amd64.deb
|
|
43
43
|
do
|
|
44
|
-
curl
|
|
44
|
+
# Launchpad answers 503 under load (curl exit 22). The file is
|
|
45
|
+
# still the Hydra build; retry the transient archive failure.
|
|
46
|
+
curl -fsSL --retry 5 --retry-delay 2 --retry-all-errors \
|
|
47
|
+
-o "$d/$f" \
|
|
48
|
+
"https://launchpad.net/ubuntu/+archive/primary/+files/$f"
|
|
45
49
|
done
|
|
46
50
|
sudo dpkg -i \
|
|
47
51
|
"$d/libmpich12_4.2.0-5.1_amd64.deb" \
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
name: Lint
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
push:
|
|
5
|
+
branches: [main, "fix/**", "feat/**", "ci/**"]
|
|
6
|
+
pull_request:
|
|
7
|
+
branches: [main]
|
|
8
|
+
workflow_dispatch:
|
|
9
|
+
jobs:
|
|
10
|
+
lint:
|
|
11
|
+
runs-on: ubuntu-latest
|
|
12
|
+
|
|
13
|
+
steps:
|
|
14
|
+
- uses: actions/checkout@v6
|
|
15
|
+
with:
|
|
16
|
+
fetch-depth: 0
|
|
17
|
+
|
|
18
|
+
- name: Conventional commits check
|
|
19
|
+
uses: cocogitto/cocogitto-action@v3
|
|
20
|
+
with:
|
|
21
|
+
check-latest-tag-only: true
|
|
22
|
+
|
|
23
|
+
# large-file-auditor is omitted: this clone already has historical
|
|
24
|
+
# target/debug blobs above 1M. Rewriting shared history is a separate job.
|
|
25
|
+
|
|
26
|
+
version:
|
|
27
|
+
runs-on: ubuntu-latest
|
|
28
|
+
|
|
29
|
+
steps:
|
|
30
|
+
- uses: actions/checkout@v6
|
|
31
|
+
|
|
32
|
+
- uses: actions/setup-python@v6
|
|
33
|
+
with:
|
|
34
|
+
python-version: '3.12'
|
|
35
|
+
|
|
36
|
+
- run: python -m pip install cogapp==3.6.0 meson==1.12.1
|
|
37
|
+
|
|
38
|
+
- name: Every version copy matches Cargo.toml
|
|
39
|
+
run: python scripts/check_version_lockstep.py
|
|
40
|
+
|
|
41
|
+
- name: Drift the sync misses still fails the check
|
|
42
|
+
run: python scripts/test_check_version_lockstep.py
|
|
43
|
+
|
|
44
|
+
- name: The sync leaves the tree unchanged
|
|
45
|
+
run: |
|
|
46
|
+
python scripts/sync-version.py
|
|
47
|
+
git diff --exit-code
|
|
@@ -1,5 +1,29 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## v0.2.2 - 2026-11-19
|
|
4
|
+
#### Features
|
|
5
|
+
- (**python**) add insert_catalog_record and list_catalog_records - (218ff19) - *HaoZeke*
|
|
6
|
+
- (**catalog**) finalize catalog records and leased claims; dumps and shard rebuilds keep catalog rows, and claim errors subclass RuntimeError - (218ff19) - *HaoZeke*
|
|
7
|
+
- (**catalog**) take the claim lease clock from the corpus - (ee80d62) - *HaoZeke*
|
|
8
|
+
- (**identity**) opt-in canonical hash for frames that differ by atom-id order - (34c88b8) - *HaoZeke*
|
|
9
|
+
#### Bug Fixes
|
|
10
|
+
- (**ci**) retry the MPICH deb download after a launchpad 503 - (da7d307) - *HaoZeke*
|
|
11
|
+
- (**docs**) write the rustdoc root page help and settings link to - (3f91bee) - *HaoZeke*
|
|
12
|
+
- (**docs**) fetch crates before the docs rustdoc build - (ff3a169) - *HaoZeke*
|
|
13
|
+
#### Documentation
|
|
14
|
+
- link the canonical identity note to reorder_like - (39ee7bb) - *HaoZeke*
|
|
15
|
+
#### Tests
|
|
16
|
+
- pin the lease window with a hand-advanced clock - (07ecd24) - *HaoZeke*
|
|
17
|
+
#### Build system
|
|
18
|
+
- (**reader**) require readcon-core 0.21.0 for atom-id correspondence
|
|
19
|
+
|
|
20
|
+
## v0.2.1 - 2026-11-11
|
|
21
|
+
#### Bug Fixes
|
|
22
|
+
- stream corpus append and parse one stored frame - (623ff00) - *HaoZeke*
|
|
23
|
+
#### Documentation
|
|
24
|
+
- document streaming append and publish the API reference - (e43f6f8) - *HaoZeke*
|
|
25
|
+
- rebuild the tutorial on recorded output and fix stale install, C, and link defects (#26) - (9cf3abf) - *HaoZeke*
|
|
26
|
+
|
|
3
27
|
## v0.2.0 - 2026-10-15
|
|
4
28
|
#### Features
|
|
5
29
|
- (**frames**) store CON text as a tagged zstd frame - (838df21) - *HaoZeke*
|
|
@@ -9,7 +9,9 @@ authors:
|
|
|
9
9
|
orcid: "https://orcid.org/0000-0002-2393-8056"
|
|
10
10
|
license: MIT
|
|
11
11
|
repository-code: "https://github.com/lode-org/readcon-db"
|
|
12
|
-
version:
|
|
12
|
+
# [[[cog cog.outl(f'version: {VERSION}') ]]]
|
|
13
|
+
version: 0.2.2
|
|
14
|
+
# [[[end]]]
|
|
13
15
|
date-released: "2026-08-15"
|
|
14
16
|
keywords:
|
|
15
17
|
- CON
|
|
@@ -850,14 +850,15 @@ checksum = "60a357793950651c4ed0f3f52338f53b2f809f32d83a07f72909fa13e4c6c1e3"
|
|
|
850
850
|
|
|
851
851
|
[[package]]
|
|
852
852
|
name = "readcon-core"
|
|
853
|
-
version = "0.
|
|
853
|
+
version = "0.21.0"
|
|
854
854
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
855
|
-
checksum = "
|
|
855
|
+
checksum = "08b9703489462ee25ce5ccc00bc357ec2a14c08a5ea2de6778ca612b64839060"
|
|
856
856
|
dependencies = [
|
|
857
857
|
"dlpk",
|
|
858
858
|
"fast-float2",
|
|
859
859
|
"flate2",
|
|
860
860
|
"half 1.8.3",
|
|
861
|
+
"libc",
|
|
861
862
|
"memchr",
|
|
862
863
|
"memmap2",
|
|
863
864
|
"ndarray",
|
|
@@ -868,7 +869,7 @@ dependencies = [
|
|
|
868
869
|
|
|
869
870
|
[[package]]
|
|
870
871
|
name = "readcon-db"
|
|
871
|
-
version = "0.2.
|
|
872
|
+
version = "0.2.2"
|
|
872
873
|
dependencies = [
|
|
873
874
|
"heed",
|
|
874
875
|
"libc",
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
[package]
|
|
2
2
|
name = "readcon-db"
|
|
3
|
-
version = "0.2.
|
|
3
|
+
version = "0.2.2"
|
|
4
4
|
edition = "2021"
|
|
5
5
|
description = "Mmap-backed CON frame corpus (Heed/LMDB), xxHash exact match, multi-language FFI"
|
|
6
6
|
license = "MIT"
|
|
@@ -27,7 +27,7 @@ mpi = ["dep:mpi"]
|
|
|
27
27
|
[dependencies]
|
|
28
28
|
heed = "0.21"
|
|
29
29
|
# The pinned writer provides exact numeric CON and JSON round trips.
|
|
30
|
-
readcon-core = "=0.
|
|
30
|
+
readcon-core = "=0.21.0"
|
|
31
31
|
thiserror = "2"
|
|
32
32
|
serde = { version = "1", features = ["derive"] }
|
|
33
33
|
serde_json = "1"
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: readcon-db
|
|
3
|
-
Version: 0.2.
|
|
3
|
+
Version: 0.2.2
|
|
4
4
|
Summary: Mmap CON corpus store (LMDB/Heed) with xxHash exact match
|
|
5
5
|
Home-Page: https://lode-org.github.io/readcon-db/
|
|
6
6
|
License: MIT
|
|
@@ -86,6 +86,8 @@ let h = db.frame_hash(keys[0])?;
|
|
|
86
86
|
|
|
87
87
|
Foreign trajectories: **`readcon.read_chemfiles("traj.xyz")` → frames → ingest into readcon-db** (chemfiles-enabled build), not `ase.io.read`.
|
|
88
88
|
|
|
89
|
+
Python `append_trajectory_frames` commits 64 frames at a time. `get_frame` returns a `StoredFrame` (`atoms[i]` builds that atom only). Gzip and zstd files are read with `readcon.read_con`, then appended. Python `append_trajectory` and Rust `append_trajectory_path` read UTF-8 and do not decompress. `readcon-db` does not register an `ase.ioformats` entry point. Guide: [`docs/orgmode/howto/streaming.org`](docs/orgmode/howto/streaming.org). Upgrade from 0.2.0: [`docs/orgmode/howto/migration.org`](docs/orgmode/howto/migration.org).
|
|
90
|
+
|
|
89
91
|
## Design
|
|
90
92
|
|
|
91
93
|
- **No SQL engine** — explicit indexes + in-process intersection, with **ASE.db-competitive screening fields** (mass, volume, PBC, reserved metadata, charge/magmom; see [design matrix](docs/orgmode/explanation/design.org)).
|
|
@@ -119,6 +121,11 @@ Foreign trajectories: **`readcon.read_chemfiles("traj.xyz")` → frames → inge
|
|
|
119
121
|
|
|
120
122
|
Full ABI table, logo, Sphinx docs, and site: see `docs/`, `website/`, `assets/logo/`, `CHANGELOG.md`. Fortran module notes: `fortran/README.md`, `fortran/ReadConDb/`.
|
|
121
123
|
|
|
124
|
+
## Questions and bug reports
|
|
125
|
+
|
|
126
|
+
Ask questions and report bugs on the [GitHub issue tracker](https://github.com/lode-org/readcon-db/issues).
|
|
127
|
+
Report a security problem by email instead, as [`SECURITY.md`](SECURITY.md) describes.
|
|
128
|
+
|
|
122
129
|
## License
|
|
123
130
|
|
|
124
131
|
MIT
|
|
@@ -73,6 +73,8 @@ let h = db.frame_hash(keys[0])?;
|
|
|
73
73
|
|
|
74
74
|
Foreign trajectories: **`readcon.read_chemfiles("traj.xyz")` → frames → ingest into readcon-db** (chemfiles-enabled build), not `ase.io.read`.
|
|
75
75
|
|
|
76
|
+
Python `append_trajectory_frames` commits 64 frames at a time. `get_frame` returns a `StoredFrame` (`atoms[i]` builds that atom only). Gzip and zstd files are read with `readcon.read_con`, then appended. Python `append_trajectory` and Rust `append_trajectory_path` read UTF-8 and do not decompress. `readcon-db` does not register an `ase.ioformats` entry point. Guide: [`docs/orgmode/howto/streaming.org`](docs/orgmode/howto/streaming.org). Upgrade from 0.2.0: [`docs/orgmode/howto/migration.org`](docs/orgmode/howto/migration.org).
|
|
77
|
+
|
|
76
78
|
## Design
|
|
77
79
|
|
|
78
80
|
- **No SQL engine** — explicit indexes + in-process intersection, with **ASE.db-competitive screening fields** (mass, volume, PBC, reserved metadata, charge/magmom; see [design matrix](docs/orgmode/explanation/design.org)).
|
|
@@ -106,6 +108,11 @@ Foreign trajectories: **`readcon.read_chemfiles("traj.xyz")` → frames → inge
|
|
|
106
108
|
|
|
107
109
|
Full ABI table, logo, Sphinx docs, and site: see `docs/`, `website/`, `assets/logo/`, `CHANGELOG.md`. Fortran module notes: `fortran/README.md`, `fortran/ReadConDb/`.
|
|
108
110
|
|
|
111
|
+
## Questions and bug reports
|
|
112
|
+
|
|
113
|
+
Ask questions and report bugs on the [GitHub issue tracker](https://github.com/lode-org/readcon-db/issues).
|
|
114
|
+
Report a security problem by email instead, as [`SECURITY.md`](SECURITY.md) describes.
|
|
115
|
+
|
|
109
116
|
## License
|
|
110
117
|
|
|
111
118
|
MIT
|
|
@@ -39,8 +39,8 @@ pixi lock
|
|
|
39
39
|
| Prek | =ci_prek.yml= | push, PR | =prek run -a= |
|
|
40
40
|
| Documentation | =ci_docs.yml= | push, PR | Locked Sphinx HTML (=pixi.lock=) + assembled site + lychee |
|
|
41
41
|
| Pages | =pages.yml= | push to main | Deploy site + locked Sphinx docs |
|
|
42
|
-
| Lint | =lint.yml= | PR | Conventional commits
|
|
43
|
-
| Version lockstep | =scripts/check_version_lockstep.
|
|
42
|
+
| Lint | =lint.yml= | PR | Conventional commits; version copies match Cargo.toml |
|
|
43
|
+
| Version lockstep | =scripts/check_version_lockstep.py= | =lint.yml=, =set-version.sh= | Each copy parsed and compared with Cargo.toml; readcon-core pin |
|
|
44
44
|
| C/C++ dist | =ci_cxx.yml= | push, PR | CMake/Meson/pkg-config without cbindgen; clib fixture gate |
|
|
45
45
|
| crates.io | =crates_publish.yml= | =v*= tag | =cargo publish --locked= |
|
|
46
46
|
| Python wheels | =python-wheels.yml= | =v*= tag, PR | maturin matrix → PyPI |
|
|
@@ -1,13 +1,17 @@
|
|
|
1
|
-
#+
|
|
2
|
-
#+options: toc:2
|
|
1
|
+
#+OPTIONS: toc:nil num:nil
|
|
3
2
|
|
|
4
|
-
*
|
|
3
|
+
* Cooked structure-of-arrays (SoA) tier (=RCSO= / =frames_soa=)
|
|
4
|
+
:PROPERTIES:
|
|
5
|
+
:CUSTOM_ID: cooked-soa
|
|
6
|
+
:END:
|
|
7
|
+
|
|
8
|
+
** Contract
|
|
5
9
|
|
|
6
10
|
RCSO is *non-authoritative*. CON text in =frames= is the sole authority
|
|
7
11
|
for hash, dedup, join/split, =reindex=, and CON export. Cooked numerics
|
|
8
12
|
in =frames_soa= are derived POD only; they never replace the text tier.
|
|
9
13
|
|
|
10
|
-
|
|
14
|
+
** Summary
|
|
11
15
|
|
|
12
16
|
=readcon-db= stores two tiers per frame key:
|
|
13
17
|
|
|
@@ -18,11 +22,11 @@ in =frames_soa= are derived POD only; they never replace the text tier.
|
|
|
18
22
|
|
|
19
23
|
*Default ingest does not cook.* Call =cook_frame= / =recook_all= / CLI =cook-frame= / =recook-all= (or =append_trajectory_path_cook(..., true)= in Rust) to populate RCSO. =delete_cooked_soa= drops only the cooked tier; CON text and indexes stay.
|
|
20
24
|
|
|
21
|
-
|
|
25
|
+
** Why the =.con= text is still required
|
|
22
26
|
|
|
23
27
|
RCSO is *not* fully equivalent to CON: it omits element symbols, masses, cell/angles, constraints, JSON metadata, and exact on-disk bytes. Those are required for xxHash3 dedup, symbol/formula indexes, =reindex=, join/split, and CON export. Do *not* omit =frames= when cooked exists.
|
|
24
28
|
|
|
25
|
-
|
|
29
|
+
** Numeric hot path
|
|
26
30
|
|
|
27
31
|
=get_positions= / =get_forces= / =get_velocities= (Rust, Python, C
|
|
28
32
|
=rkrdb_get_positions= / =rkrdb_get_forces= / =rkrdb_get_velocities=, CLI
|
|
@@ -31,7 +35,7 @@ Missing or corrupt cooked falls back to parsing CON text. Authority APIs
|
|
|
31
35
|
(=frame_hash=, =find_by_hash=, =get_frame_text=, =reindex=, shard join)
|
|
32
36
|
never read =frames_soa=.
|
|
33
37
|
|
|
34
|
-
|
|
38
|
+
** Language surfaces
|
|
35
39
|
|
|
36
40
|
| Surface | Cook / delete / has-valid | Positions / forces / velocities |
|
|
37
41
|
|---------+---------------------------+--------------------------------|
|
|
@@ -41,7 +45,7 @@ never read =frames_soa=.
|
|
|
41
45
|
| Fortran | =db_cook_frame=, =db_delete_cooked=, =db_has_valid_cooked=, =db_recook_all= | =db_get_positions=, =db_get_forces=, =db_get_velocities= |
|
|
42
46
|
| CLI | =cook-frame=, =delete-cooked=, =recook-all= | =positions= |
|
|
43
47
|
|
|
44
|
-
|
|
48
|
+
** See also
|
|
45
49
|
|
|
46
|
-
- Internal design notes:
|
|
47
|
-
- Architecture
|
|
50
|
+
- Internal design notes: @@rst::doc:`/explanation/design`@@ (engineer-facing; mirrors this contract)
|
|
51
|
+
- Architecture summary: @@rst::doc:`/explanation/architecture`@@
|
|
@@ -35,6 +35,8 @@ Environment (Heed / LMDB)
|
|
|
35
35
|
├── idx_formula : `Cu:2|H:2` ‖ 0xFF ‖ FrameKey
|
|
36
36
|
├── idx_topo : topology-key utf-8 ‖ 0xFF ‖ FrameKey # optional; empty if missing on readonly
|
|
37
37
|
├── topo_by_frame : FrameKey → topology key # optional; authority for matching reindex
|
|
38
|
+
├── idx_canon : version ‖ canonical xxh3-128 ‖ FrameKey # optional; atom-id order
|
|
39
|
+
├── canon_by_frame : FrameKey → version ‖ canonical hash ‖ content hash
|
|
38
40
|
├── idx_flags : (flag_id ‖ FrameKey) → () # forces / velocities / has_energy
|
|
39
41
|
├── frame_by_hash : xxh3-128 → FrameKey (first wins)
|
|
40
42
|
├── frames_soa : FrameKey → RCSO cooked numerics (optional, derived)
|
|
@@ -43,13 +45,18 @@ Environment (Heed / LMDB)
|
|
|
43
45
|
|
|
44
46
|
=idx_topo= and =topo_by_frame= are created on write-open. A readonly open of an older corpus that lacks them treats the topology index as empty.
|
|
45
47
|
|
|
48
|
+
=idx_canon= and =canon_by_frame= are created on write-open and stay empty until =index_canonical_identity=. The version byte is 1: atoms in increasing =atom_id= order, then xxHash3-128 of the canonical CON writer bytes. The content hash in =hash_by_frame= is still the stored CON bytes. A readonly open of an older corpus that lacks the two databases has no canonical index. See @@rst::doc:`/howto/atom-order`@@.
|
|
49
|
+
|
|
46
50
|
=TrajMeta= may record =topo_cutoff=, =topo_graph=, =topo_hops=, and =topo_method= after =annotate_topology=. Those fields have serde defaults so old JSON still loads. Ingest and extend preserve them.
|
|
47
51
|
|
|
48
52
|
*H5MD interchange:* =collect_h5md= / =export_h5md= emit one =[T][N][3]= trajectory (position, optional force and velocity). CON text stays authority. Dest units are Å / ps / kJ mol^{-1} Å^{-1}; velocity dest is =Angstrom ps-1=. Velocities follow D10: v1, v2, and v3.0 use the natural unit whatever the time label says; v3.1 uses =units.time=. A v3.1 clock with no =units.time= is an error. v1, v2, and v3.0 clocks with no =units.time= are read as =fs=.
|
|
49
53
|
|
|
50
54
|
*Drain/join:* node-local =shard-ingest=, =drain_to= compact-snapshots =data.mdb= (refuse overwrite), then =join-drained=. =compact-join= is the single-root join (=open_existing=). Ops: @@rst::doc:`/howto/campaign`@@.
|
|
51
55
|
|
|
52
|
-
*Cooked SoA tier:* optional RCSO in =frames_soa= accelerates =get_positions= / =get_forces= / =get_velocities= without
|
|
56
|
+
*Cooked SoA tier:* optional =RCSO= in =frames_soa= accelerates =get_positions= / =get_forces= / =get_velocities= without a =.con= parse when valid.
|
|
57
|
+
=RCSO= is non-authoritative: the =.con= text in =frames= remains sole authority for hash/dedup/join/reindex.
|
|
58
|
+
=RCSO= is not fully equivalent (no symbols/metadata/exact bytes).
|
|
59
|
+
See @@rst::doc:`/cooked-soa`@@.
|
|
53
60
|
|
|
54
61
|
=FrameKey= is 12 bytes: =traj_id= (BE u64) + =frame_idx= (BE u32) so lexicographic order matches numeric order.
|
|
55
62
|
|
|
@@ -0,0 +1,87 @@
|
|
|
1
|
+
#+OPTIONS: toc:nil num:nil
|
|
2
|
+
|
|
3
|
+
* How-to: atom-id identity
|
|
4
|
+
:PROPERTIES:
|
|
5
|
+
:CUSTOM_ID: how-to-atom-id-identity
|
|
6
|
+
:END:
|
|
7
|
+
The content hash is xxHash3-128 of the stored CON bytes. CON writes one element block per run, in the order the elements were first seen, so the same atoms with the same =atom_id= values are a different hash when a later file emits oxygen before carbon. Column 5 is that id. It stays with the atom.
|
|
8
|
+
|
|
9
|
+
The canonical identity is optional. It reorders the rows into increasing =atom_id= and hashes that text. =hash_by_frame= and =frame_by_hash= are not modified, and a corpus that never runs the indexer has no new keys.
|
|
10
|
+
|
|
11
|
+
** What is stored
|
|
12
|
+
:PROPERTIES:
|
|
13
|
+
:CUSTOM_ID: what-is-stored
|
|
14
|
+
:END:
|
|
15
|
+
Version 1 is the byte in front of the hash.
|
|
16
|
+
|
|
17
|
+
- =canon_by_frame= maps a 12-byte =FrameKey= to the version byte, the 16-byte canonical hash, and the 16-byte content hash taken when the frame was indexed.
|
|
18
|
+
- =idx_canon= maps version byte, canonical hash, and =FrameKey= to an empty value. A prefix scan on the version and the hash returns every stored frame with that identity.
|
|
19
|
+
|
|
20
|
+
The canonical bytes are the CON writer in canonical mode: round-trip floats, metadata keys sorted. The row order is =reorder_like= into increasing =atom_id=, with the strict check (symbol, mass within 1e-8, and fixed mask). A duplicate =atom_id= is an error before anything is hashed. A readonly open of an older corpus that lacks these two databases has no canonical index.
|
|
21
|
+
|
|
22
|
+
** Index a corpus
|
|
23
|
+
:PROPERTIES:
|
|
24
|
+
:CUSTOM_ID: index-a-corpus
|
|
25
|
+
:END:
|
|
26
|
+
#+begin_src sh
|
|
27
|
+
readcon-db ingest /tmp/corpus reactant.con
|
|
28
|
+
readcon-db index-canonical /tmp/corpus
|
|
29
|
+
#+end_src
|
|
30
|
+
|
|
31
|
+
Rust:
|
|
32
|
+
|
|
33
|
+
#+begin_src rust
|
|
34
|
+
use readcon_db::ConCorpus;
|
|
35
|
+
|
|
36
|
+
let db = ConCorpus::open("/tmp/corpus")?;
|
|
37
|
+
db.append_trajectory_path(1, "reactant.con")?;
|
|
38
|
+
db.index_canonical_identity()?;
|
|
39
|
+
#+end_src
|
|
40
|
+
|
|
41
|
+
Python:
|
|
42
|
+
|
|
43
|
+
#+begin_src python
|
|
44
|
+
db.index_canonical_identity()
|
|
45
|
+
#+end_src
|
|
46
|
+
|
|
47
|
+
Ingest does not fill the index. =set_trajectory_units=, or any other rewrite of the stored CON text, leaves the index stale. Run =index-canonical= again. =reindex= rebuilds the content-hash indexes and leaves this one in place.
|
|
48
|
+
|
|
49
|
+
** Look up a reordered frame
|
|
50
|
+
:PROPERTIES:
|
|
51
|
+
:CUSTOM_ID: look-up-a-reordered-frame
|
|
52
|
+
:END:
|
|
53
|
+
#+begin_src sh
|
|
54
|
+
readcon-db find-by-atom-order /tmp/corpus product.con
|
|
55
|
+
#+end_src
|
|
56
|
+
|
|
57
|
+
A hit is one line:
|
|
58
|
+
|
|
59
|
+
#+begin_src text
|
|
60
|
+
query 0: traj=1 frame=0 permutation=1,2,0
|
|
61
|
+
#+end_src
|
|
62
|
+
|
|
63
|
+
=query= is the zero-based frame in the file. =permutation[i]= is the index in that query frame of the atom whose =atom_id= equals stored atom =i=. That is =atom_id_permutation= with the stored frame as the reference. No hit prints =query 0: 0 keys=.
|
|
64
|
+
|
|
65
|
+
Rust and Python return the same permutation as a list of indexes:
|
|
66
|
+
|
|
67
|
+
#+begin_src rust
|
|
68
|
+
let hits = db.find_by_atom_order_path("product.con")?;
|
|
69
|
+
let perm = &hits[0].permutation;
|
|
70
|
+
#+end_src
|
|
71
|
+
|
|
72
|
+
#+begin_src python
|
|
73
|
+
hits = db.find_by_atom_order_path("product.con")
|
|
74
|
+
perm = hits[0].permutation
|
|
75
|
+
#+end_src
|
|
76
|
+
|
|
77
|
+
=find_by_atom_order= takes CON text instead of a path. =frame_canonical_identity(traj_id, frame_idx)= recomputes the version and the hash from the stored text and does not read the index.
|
|
78
|
+
|
|
79
|
+
A coordinate that moved, including one stored a cell away, is a different canonical hash. This lookup does not wrap displacements.
|
|
80
|
+
|
|
81
|
+
** Errors
|
|
82
|
+
:PROPERTIES:
|
|
83
|
+
:CUSTOM_ID: errors
|
|
84
|
+
:END:
|
|
85
|
+
Duplicate ids, an id present on only one of the two frames, and a symbol mismatch fail with a message that names the =atom_id=. The strict check also names a mass or fixed-mask mismatch. A corpus with frames and an empty canonical index, a count that no longer matches the frame count, or a stored content hash that no longer matches the indexed one, fails with a message that names =index-canonical=.
|
|
86
|
+
|
|
87
|
+
The content hash is unchanged by a successful index. =find_by_hash= and =Select::exact_hash= still mean byte-for-byte CON text.
|
|
@@ -114,7 +114,7 @@ ConCorpus("/lustre/orion/proj/campaign_single", readonly=True).export_h5md(1, "t
|
|
|
114
114
|
:PROPERTIES:
|
|
115
115
|
:CUSTOM_ID: units
|
|
116
116
|
:END:
|
|
117
|
-
Stamp units on ingest (=--units= JSON, or C =rkrdb_append_trajectory_units= / Fortran =db_append_units=). Aliases canonicalize (=A= -> =angstrom=). =set_units= converts stored numbers
|
|
117
|
+
Stamp units on ingest (=--units= JSON, or C =rkrdb_append_trajectory_units= / Fortran =db_append_units=). Aliases canonicalize (=A= -> =angstrom=). =set_units= converts stored numbers and refuses a v3.1 clock or velocities frame with no =units.time= instead of assuming =fs=; append/extend stamp incoming values. CON line-2 =units= is the authority for length, energy, and the clock. A v3.1 frame with =time= or =timestep= and no =units.time= is an error. =--velocity-time-unit= supplies that missing clock unit and overrides the D10 velocity rule for a file that breaks it. A present =units.time= still scales the clock. v1, v2, and v3.0 clocks with no =units.time= are read as =fs=. H5MD velocities follow D10: v1, v2, and v3.0 use the natural unit =(amu*angstrom^2/eV)^0.5= whatever the time label says; v3.1 uses =units.time= and fails when velocities have no =units.time=.
|
|
118
118
|
|
|
119
119
|
** C / Fortran writers
|
|
120
120
|
:PROPERTIES:
|
|
@@ -44,17 +44,17 @@ Exact match: =Select::new().exact_hash(h.to_bytes())=.
|
|
|
44
44
|
:CUSTOM_ID: python
|
|
45
45
|
:END:
|
|
46
46
|
#+begin_src python
|
|
47
|
-
import
|
|
48
|
-
|
|
49
|
-
db =
|
|
50
|
-
db.
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
h = db.frame_hash(
|
|
54
|
-
text = db.get_frame_text(
|
|
47
|
+
from readcon_db import ConCorpus
|
|
48
|
+
|
|
49
|
+
db = ConCorpus("/tmp/corpus")
|
|
50
|
+
db.append_trajectory(1, "run.con")
|
|
51
|
+
keys = db.select(symbol="Cu")
|
|
52
|
+
traj_id, frame_idx = keys[0]
|
|
53
|
+
h = db.frame_hash(traj_id, frame_idx)
|
|
54
|
+
text = db.get_frame_text(traj_id, frame_idx)
|
|
55
55
|
#+end_src
|
|
56
56
|
|
|
57
|
-
=maturin develop --features python= from a checkout. Module name is =readcon_db=.
|
|
57
|
+
=maturin develop --features python= from a checkout. Module name is =readcon_db=. Streaming append, =StoredFrame=, and compressed files: @@rst::doc:`/howto/streaming`@@. The 0.2.1 changes: @@rst::doc:`/howto/migration`@@.
|
|
58
58
|
|
|
59
59
|
** C / C++
|
|
60
60
|
:PROPERTIES:
|
|
@@ -63,12 +63,21 @@ text = db.get_frame_text(keys[0])
|
|
|
63
63
|
#+begin_src C
|
|
64
64
|
#include "readcon-db.h"
|
|
65
65
|
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
66
|
+
size_t id;
|
|
67
|
+
uint32_t n_frames;
|
|
68
|
+
rkrdb_open("/tmp/corpus", &id);
|
|
69
|
+
rkrdb_append_trajectory(id, 1, "run.con", &n_frames);
|
|
70
|
+
/* traj_id -1 matches every trajectory; limit 0 means no limit */
|
|
71
|
+
rkrdb_select_basic(id, -1, "Cu", 0, UINT32_MAX, 0);
|
|
72
|
+
for (int i = 0; i < rkrdb_result_count(id); i++) {
|
|
73
|
+
uint64_t traj;
|
|
74
|
+
uint32_t frame;
|
|
75
|
+
rkrdb_result_key(id, i, &traj, &frame);
|
|
76
|
+
}
|
|
77
|
+
rkrdb_close(id);
|
|
70
78
|
#+end_src
|
|
71
79
|
|
|
80
|
+
Each call returns =RKRDB_OK= on success, and =rkrdb_last_error= copies the message of the last failure into a caller buffer.
|
|
72
81
|
C++ RAII: =readcon_db::Corpus=. MPI pack/bcast takes the *caller* communicator (=readcon-db-mpi.h=). The library does not call =MPI_Init=. Details: @@rst::doc:`/reference/c`@@.
|
|
73
82
|
|
|
74
83
|
** Fortran
|
|
@@ -14,7 +14,7 @@ cargo add readcon-db
|
|
|
14
14
|
cargo install readcon-db --locked
|
|
15
15
|
#+end_src
|
|
16
16
|
|
|
17
|
-
|
|
17
|
+
Pulls in [[https://crates.io/crates/readcon-core][readcon-core]] at the version requirement ~{{{readcon-core-req}}}~ from =Cargo.toml=.
|
|
18
18
|
|
|
19
19
|
** Python (PyPI)
|
|
20
20
|
:PROPERTIES:
|
|
@@ -38,7 +38,8 @@ cargo test --locked
|
|
|
38
38
|
cargo build --release # libreadcon_db + CLI readcon-db
|
|
39
39
|
#+end_src
|
|
40
40
|
|
|
41
|
-
=readcon-core= comes from crates.io (
|
|
41
|
+
=readcon-core= comes from crates.io (~{{{readcon-core-req}}}~).
|
|
42
|
+
Add an *untracked* =.cargo/config.toml= with the patch below to build against a local core tree.
|
|
42
43
|
|
|
43
44
|
#+begin_src toml
|
|
44
45
|
[patch.crates-io]
|
|
@@ -64,7 +65,7 @@ CMake:
|
|
|
64
65
|
include(FetchContent)
|
|
65
66
|
FetchContent_Declare(
|
|
66
67
|
readcon-db
|
|
67
|
-
URL https://github.com/lode-org/readcon-db/releases/download/
|
|
68
|
+
URL https://github.com/lode-org/readcon-db/releases/download/v{{{readcon-db-version}}}/readcon-db-cxx-{{{readcon-db-version}}}.tar.gz
|
|
68
69
|
URL_HASH SHA256=<sha256 from the .sha256 sidecar on the GitHub Release>
|
|
69
70
|
)
|
|
70
71
|
FetchContent_MakeAvailable(readcon-db)
|
|
@@ -91,7 +92,7 @@ A process that uses both C APIs must link the *shared* objects (=libreadcon_db.s
|
|
|
91
92
|
Unpack =readcon-db-clib-$VERSION-$target.tar.gz= from the GitHub Release, then =export READCON_DB_LIB= / =PKG_CONFIG_PATH=. Attach assets to an already-published tag with Actions → *C ABI library tarball* → ~tag=vX.Y.Z~.
|
|
92
93
|
|
|
93
94
|
#+begin_src sh
|
|
94
|
-
VER=
|
|
95
|
+
VER={{{readcon-db-version}}}
|
|
95
96
|
TARGET=x86_64-unknown-linux-gnu
|
|
96
97
|
curl -fsSL -O "https://github.com/lode-org/readcon-db/releases/download/v${VER}/readcon-db-clib-${VER}-${TARGET}.tar.gz"
|
|
97
98
|
tar -xzf "readcon-db-clib-${VER}-${TARGET}.tar.gz"
|
|
@@ -137,7 +138,8 @@ Campaign shard/drain/join is the =readcon-db= CLI (in =bin/= of the clib tarball
|
|
|
137
138
|
pixi r -e docs docbld
|
|
138
139
|
#+end_src
|
|
139
140
|
|
|
140
|
-
=pixi.lock= pins Sphinx,
|
|
141
|
+
=pixi.lock= pins Sphinx, Shibuya, and Markedly Structured Text (MyST) to the same set Pages publishes.
|
|
142
|
+
Refresh with =pixi lock= after editing =pixi.toml= =[feature.docs]=.
|
|
141
143
|
|
|
142
144
|
** Static marketing page
|
|
143
145
|
:PROPERTIES:
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
#+OPTIONS: toc:nil num:nil
|
|
2
|
+
|
|
3
|
+
* Migrating to 0.2.1
|
|
4
|
+
:PROPERTIES:
|
|
5
|
+
:CUSTOM_ID: migrating-to-0-2-1
|
|
6
|
+
:END:
|
|
7
|
+
|
|
8
|
+
0.2.1 keeps the same corpus files as 0.2.0. Two Python calls behave differently. Rust =get_frame= still returns a =readcon_core::ConFrame=. Rust =append_trajectory_frames= still commits the slice you pass in one transaction.
|
|
9
|
+
|
|
10
|
+
** =get_frame= returns a =StoredFrame=
|
|
11
|
+
:PROPERTIES:
|
|
12
|
+
:CUSTOM_ID: get-frame-returns-a-storedframe
|
|
13
|
+
:END:
|
|
14
|
+
In 0.2.0, Python =get_frame= parsed the stored text with =readcon.read_con_string= and returned a =readcon.ConFrame=. Reading =atoms= on that object built a Python atom for every site.
|
|
15
|
+
|
|
16
|
+
In 0.2.1 it returns a =StoredFrame=:
|
|
17
|
+
|
|
18
|
+
| Still works | =frame.xyz=, =frame.atoms[i].symbol=, =frame.atoms[i].x= / =y= / =z=, =frame.cell=, =frame.angles=, =len(frame)= |
|
|
19
|
+
| Changed | =type(frame)= is =StoredFrame=, not =ConFrame=. There is no =to_ase=, no metadata dict, and no velocity or force attributes on =StoredAtom=. |
|
|
20
|
+
|
|
21
|
+
=atoms[i]= builds that one atom. Use =get_frame_text= when you need the text, and =readcon.read_con_string= when you need a =ConFrame=:
|
|
22
|
+
|
|
23
|
+
#+begin_src python
|
|
24
|
+
text = db.get_frame_text(traj_id, frame_idx)
|
|
25
|
+
frame = readcon.read_con_string(text)[0]
|
|
26
|
+
#+end_src
|
|
27
|
+
|
|
28
|
+
Positions, forces, and velocities are also still on =get_positions=, =get_forces=, and =get_velocities=.
|
|
29
|
+
|
|
30
|
+
** Append commits 64 frames at a time
|
|
31
|
+
:PROPERTIES:
|
|
32
|
+
:CUSTOM_ID: append-commits-64-frames-at-a-time
|
|
33
|
+
:END:
|
|
34
|
+
In 0.2.0, Python =append_trajectory_frames= turned the whole trajectory into one CON string, then prepared and committed every frame in one transaction. The string and the prepared rows were resident together, and walking a =read_con= result built a Python frame for every index.
|
|
35
|
+
|
|
36
|
+
In 0.2.1 the same call commits groups of 64 frames. The first group creates the trajectory. Each later group extends it. The return value is still the number of frames in the trajectory after the last commit. A =read_con= list is serialized from the parser's stored frames, so those Python frames are not built.
|
|
37
|
+
|
|
38
|
+
Python =append_trajectory= and Rust =append_trajectory_path= are unchanged: they read the path as UTF-8 and do not decompress gzip or zstd. Compressed files go through =readcon.read_con=, then =append_trajectory_frames=. The guide is @@rst::doc:`/howto/streaming`@@.
|