Releases: quwubin/MFEprimer-3.0
Release list
v4.5.1
MFEprimer v4.5.1
Query -k auto-detect from the index, plus index robustness fixes from late July.
Highlights
-
Query
-kauto-detect (mfeprimer/spec/search)
Omit-kto read k from each-dindex (.primerqc.binheader; legacy: first.primerqc.failength). An explicit-kmust match every-dindex, or the run errors — no more silent 0 binding sites when query k > index k. Multiple-dparts must share the same k. Motivated by large / repeat-rich assemblies (issue #34). -
Index robustness
- Atomic publish of
.primerqc.bin(.partial→ fsync → rename) so a killed build cannot leave a truncated index that looks valid. - Phase-2 disk spill under memory pressure (sequential bucket encode).
- Stricter decode /
OpenIndex/ migrate / verify / indexcmp (reject truncated postings; k capped at 15; migrate prefers source k).
- Atomic publish of
-
Fix: forward binding start display
After the exclusive-bound coordinate change for SNP matching, the report template now shows the correct 1-based inclusive forward binding start.
Docs
- Guide: Large / repeat-rich genomes — choosing index k, split FASTA + multi-
-d,--bind-amp-only, reading PBN/MBN vs amplicon count.
Quick start
mfeprimer index -i genome.fa -k 13 -c 32 -f
mfeprimer spec -i primers.fa -d genome.fa -o out.spec --bind-amp-only -b -j
# omit -k: auto from indexv4.5.0
MFEprimer v4.5.0
Fix --snp for FASTA input, and expose SNP QC counts in *.spec.tsv.
Highlights
-
Fix:
--snpon FASTA primer input
The batch specificity path (mfeprimer/mfeprimer specwith FASTA-i) accepted--snpand printed it under Parameters, but never ran SNP annotation on predicted amplicons (the*marks in Amplicon details / SNP count columns). That is separate from--bind, which reports genome-wide primer hit sites. SNP annotation now runs before report / TSV output. (TSV pair inputname fp rpalready worked.) -
*.spec.tsv: SNP QC columns (breaking layout)
Four integer columns are inserted beforenote:fpSNP rpSNP fpSnpDanger rpSnpDangerColumn Meaning fpSNP/rpSNPSNPs overlapping the forward / reverse primer–template duplex on the predicted amplicon fpSnpDanger/rpSnpDangerSubset within 6 bp of the primer 3′ end Without
--snp, all four columns are0(columns are always present).--snpdoes not change which amplicons are predicted.Full header:
#name chrom ampStart ampEnd ampGC ampSize productTm ta fpName fpStart fpEnd fpSeq fpTm fpGC fpDg rpName rpEnd rpStart rpSeq rpTm rpGC rpDg fpSNP rpSNP fpSnpDanger rpSnpDanger noteParsers that assumed a fixed column index for
notemust be updated. Prefer parsing by column name.
Example (official chrM fixture)
wget -c https://github.com/quwubin/MFEprimer-3.0/raw/master/chrM.fa
wget -c https://github.com/quwubin/MFEprimer-3.0/raw/master/p.fa
wget -c https://github.com/quwubin/MFEprimer-3.0/raw/master/snp.bed
./mfeprimer index -i chrM.fa
./mfeprimer -i p.fa -d chrM.fa --snp snp.bed -o outIn the text report, Amp 1 (p3 + p4) shows * under primer bases that overlap SNPs. In out.spec.tsv, expect non-zero fpSNP / rpSNP for that row.
Notes
- Chromosome names in the SNP BED must match FASTA headers (
chr1≠1). - BED coordinates are standard 0-based half-open.
- Related: issue #35.
v4.4.0
MFEprimer v4.4.0
Faster --bind on large genomes: amplicon-scoped binding reports and a fully parallel binding path.
Highlights
-
New
--bind-amp-only(implies-b/--bind)
Compute and report binding sites only within the predicted amplicons, instead of running the full thermodynamic workup on every genome-wide k-mer hit. On multi-Gbp, repeat-rich genomes this turnsspec -bruns that previously never finished into seconds. Background and benchmarks: issue #33. -
Parallel binding path
The k-mer binding query, the amplicon search, and the binding-detail workup now all run in the worker pool, so-cfinally scalesspec -b(previously the-bpath was single-threaded). -
Fix: duplicated binding entries on multi-record references
Binding entries were appended once per record, so*.bind.txtgrew quadratically and contained duplicated sites on multi-chromosome/contig databases. The reported site set is unchanged; the duplicates are gone. -
Consistent counts with
--bind-amp-only
The per-primer header now shows both the genome-wide hit count and the reported subset, e.g.has [ 2/plus + 1/minus ] binding sites genome-wide, showing [ 1/plus + 0/minus ] within predicted amplicons.
Notes
- Default
-boutput is unchanged except that duplicated entries are removed (byte-identical on single-record references). - With
--bind-amp-only, the reported sites are exactly the full-bsites overlapping the predicted amplicons; with zero predicted amplicons it returns instantly.
Quick start
mfeprimer spec -i primers.fa -d huge_genome.fa -o out --bind-amp-only -c 16v4.3.1
MFEprimer v4.3.1
Smaller primer-QC indexes for large genomes, without changing QC / specificity semantics.
Highlights
-
New default binary index (
.primerqc.bin)
Exact 9-mer indexing for primer 3' ends is unchanged. The new format stores each reference window once and recovers minus-strand hits at query time, so plus/minus results stay consistent with previous releases. -
Much smaller indexes than the legacy text format
Especially helpful for large reference genomes where the old.primerqcindexes could become extremely large. -
mfeprimer migrate
Batch-upgrade existing legacy indexes under a directory to the new binary format.
Optional--verify.--deleteremoves legacy text sidecars only after a successful upgrade. -
Existing databases keep working. Rebuild / migrate when you want the smaller footprint.
Updates (same version, refreshed binaries)
*.spec.tsv: addproductTmandtacolumns (same values as the text report’s ProductTm / Ta). See issue #32.
Quick start
mfeprimer index -i reference.fa -c 16 -f
mfeprimer migrate -d /path/to/databases --verifyNotes
- For very large assemblies, please compare index size (
du -h) and peak memory on your own FASTA and report back if anything still looks off.
v4.2.4
v4.2.3 what's the max-amp-count?
Bug fixed
- The default graphic and tsv output are not identical.
-oflag is mandatory from v4.0.- TSV output coordinates fixed: 1-based coordinate, should be idential to blat output if align primer sequences to genome.
What's the flag of --max-amp-count?
There are cases that more than 100,000 primers for evaluation simultaneously, and the program will consume all available system memory, leading to performance issues or crashes.
To address this, we introduced the-M(or --max-amp-count) flag, which enables batched output of predicted amplicons to prevent excessive memory usage.
Default Behavior (Amplicon Count ≤ --max-amp-count)
- The default value is 10,000 amplicons per batch.
- When the number of predicted amplicons does not exceed this threshold:
- Both graphical and TSV (tab-separated values) outputs are identical (sorted and deduplicated).
- The only difference is that the TSV output excludes amplicon sequences (to reduce file size while maintaining key information).
Handling Large Datasets (Amplicon Count > --max-amp-count)
- If the number of predicted amplicons exceeds the
--max-amp-countthreshold:- The first batch (≤ --max-amp-countamplicons) is processed normally (sorted and deduplicated).
- Subsequent batches are appended to the TSV output without sorting or deduplication (to optimize memory efficiency).
This ensures stable performance even with very large primer sets, while maintaining optimal output quality for smaller datasets.
v4.2.2
Output binding for each database
Bug Fixes
- Resolved issue #29;
- For multiple databases, output binding information on each database.
make TSV output default
Key Updates
-
Output File Handling:
- The --tsv flag has been deprecated. TSV output is now the default format.
- If input is
name fp rp, adding support for other output formats. - For both
mfeprimerandmfeprimer spec, results will be saved as out.spec.tsv. - Additional outputs for mfeprimer:
- Dimer analysis: out.dimer.tsv;
- Hairpin analysis: out.hairpin.tsv.
-
Bug Fixes:
- Resolved issue #26;
- Mismatch not working in tsv mode;
-
Sub-command Enhancements:
- New sub-commands are now available:
mfeprimer search: homology search for short sequences like primers against genome database, require pre-indexed bymfeprimer index;mfeprimer degen: convert a DNA sequence from ambiguous (with degenerate bases) to unambiguous DNA list;mfeprimer split-fasta: split fasta into N parts with almost equal size;mfeprimer thermo: thermodynamics calculation for oligos.
- New sub-commands are now available:
mutiple db bug fixed
fixed a bug when mutiple background databases were specified.