|
| 1 | +# Finishing the CellPheno NIS submission on a local GPU server |
| 2 | + |
| 3 | +This is the runbook for the three steps the automated cloud session could not do |
| 4 | +(no Docker daemon, blocked registry hosts, GitHub scope). Run it on your GPU |
| 5 | +server, where Docker + GPU + network + your credentials are available. You can |
| 6 | +either run the commands yourself, or launch **Claude Code** in this repo and say: |
| 7 | +*"complete the CellPheno NIS nf-core submission per docs/local_gpu_run.md"* — the |
| 8 | +agent will execute these steps and verify each one. |
| 9 | + |
| 10 | +## 0. One-time setup |
| 11 | + |
| 12 | +```bash |
| 13 | +git clone https://github.com/Chrisa142857/Lightsheet_microscopy_image_3D_nuclei_instance_segmentation |
| 14 | +cd Lightsheet_microscopy_image_3D_nuclei_instance_segmentation |
| 15 | +git checkout claude/nis-nfcore-conversion-afd7qu |
| 16 | + |
| 17 | +bash scripts/setup_local_gpu.sh # installs nf-core, nextflow, nf-test, gdown; checks Docker+GPU |
| 18 | +docker login ghcr.io # your GitHub container registry |
| 19 | +docker login quay.io # only if you have nf-core org push access |
| 20 | +gh auth login # for the fork + PR |
| 21 | +``` |
| 22 | + |
| 23 | +## 1. Build + push the GPU container |
| 24 | + |
| 25 | +```bash |
| 26 | +# Preferred: nf-core org namespace (matches numorph/3dunet). Needs nf-core quay access. |
| 27 | +bash containers/nis/build_and_push.sh quay.io/nf-core/cellpheno-nis 1.0.0 |
| 28 | + |
| 29 | +# Fallback you fully control (works without nf-core membership): |
| 30 | +bash containers/nis/build_and_push.sh ghcr.io/chrisa142857/cellpheno-nis 1.0.0 |
| 31 | +``` |
| 32 | + |
| 33 | +If you used the **ghcr fallback**, point the module at it so lint can reach the |
| 34 | +image, and make the package public (`ghcr.io` → package settings → Public): |
| 35 | + |
| 36 | +```bash |
| 37 | +sed -i 's#quay.io/nf-core/cellpheno-nis#ghcr.io/chrisa142857/cellpheno-nis#' \ |
| 38 | + modules/nf-core/cellpheno/nis/main.nf |
| 39 | +``` |
| 40 | + |
| 41 | +## 2. Verify the module is fully green |
| 42 | + |
| 43 | +Lint must run inside a clone of nf-core/modules (it compares against that repo). |
| 44 | + |
| 45 | +```bash |
| 46 | +git clone --depth 1 https://github.com/nf-core/modules.git /tmp/nfcore-modules |
| 47 | +cp -r modules/nf-core/cellpheno /tmp/nfcore-modules/modules/nf-core/ |
| 48 | +cd /tmp/nfcore-modules |
| 49 | +nf-core modules lint cellpheno/nis # container check now PASSES (image is reachable) |
| 50 | +cd - |
| 51 | +``` |
| 52 | + |
| 53 | +Expected: the previous `container_links` failure is gone (image now reachable). |
| 54 | +The remaining `process_gpu` / container-version messages are non-fatal warnings |
| 55 | +that every GPU module carries. |
| 56 | + |
| 57 | +## 3. (Optional, for the real GPU test) prepare test data |
| 58 | + |
| 59 | +The committed test has a `-stub` test (already snapshotted) plus a `gpu`-tagged |
| 60 | +real test. The real test needs data; the stub is enough to open the PR. To enable |
| 61 | +the real test later: |
| 62 | + |
| 63 | +```bash |
| 64 | +bash containers/nis/fetch_models.sh downloads/resource # G-drive NIS .pt models (cpp/README.md) |
| 65 | +# Tiny tile fixture is in tests/testdata/cellpheno_nis/ — replace with a real small tile. |
| 66 | +# Then: PR the tile to nf-core/test-datasets, host .pt weights on Zenodo, and run |
| 67 | +nf-test test modules/nf-core/cellpheno/nis/tests/main.nf.test --profile docker,gpu --update-snapshot |
| 68 | +``` |
| 69 | + |
| 70 | +## 4. Fork nf-core/modules and open the PR |
| 71 | + |
| 72 | +```bash |
| 73 | +gh repo fork nf-core/modules --clone --remote |
| 74 | +cd modules |
| 75 | +git checkout -b cellpheno-nis |
| 76 | +cp -r ../Lightsheet_microscopy_image_3D_nuclei_instance_segmentation/modules/nf-core/cellpheno \ |
| 77 | + modules/nf-core/ |
| 78 | +nf-core modules lint cellpheno/nis |
| 79 | +pre-commit run --all-files |
| 80 | +git add modules/nf-core/cellpheno |
| 81 | +git commit -m "new module: cellpheno/nis" |
| 82 | +git push -u origin cellpheno-nis |
| 83 | +gh pr create --repo nf-core/modules --base master \ |
| 84 | + --title "new module: cellpheno/nis" \ |
| 85 | + --body-file ../Lightsheet_microscopy_image_3D_nuclei_instance_segmentation/PR_BODY.md |
| 86 | +``` |
| 87 | + |
| 88 | +The PR body text is in [`docs/nfcore_submission.md`](nfcore_submission.md) — copy |
| 89 | +it into `PR_BODY.md` first (or paste it into the PR on GitHub). |
| 90 | + |
| 91 | +## Notes |
| 92 | + |
| 93 | +- **Registry choice:** `quay.io/nf-core/cellpheno-nis` is the ideal home but needs |
| 94 | + nf-core org access; maintainers commonly mirror a contributor image there during |
| 95 | + review. Using `ghcr.io/chrisa142857/cellpheno-nis` (public) is fine to get a green |
| 96 | + lint and open the PR — note it in the PR and the team can re-host. |
| 97 | +- **Conda CI:** the module intentionally errors under `-profile conda/mamba` |
| 98 | + (GPU binary, no conda) — this is expected and matches `parabricks/*`. |
0 commit comments