Synthetic 3D ore-body block models of the MineLib nature: seeded deposit archetypes, bench structure, slope precedence, UPIT economics, an exact max-closure solver, extraction states with loading faces, and MineLib .blocks/.prec/.upit read/write
Project description
oreblocks
Synthetic 3-D ore-body block models of the MineLib nature — seeded deposit archetypes with
per-block grades, bench (level) structure, slope precedence, UPIT economics with per-block optimal
destination, an exact max-closure solver, extraction states with loading faces, and MineLib
.blocks/.prec/.upit read/write. Deterministic given a seed; every generated instance is
clearly labelled SYNTHETIC.
Why: per-block ground truth on real mines is licensed or proprietary (MineLib grants academic download only, no redistribution). oreblocks generates instances of the same nature — 3-D benches, grades, precedence, net values — with a stamped exact optimum, so solvers, dispatch simulators and teaching apps get license-free realistic instances with known-by-construction answers.
Install
pip install oreblocks
Quickstart — a MineLib-format twin with a stamped optimum
from oreblocks import make_twin
twin = make_twin("porphyry", dims=(20, 20, 10), seed=42)
print(twin.upit.pit_value, twin.upit.n_in_pit) # the EXACT optimum, stamped
twin.write("out/") # -> twin-*.blocks / .prec / .upit / .meta.json (MineLib format)
The emitted triplet is byte-consumable by any MineLib UPIT reader. Cross-validated against an independent TypeScript min-cut engine (CAOS PitForge, which reproduces the published newman1 / zuck_small / kd optima): relative disagreement ~1e-11 on a 4,000-block twin.
Pieces
| Module | What |
|---|---|
BlockGrid |
regular grid; LEVELS increase upward (the MineLib convention) |
make_deposit |
seeded archetypes: porphyry, vein, layered, core_halo (trend + correlated noise) |
Econ / block_values |
UPIT net value at the optimal destination (floating cutoff = the max) |
build_precedence |
slope-cone template one level up (45° cubic → the classic 9-point), CSR |
solve_upit |
exact Picard max-closure → Dinic min-cut; closure + value-identity self-checks |
extraction_state / loading_faces |
top-down bench extraction + seeded k-means shovel faces (grade at face, ore fraction, tonnes) — the bridge to haulage simulators |
write_minelib / read_* |
the .blocks/.prec/.upit triplet + a meta sidecar with the stamped optimum |
Convention notes
- Levels (z) increase upward: level 0 is the deepest bench — exactly how published MineLib
instances index (verified against newman1). Depth-down viewers flip with
z_down = nz-1-level. .blocksfree columns written by oreblocks are documented in the meta sidecar:grade (mass fraction) · tonnage (t) · density (t/m³).- Nothing here downloads or redistributes published MineLib data.
Used by
- minehaulsim (haulage DES) — geology-grounded scenarios: loading faces with grade/bench.
- CAOS PitForge — license-free synthetic twins next to the published-instance lane.
License
Apache-2.0.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file oreblocks-0.1.0.tar.gz.
File metadata
- Download URL: oreblocks-0.1.0.tar.gz
- Upload date:
- Size: 23.6 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
0ef75a278404d1907d8b73855e0e4b9b252612bd5f309aeaa2150100de44d8fa
|
|
| MD5 |
a2e58a1d61aa3f0e000355573a15be3e
|
|
| BLAKE2b-256 |
25251550789c43c2bfba0c4ef9731631ebf8513a99802bd3fdf13e0a47d8a5b4
|
Provenance
The following attestation bundles were made for oreblocks-0.1.0.tar.gz:
Publisher:
publish-pypi.yml on fsantibanezleal/CAOS_OreBlocks
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
oreblocks-0.1.0.tar.gz -
Subject digest:
0ef75a278404d1907d8b73855e0e4b9b252612bd5f309aeaa2150100de44d8fa - Sigstore transparency entry: 2064662923
- Sigstore integration time:
-
Permalink:
fsantibanezleal/CAOS_OreBlocks@58c5969428b174a62a394efbba0a52901d979ad3 -
Branch / Tag:
refs/tags/v0.1.0 - Owner: https://github.com/fsantibanezleal
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish-pypi.yml@58c5969428b174a62a394efbba0a52901d979ad3 -
Trigger Event:
release
-
Statement type:
File details
Details for the file oreblocks-0.1.0-py3-none-any.whl.
File metadata
- Download URL: oreblocks-0.1.0-py3-none-any.whl
- Upload date:
- Size: 23.6 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
0dd1e81b1cae5d24103d8bef698cc39a7bcaa002bcb866b9b00151f8596b69a4
|
|
| MD5 |
86c979b2dc334ea2ae327d53ba340521
|
|
| BLAKE2b-256 |
220b3ce780f836f052d07bef7d10f6a7735415ab5d80989687a64cebc7c1686e
|
Provenance
The following attestation bundles were made for oreblocks-0.1.0-py3-none-any.whl:
Publisher:
publish-pypi.yml on fsantibanezleal/CAOS_OreBlocks
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
oreblocks-0.1.0-py3-none-any.whl -
Subject digest:
0dd1e81b1cae5d24103d8bef698cc39a7bcaa002bcb866b9b00151f8596b69a4 - Sigstore transparency entry: 2064662933
- Sigstore integration time:
-
Permalink:
fsantibanezleal/CAOS_OreBlocks@58c5969428b174a62a394efbba0a52901d979ad3 -
Branch / Tag:
refs/tags/v0.1.0 - Owner: https://github.com/fsantibanezleal
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish-pypi.yml@58c5969428b174a62a394efbba0a52901d979ad3 -
Trigger Event:
release
-
Statement type: