Reformatting the software toward a distributable version - #3
Merged
Conversation
Contributor
There was a problem hiding this comment.
Pull request overview
Repackages mixmax for distribution, expands documentation/tutorials, and adds a benchmarking workflow with supporting scripts and tests.
Changes:
- Adds modern packaging, dependency, linting, typing, and version configuration.
- Introduces three Quarto tutorials and expanded project/workflow documentation.
- Adds a Snakemake benchmarking pipeline, simulation utilities, fixtures, and tests.
Reviewed changes
Copilot reviewed 22 out of 68 changed files in this pull request and generated 7 comments.
Show a summary per file
| File | Description |
|---|---|
.gitignore |
Expands generated-file exclusions |
README.md |
Rewrites installation and usage docs |
benchmarking_pipeline/config/README.md |
Removes placeholder documentation |
mixmax/README.md |
Removes superseded documentation |
notebooks/.gitignore |
Ignores Quarto artifacts |
notebooks/_quarto.yml |
Configures tutorial website |
notebooks/01_introduction.qmd |
Adds Bayesian introduction |
notebooks/02_kalman_filter.qmd |
Adds Kalman filter tutorial |
notebooks/03_diagnostics.qmd |
Adds posterior diagnostics tutorial |
pixi.toml |
Defines environment and tasks |
pyproject.toml |
Adds package/build configuration |
pyrightconfig.json |
Configures local type checking |
src/mixmax/__init__.py |
Exposes package version |
src/mixmax/_version.py |
Adds version loading |
src/mixmax/_version_generated.py |
Adds generated version data |
src/mixmax/create_demultiplexing_scheme.py |
Revises CLI input handling |
src/mixmax/match_samples.py |
Adds sample-matching CLI |
tests/pools_test.txt |
Adds pooling fixture |
tests/sample_list_test.txt |
Adds sample-list fixture |
tests/split_loom_data_test_split1.loom |
Adds split fixture |
tests/split_loom_data_test_split2.loom |
Adds split fixture |
tests/test_common.py |
Tests workflow helpers |
tests/test_create_demultiplexing_scheme.py |
Tests scheme generation |
tests/test_mosaic_processing.py |
Tests pseudobulk VAF handling |
tests/test_split_loom_files.py |
Tests Loom splitting |
workflow/README.md |
Documents benchmarking workflow |
workflow/Snakefile |
Defines benchmarking pipeline |
workflow/config/template.yaml |
Adds workflow configuration template |
workflow/envs/loom.yml |
Defines Loom environment |
workflow/envs/mosaic.yml |
Defines mosaic environment |
workflow/envs/sample_assignment.yml |
Defines assignment environment |
workflow/launch_pipeline.py |
Adds Slurm launcher |
workflow/launcher_loop.sh |
Launches multiple seeded runs |
workflow/rules/common.smk |
Adds shared workflow helpers |
workflow/sandbox/compute_performance_score.py |
Computes simulation metrics |
workflow/sandbox/figure3.py |
Generates performance figures |
workflow/sandbox/figure4.py |
Generates parameter figures |
workflow/sandbox/generate_parameter_space.py |
Generates parameter combinations |
workflow/sandbox/parameter_space.tsv |
Defines benchmark parameters |
workflow/sandbox/results_for_non_robust.csv |
Adds non-robust results |
workflow/sandbox/results_for_robust.csv |
Adds robust results |
workflow/scripts/__init__.py |
Marks scripts package |
workflow/scripts/assign_subsample_simulation.py |
Clarifies output format |
workflow/scripts/compare_distances.py |
Improves boolean parsing and plots |
workflow/scripts/create_demultiplexing_scheme.py |
Improves boolean parsing |
workflow/scripts/demo_tape.py |
Adds demultiplexing implementation |
workflow/scripts/demultiplex_distance.py |
Adds library-depth visualization |
workflow/scripts/find_multiplexing_scheme_ILP.py |
Adds ILP scheme optimization |
workflow/scripts/get_input_samples.py |
Adds seeded sample selection |
workflow/scripts/gurobi.log |
Adds generated optimizer log |
workflow/scripts/split_loom_files.py |
Adds Loom splitting utility |
Suppressed comments (8)
src/mixmax/create_demultiplexing_scheme.py:194
- When
--input_samplesis omitted (the documented--n_samplesmode),input_samplesis never assigned, yet it is always passed here, so the CLI raisesUnboundLocalErrorinstead of writing a scheme. Define the intended output for a count-only invocation, or require and validate the sample list before this call.
src/mixmax/match_samples.py:62 type=booltreats every non-empty CLI string as true, including"False"; therefore the README's--robust Falsecommand runs robust matching. Parse accepted boolean spellings explicitly, as done inworkflow/scripts/compare_distances.py.
src/mixmax/match_samples.py:83- This f-string uses the same quote character inside and outside the expression, which is a
SyntaxErroron Python 3.10 and 3.11 even though both are declared supported. Use different outer quotes so the module can be parsed on all supported versions.
src/mixmax/match_samples.py:208 - For a valid one-pool input,
plt.subplots(1, 1)returns a singleAxes, not a 2-D array, soaxes[i, j]raisesTypeError. Normalize the result to two dimensions before indexing.
src/mixmax/match_samples.py:226 - For one input pool, this
subplotscall returns a scalarAxes, so the followingaxes[i]indexing fails. Normalize it to a one-dimensional array as the workflow copy now does.
src/mixmax/create_demultiplexing_scheme.py:165 - Adding
--input_samplesas an alternative does not make--n_samplesoptional: the parser still declares--n_sampleswithrequired=True, so the README's input-file-only invocation is rejected before this branch runs. Make these inputs mutually exclusive and require exactly the mode(s) the implementation supports.
src/mixmax/create_demultiplexing_scheme.py:160 --input_diris now optional, butmainalways passes it toselect_samples_for_pooling, which performsinput_dir / filename; omitting it therefore produces aTypeError. Either keep it required whenever concrete sample paths are emitted or define a count-only output mode.
src/mixmax/match_samples.py:292- Reassigning
sorted_ratiosinside afor ... in sorted_ratiosloop does not change the iterator already being consumed, so the claimed dynamic reprioritization never occurs; all remaining matrix pairs are processed in the original order. Drive this with awhileloop that selects from the newly computed list (and recompute ratios from the still-unused rows/columns).
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
JohannesGawron
force-pushed
the
create_package
branch
from
August 11, 2026 14:53
a041118 to
833f6b3
Compare
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
Co-authored-by: JohannesGawron <93670909+JohannesGawron@users.noreply.github.com>
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 pull request reformats the software to support pixi and a distribution as a package. The most important changes are grouped below by theme:
Documentation Overhaul:
README.mdto provide a clear project overview, installation instructions, detailed usage for CLI tools, repository structure, development workflow, and badges for linting, license, and Python version. This makes onboarding and usage much more accessible.mixmax/README.md, consolidating all relevant information into the mainREADME.md.benchmarking_pipeline/config/README.mdto clean up the repository and avoid confusion.Notebook Management:
.gitignoreinnotebooks/to exclude Quarto build artifacts and output files, ensuring a clean repository and avoiding accidental commits of generated content.Restructuring of project