scripts to calculate DWPC directly#7
Open
lagillenwater wants to merge 4 commits intogreenelab:mainfrom
Open
Conversation
Contributor
There was a problem hiding this comment.
Pull request overview
Adds a direct, local DWPC computation path (via hetmatpy) intended to run after null dataset generation, reducing reliance on Docker/API lookups and enabling caching/parallelism.
Changes:
- Introduces a new
src/dwpc_direct.pymodule to compute/cache DWPC matrices and extract DWPC values for pair lists. - Adds
scripts/compute_dwpc_direct.pyto run the direct DWPC computation across real/permuted/random datasets. - Updates pipeline/tasking/docs and tweaks permutation validation output formatting.
Reviewed changes
Copilot reviewed 6 out of 6 changed files in this pull request and generated 11 comments.
Show a summary per file
| File | Description |
|---|---|
| src/dwpc_direct.py | New DWPC computation/caching module + helpers for pairwise extraction and parallel runs. |
| scripts/compute_dwpc_direct.py | New executable script (jupytext export) that precomputes matrices and writes per-dataset DWPC outputs. |
| scripts/pipeline_production.py | Alters subprocess invocation for pipeline steps. |
| scripts/permutation_null_datasets.py | Minor formatting changes in permutation validation output. |
| pyproject.toml | Adds/adjusts Poe tasks and optional dev dependencies. |
| README.md | Updates workflow/task documentation. |
Comments suppressed due to low confidence (1)
pyproject.toml:60
pipeline-publicationis referenced in README.md but is not defined in the Poe tasks anymore (only pipeline-production / pipeline-null exist). Consider re-adding apipeline-publicationtask (it looks like scripts/pipeline_publication.py still exists) or removing the README reference to avoid broken docs.
# Grouped tasks
pipeline-production = "python scripts/pipeline_production.py"
pipeline-null = ["gen-permutation", "gen-random"]
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
…laps, and maintain consistent data structures Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Collaborator
Author
|
Hi @emma2207, I realized that I had an existing, unmerged PR to address. Let me know if you have any questions or if anything does not make sense. |
emma2207
approved these changes
Mar 31, 2026
emma2207
left a comment
There was a problem hiding this comment.
🚀 I love to see you wrote a class with functions!
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This PR focuses on calculating DWPC scores for metapaths after null generation.
Updated production pipeline runner to include direct DWPC after null generation:
Added direct DWPC execution script
Fixed permutation validation to iterate existing
updated README and pyproject.toml to include instructions for DWPC calc tasks