Development
Local Setup
python3 -m pip install -e ".[test,export]"
Run tests:
.venv/bin/python -m pytest -q
Repository Layout
src/pyoncoplot/ package code
tests/ pytest suite
docs/ Markdown documentation
plans/ implementation plans
python_refactor_goal_sources/ gallery scripts and training source tree
python_refactor_goal_sources/config.yaml config-driven gallery run definitions
python_refactor_goal_sources/make_oncoplots.py direct oncoplot() gallery renderer
python_refactor_goal_sources/goal_plots/ numbered source/reference plots
python_refactor_goal_sources/fuc_sources/ fuc source scripts and fixture rebuild helper
python_refactor_goal_sources/syntheitic_goal_data/ deterministic TSV/JSON gallery inputs
Regenerate Gallery Inputs
python3 python_refactor_goal_sources/generate_synthetic_inputs.py
This rewrites deterministic non-fuc TSV/JSON files under:
python_refactor_goal_sources/syntheitic_goal_data/
The generator reads output filenames and deterministic non-fuc generation
settings from gallery_params.input_files and
gallery_params.synthetic_inputs in python_refactor_goal_sources/config.yaml.
The AML fuc fixtures are rebuilt separately after downloading the upstream
fuc-data source files listed in
python_refactor_goal_sources/fuc_sources/manifest.json:
python3 python_refactor_goal_sources/fuc_sources/rebuild_fuc_fixtures.py --source-dir /path/to/fuc-data
Regenerate Gallery Images
python3 python_refactor_goal_sources/recreate_gallery.py
python3 python_refactor_goal_sources/recreate_gallery.py --style comparison --preset brca_large
Generated gallery images are tracked when intentionally updated.
Adding A Gallery Preset
Add or extend synthetic input settings in
python_refactor_goal_sources/config.yaml, or fuc-derived inputs inpython_refactor_goal_sources/fuc_sources/rebuild_fuc_fixtures.py.Commit the generated TSV/JSON inputs.
Use
renderer: oncoplot; active gallery goals must be expressible through publiconcoplot()params.Add the named run to
python_refactor_goal_sources/config.yamlundergallery_params.plot_runs.Add or update tests in
tests/test_gallery.py.Document the preset in Gallery.
The generic oncoplot renderer reads params.oncoplot from config and passes it
to the public API. Keep runtime choices such as genes, metadata tracks, legend
controls, expected dimensions, output names, and save DPI in YAML.
Documentation Changes
Docs are Markdown-first. Keep examples runnable from the repository root unless the page says otherwise.
After editing docs:
.venv/bin/python -m pytest -q
The docs test checks that required pages exist and that local Markdown links resolve.