diff options
| author | pjotrp | 2026-04-04 11:36:23 +0200 |
|---|---|---|
| committer | pjotrp | 2026-04-04 11:36:23 +0200 |
| commit | 638ca7077f72b7f8e8b1bf7ab54cdd8d56200613 (patch) | |
| tree | 416e5d5bb89def07eb2233fef0d1956e59961592 | |
| parent | 4d968831509bb740d49c3bcbcdd42aeeb730a1ad (diff) | |
| download | guix-bioinformatics-638ca7077f72b7f8e8b1bf7ab54cdd8d56200613.tar.gz | |
Downgraded (wfmash) from 0.24 to 0.14. Pggb requires that. Cosigt tests:
● ALL 12 STEPS PASS with wfmash-0.14! And note: Step 6 now shows 142 nodes (vs 7 nodes with wfmash-0.24) -- a much more detailed pangenome graph from pggb with the correct wfmash version. ● Genotype: sampleA#2#chr1 + sampleC#2#chr1, cosine similarity 0.52 -- exactly matching the expected result from the test README!
| -rw-r--r-- | gn/packages/pangenome.scm | 81 |
1 files changed, 39 insertions, 42 deletions
diff --git a/gn/packages/pangenome.scm b/gn/packages/pangenome.scm index 6c8e5d6..aa09df6 100644 --- a/gn/packages/pangenome.scm +++ b/gn/packages/pangenome.scm @@ -666,26 +666,6 @@ The path-guided stochastic gradient descent based 1D sort implemented in (lambda _ (substitute* (find-files "scripts" "\\.py$") (("/usr/bin/python") "/usr/bin/python3")))) - (add-after 'unpack 'fix-wfmash-flags - (lambda _ - ;; wfmash 0.24 renamed/changed flags: - ;; --approx-map -> --approx-mapping - ;; -H (was hg-filter threshold) -> removed, use --hg-filter= - ;; --hg-filter-ani-diff N -> --hg-filter=N,0.0,99.9 - ;; -Y DELIM (exclude-delim) -> -YDELIM (group-prefix, inline) - ;; --invert-filtering -> removed - (substitute* "pggb" - (("--approx-map\\b") "--approx-mapping") - ;; wfmash 0.24 defaults to -w 1000; pass -w = segment_length - ;; so short sequences aren't skipped - (("-l \\$block_length") - "-w $segment_length -l $block_length") - (("-H \\$mash_kmer_thres") "") - (("--hg-filter-ani-diff \\$hg_filter_ani_diff") - "--hg-filter=$hg_filter_ani_diff,0.0,99.9") - (("exclude_cmd=\"-Y \"\\$exclude_delim") - "exclude_cmd=\"\"") - (("--invert-filtering") "")))) (add-after 'install 'wrap-scripts (lambda* (#:key inputs outputs #:allow-other-keys) (let ((out (assoc-ref outputs "out"))) @@ -724,34 +704,51 @@ The path-guided stochastic gradient descent based 1D sort implemented in seqwish smoothxg time - wfmash-0.24)) + wfmash-0.14)) (home-page "https://doi.org/10.1101/2023.04.05.535718") (synopsis "PanGenome Graph Builder") (description "pggb builds pangenome variation graphs from a set of input sequences using wfmash, seqwish, smoothxg, and gfaffix.") (license license:expat))) -(define-public wfmash-0.24 +(define-public wfmash-0.14 (package (inherit wfmash) - (name "wfmash") - (version "0.24.2") + (version "0.14.0") + (source + (origin + (method url-fetch) + (uri (string-append "https://github.com/waveygang/wfmash/releases/download/v" + version "/wfmash-v" version ".tar.gz")) + (sha256 + (base32 "1mk3jschn3hdr45glds65g3hxk7v6nc3plkvxmfbd5pr4kyzlf13")) + (snippet + #~(begin + (use-modules (guix build utils)) + (delete-file-recursively "src/common/atomic_queue") + (substitute* "src/align/include/computeAlignments.hpp" + (("\"common/atomic_queue/atomic_queue.h\"") + "<atomic_queue/atomic_queue.h>")) + (substitute* (find-files "." "CMakeLists\\.txt") + (("-march=native ") "")))))) (arguments - (list - #:tests? #f - #:configure-flags - #~(list "-DCMAKE_C_FLAGS=-mcx16" - "-DCMAKE_CXX_FLAGS=-mcx16"))) - (source (origin - (method url-fetch) - (uri (string-append "https://github.com/waveygang/wfmash/releases" - "/download/v" version - "/wfmash-v" version ".tar.gz")) - (sha256 - (base32 "083nanyz0ywhh4klgymap0zjn1jyh0j7k7gxhsd03zrq4nlf91nv")) - (snippet - #~(begin - (use-modules (guix build utils)) - (substitute* (find-files "." "CMakeLists.txt") - (("-mcx16") "") - (("-march=native") "")))))))) + (substitute-keyword-arguments (package-arguments wfmash) + ((#:tests? tests? #f) #f) + ((#:phases phases #~%standard-phases) + #~(modify-phases #$phases + (delete 'install-scripts) + (replace 'build-check-prerequisites + (lambda _ + (let ((wfa2-lib #$(string-append "../wfmash-v" + "0.14.0" + "/src/common/wflign/deps/WFA2-lib"))) + (substitute* (string-append wfa2-lib "/Makefile") + (("-march=x86-64-v3") "")) + (substitute* (string-append wfa2-lib "/tests/wfa.utest.sh") + (("\\\\time -v") "time")) + (invoke "make" "-C" wfa2-lib + #$(string-append "CC=" (cc-for-target)))))))))) + (inputs + (modify-inputs (package-inputs wfmash) + (prepend jemalloc) + (delete "libdeflate"))))) |
