drcutils is a shared utility package for Design Research Collective lab members.
It is intended primarily for internal lab workflows where consistent branding, figure export, and lightweight runtime/data helpers are needed across projects.
This package currently focuses on:
- DRC brand assets, palettes, and watermarking helpers
- publication-ready figure export presets
- CAD and model-visualization wrappers
- file conversion and runtime environment detection utilities
Requires Python 3.12+.
Reproducible release installs are pinned to Python 3.12.12 (.python-version).
python -m venv .venv
source .venv/bin/activate
make dev
make testimport matplotlib.pyplot as plt
from drcutils.data import convert
from drcutils.runtime import is_notebook
from drcutils.viz import export_figure
convert("inputs/data.csv", "artifacts/data.json")
fig, ax = plt.subplots()
ax.plot([0, 1, 2], [0, 1, 4])
result = export_figure(
fig,
"artifacts/figures/main_result",
targets=["one_col", "slide_16x9"],
formats=["pdf", "png"],
)
print(is_notebook())
print(result["files"])See the published documentation for usage guides and API reference.
Build docs locally with:
make docs-buildContribution workflow and quality gates are documented in CONTRIBUTING.md.