Albucore Public API
Star Import
from albucore import * follows albucore/__init__.py, which merges __all__ from functions, decorators, geometric, and utils, plus metadata.
Most routers live in albucore/functions.py __all__, re-exported from arithmetic, lut, normalize, convert, ops_misc, and stats. Geometric routers live in albucore/geometric.py __all__ and are separately merged by package __init__; resize3d is one such router.
Classification Doc
Use docs/public-api.md for router classification and explicit from albucore.functions import ... shims such as *_opencv, *_numpy, NumKong helpers, and LUT plumbing.
Dependents
If Albumentations or another downstream package imports a symbol, it must be either:
- On package
__all__for star-import compatibility, or - Documented with an explicit import path such as
albucore.functions.
Example: sz_lut and apply_uint8_lut are public routers on __all__ and are implemented in albucore/lut.py.
Adding an Export
- Implement in the appropriate submodule (
arithmetic.py,lut.py,geometric.py, etc.). - For a regular router, ensure
from submodule import *infunctions.pyexposes the name and append it tofunctions.__all__, sorted or grouped with peers. - For a geometric router, append it to
geometric.__all__; do not add a compatibility shim tofunctions.pyunless there is a separate public-API decision. - Confirm
from albucore import <name>succeeds and that the name occurs once in package__all__. - Update
docs/public-api.mdif classification changes.