Skip to content

7. Packaging and CI - #7

Merged
dadudu13 merged 3 commits into
mainfrom
pr/7-packaging-ci
Oct 21, 2026
Merged

dadudu13 merged 3 commits into
mainfrom
pr/7-packaging-ci

Conversation

@dadudu13

Copy link
Copy Markdown
Owner

Makes the repository installable and tested by someone who has never seen it.

  • pyproject.toml declares what importing ddh needs. auton-survival is installed from its 0.1.0 release commit with --no-deps, because its PyPI metadata pins torch<2.0. This was verified in a clean environment from a standalone clone.
  • Removed the unused DeepSurvivalMachines submodule; its SSH URL broke recursive clones.
  • .gitignore refuses tabular and model-artifact formats.
  • GitHub Actions runs the tests on Python 3.11 and 3.12 with exactly the README's install steps.
  • Docstrings and test names describe causes generically (cause 1 = event of interest, cause 2 = competing event). No behaviour changes.

A few docstrings and test comments named the clinical outcome this was
first built for, a private evaluation pipeline, or a cohort statistic.
None of it is needed to read the code: cause 1 is the event of interest,
cause 2 the competing event, and the horizon term's labels mirror the
landmark evaluation. Renames test_labels_and_weights_match_v3_evaluation
to ..._match_landmark_evaluation. No behaviour changes.
…module

Nothing imports from the DeepSurvivalMachines submodule since the switch
to auton-survival, and its SSH URL made a recursive clone fail without
GitHub keys. Remove it.

pyproject.toml makes `pip install -e .` work and lists what importing ddh
needs: torch, numpy and tqdm for the model, plus the packages
auton-survival imports when it loads. auton-survival itself is not a
declared dependency: its only PyPI release pins torch<2.0, so the README
installs it from source with --no-deps. That combination was checked in a
clean virtual environment (torch 2.14, Python 3.11) from a standalone
clone: the import resolves to the installed package and the tests pass.

.gitignore now refuses common tabular and model-artifact formats, so
patient-level data cannot be committed by accident.
GitHub Actions installs CPU torch, auton-survival from its 0.1.0 release
commit with --no-deps, and the package with its test extra, then runs
pytest on Python 3.11 and 3.12. It installs exactly what the README tells
a user to install, so a broken install recipe fails CI too.
@dadudu13
dadudu13 changed the base branch from pr/6-row-weighting to main October 21, 2026 20:37
@dadudu13
dadudu13 merged commit 6cc7198 into main Oct 21, 2026
4 checks passed
@dadudu13
dadudu13 deleted the pr/7-packaging-ci branch October 21, 2026 20:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant