aidenlab / juicer

A One-Click System for Analyzing Loop-Resolution Hi-C Experiments
http://aidenlab.org
MIT License
399 stars 181 forks source link

ava.lang.RuntimeException: No reads in Hi-C contact matrices. This could be because the MAPQ filter is set too high (-q) or because all reads map to the same fragment. #311

Open molecule53 opened 1 year ago

molecule53 commented 1 year ago

Are you sure this is an issue? Github Issues is reserved for situations that require changes to the codebase. Questions, discussions, etc. should be posted to the forum: aidenlab.org/forum.html Hello,

I checked the forum and tried to incorporate suggestions for the issues - fixed some but still fighting with this one. Below are details about my test file and commands.

awk '{if ($3 <= $7) print $0; else print $1,$6,$7,$8,$9,$2,$3,$4,$5,$11,$10}' porec_test.concatemers.pairs.txt > corrected2_porec_test.concatemers.pairs.txt

sort -k3,3d -k7,7d corrected2_porec_test.concatemers.pairs.txt > sorted_corrected2_porec_test.concatemers.pairs.txt

(base) /Data1$ cat sorted_corrected2_porec_test.concatemers.pairs.txt | head -n 20

genome_assembly: unknown

CONCAT0 - - NU 5 ! 0 chr2 6538 0 R1 CONCAT10 - - NU 6 ! 0 chr2 6764 0 R1 CONCAT100 - - NU 2 ! 0 chr2 6764 0 R1 CONCAT1000 - - NU 3 ! 0 chr2 6538 0 R1 CONCAT103 - - NU 2 ! 0 chr2 6764 0 R1 CONCAT104 - - NU 8 ! 0 chr2 6538 0 R1 CONCAT105 - - NU 3 ! 0 chr2 537 0 R1 CONCAT106 - - NU 1 ! 0 chr1 3003 0 R1 CONCAT107 - - NU 2 ! 0 chr1 601 0 R1 CONCAT110 - - NU 7 ! 0 chr2 5512 0 R1 CONCAT112 - - NU 4 ! 0 chr2 5512 0 R1 CONCAT114 - - NU 7 ! 0 chr2 537 0 R1 CONCAT115 - - NU 7 ! 0 chr1 3577 0 R1 CONCAT116 - - NU 8 ! 0 chr2 6764 0 R1 CONCAT118 - - NU 9 ! 0 chr1 1103 0 R1 CONCAT119 - - NU 5 ! 0 chr2 5512 0 R1 CONCAT12 - - NU 5 ! 0 chr2 537 0 R1 CONCAT120 - - NU 3 ! 0 chr2 7551 0 R1 CONCAT123 - - NU 5 ! 0 chr2 6538 0 R1

(base) /Data1$ cat sorted_corrected2_porec_test.concatemers.pairs.txt | tail -n 20 CONCAT988 + - UU 4 chr2 6765 chr1 1103 60 R1 CONCAT989 + - UU 1 chr2 6765 chr2 6764 60 R1 CONCAT99 + - UU 2 chr2 6765 chr1 1103 60 R1 CONCAT990 + - UU 4 chr2 6765 chr2 537 60 R1 CONCAT993 + - UU 8 chr2 6765 chr2 537 60 R1 CONCAT995 + - UU 4 chr2 6765 chr2 5512 60 R1 CONCAT997 + - UU 5 chr2 6765 chr2 6764 60 R1 CONCAT998 + - UU 3 chr2 6765 chr2 537 60 R1 CONCAT999 + - UU 3 chr2 6765 chr2 5512 60 R1

chromsize: chr1 3577

chromsize: chr2 7551

samheader: PP:minimap2 CL:/home/epi2melabs/conda/bin/pore-c-py annotate - @PG PN:pore-c-py ID:pore-c-py-2 VN:2.0.1 --monomers porec_test.concatemers

samheader: @SQ SN:chr1 LN:3577

samheader: @SQ SN:chr2 LN:7551

samheader: CL:minimap2 -ay -t 2 @PG PN:minimap2 ID:minimap2 VN:2.24-r1122 map-ont -x

columns: readID chrom1 pos1 chrom2 pos2 strand1 strand2 pair_type walk_pair_index walk_pair_type mapq1 mapq2 pos51 pos52 pos31 pos32 cigar1 cigar2 read_len1 read_len2 matched_bp1 matched_bp2 algn_ref_span1 algn_ref_span2 algn_read_span1 algn_read_span2 dist_to_51 dist_to_52 dist_to_31 dist_to_32 mismatches1 mismatches2 rfrag1 rfrag_start1 rfrag_end1 rfrag2 rfrag_start2 rfrag_end2

samheader: restrict -f fragments.bed -o @PG ID:pairtools_restrict PN:pairtools_restrict CL:/home/epi2melabs/conda/bin/pairtools extract_pairs.tmp porec_test.concatemers.pairs.gz

pairs format v1.0.0

shape: whole matrix

samheader: parse2 --output-stats porec_test.concatemers.stats.txt -c @PG ID:pairtools_parse2 PN:pairtools_parse2 CL:/home/epi2melabs/conda/bin/pairtools --single-end fasta.fai

(base) /Data1$ java -Xmx48000m -Djava.awt.headless=true -jar juicer_tools_1.22.01.jar pre --threads 16 /Data1/sorted_corrected2_porec_test.concatemers.pairs.txt test_contact_map.hic /Data1/wf-pore-c-master/test_data/porec_test.fasta_chrom.sizes WARNING: sun.reflect.Reflection.getCallerClass is not supported. This will impact performance. WARN [2023-04-11T15:00:05,148] [Globals.java:138] [main] Development mode is enabled Using 16 CPU thread(s) Not including fragment map Start preprocess Writing header Writing body java.lang.RuntimeException: No reads in Hi-C contact matrices. This could be because the MAPQ filter is set too high (-q) or because all reads map to the same fragment. at juicebox.tools.utils.original.MatrixZoomDataPP.mergeAndWriteBlocks(MatrixZoomDataPP.java:276) at juicebox.tools.utils.original.Preprocessor.writeMatrix(Preprocessor.java:970) at juicebox.tools.utils.original.Preprocessor.writeBody(Preprocessor.java:659) at juicebox.tools.utils.original.Preprocessor.preprocess(Preprocessor.java:425) at juicebox.tools.clt.old.PreProcessing.run(PreProcessing.java:139) at juicebox.tools.HiCTools.main(HiCTools.java:94)

base) /Data1$ vim /Data1/wf-pore-c-master/test_data/porec_test.fasta_chrom.sizes

chr1 3577 chr2 7551 ~
~
~
~