Skip to content

Incorrect support of 4DN DCIC format (pairs) in recent Pre versions (worked in 1.22.01 but fails in 2.16.00 and later) #387

@tanlongzhi

Description

@tanlongzhi

Dear Juicer Tools team,

My lab and I have been long-time loyal users of your incredible Juicer Tools, but recently your newer versions have broken the support of standard 4DN DCIC format (pairs) in Juicer Tools Pre because of incorrect handling of pairs file headers.

In particular, in previous versions (for example, we tested 1.14.08 and 1.22.01), a standard pairs file with all the correct header lines (see below) works for Juicer Tools Pre:

## pairs format v1.0
#sorted: chr1-chr2-pos1-pos2
#shape: upper triangle
#chromosome: chr1 248956422
#chromosome: chr2 242193529
#chromosome: chr3 198295559
#chromosome: chr4 190214555
#chromosome: chr5 181538259
#chromosome: chr6 170805979
#chromosome: chr7 159345973
#chromosome: chr8 145138636
#chromosome: chr9 138394717
#chromosome: chr10 133797422
#chromosome: chr11 135086622
#chromosome: chr12 133275309
#chromosome: chr13 114364328
#chromosome: chr14 107043718
#chromosome: chr15 101991189
#chromosome: chr16 90338345
#chromosome: chr17 83257441
#chromosome: chr18 80373285
#chromosome: chr19 58617616
#chromosome: chr20 64444167
#chromosome: chr21 46709983
#chromosome: chr22 50818468
#chromosome: chrX 156040895
#chromosome: chrY 57227415
#columns: readID chr1 pos1 chr2 pos2 strand1 strand2

But this stopped working in newer versions (for example, we tested 2.16.00 and 2.20.00), throwing in the following error:

WARN [2025-11-17T09:24:11,822]  [Globals.java:138] [main]  Development mode is enabled
Using 1 CPU thread(s) for primary task
Using 10 CPU thread(s) for secondary task
Not including fragment map
Start preprocess
Writing header
Writing body
java.lang.ArrayIndexOutOfBoundsException: 3
	at juicebox.tools.utils.original.mnditerator.ComplexLineParser.generateBasicPair(ComplexLineParser.java:56)
	at juicebox.tools.utils.original.mnditerator.MNDFileParser.parseDCICFormat(MNDFileParser.java:118)
	at juicebox.tools.utils.original.mnditerator.MNDFileParser.parse(MNDFileParser.java:83)
	at juicebox.tools.utils.original.mnditerator.GenericPairIterator.advance(GenericPairIterator.java:56)
	at juicebox.tools.utils.original.mnditerator.GenericPairIterator.next(GenericPairIterator.java:46)
	at juicebox.tools.utils.original.Preprocessor.computeWholeGenomeMatrix(Preprocessor.java:603)
	at juicebox.tools.utils.original.Preprocessor.writeBody(Preprocessor.java:690)
	at juicebox.tools.utils.original.Preprocessor.preprocess(Preprocessor.java:452)
	at juicebox.tools.clt.old.PreProcessing.run(PreProcessing.java:176)
	at juicebox.tools.HiCTools.main(HiCTools.java:97)

After extensive troubleshooting, we found that that newer versions can be made working by manually removing most of the standard pairs header line to match your web manual, namely leaving only the following header:

## pairs format v1.0
#columns: readID chr1 pos1 chr2 pos2 strand1 strand2

Would you mind fixing this, so that you can restore proper support of 4DN pairs format (specifically, the full, functional header as mandated by the standard) that once worked in earlier versions of Pre? Thank you very much!

Yours sincerely,
Tan


Longzhi Tan (he/him/his)
Assistant Professor
Department of Neurobiology
Stanford University

299 Campus Drive
Fairchild Science Building, Room D235
Stanford, CA 94305

Email: tttt@stanford.edu
Lab Website: 3dgeno.me

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions