Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

pyBHFDR can't find weight column #9

Open
wangzwYYDS opened this issue Oct 8, 2023 · 3 comments
Open

pyBHFDR can't find weight column #9

wangzwYYDS opened this issue Oct 8, 2023 · 3 comments

Comments

@wangzwYYDS
Copy link

pyBHFDR -O K562-MboI-BHFDR-loops.txt -p Ga.40000.a.cool::40000 -C 4 --pw 1 --ww 3

root INFO @ 10/08/23 15:58:09: Python Version: 3.6.15
root INFO @ 10/08/23 15:58:09:

ARGUMENT LIST:

Output file = K562-MboI-BHFDR-loops.txt

Cooler URI = Ga.40000.cool::40000

Chromosomes = ['4']

Peak window width = 1

Donut width = 3

Maximum donut width = 10

Significant Level = 0.05

Maximum Genomic distance = 2000000

Weight column name = weight

Number of Processes = 1

root INFO @ 10/08/23 15:58:10: Loading Hi-C data ...
root INFO @ 10/08/23 15:58:10: Calling Peaks ...
Traceback (most recent call last):
File "/data/Software/miniconda3/envs/TADlib/bin/pyBHFDR", line 185, in
run()
File "/data/Software/miniconda3/envs/TADlib/bin/pyBHFDR", line 169, in run
for key, pixel_table in results:
File "/data/Software/miniconda3/envs/TADlib/bin/pyBHFDR", line 116, in worker
cHeatMap = Lib.matrix(balance=args.clr_weight_name, sparse=True).fetch(key)
File "/data/Software/miniconda3/envs/TADlib/lib/python3.6/site-packages/cooler/core/_selectors.py", line 150, in fetch
return self._slice(self.field, i0, i1, j0, j1)
File "/data/Software/miniconda3/envs/TADlib/lib/python3.6/site-packages/cooler/api.py", line 384, in _slice
self._is_symm_upper,
File "/data/Software/miniconda3/envs/TADlib/lib/python3.6/site-packages/cooler/api.py", line 710, in matrix
+ "calculate balancing weights or set balance=False."
ValueError: No column 'bins/weight'found. Use cooler.balance_cooler to calculate balancing weights or set balance=False.

toCool

toCooler -O Ga.40000.a.cool -d datasets --chromsizes-file aa.leng --no-balance --nproc 1

root INFO @ 10/08/23 16:06:11: Python Version: 3.6.15
root INFO @ 10/08/23 16:06:11:

ARGUMENT LIST:

Output cooler path = Ga.40000.a.cool

Hi-C datasets = {40000: '/gpfs/Project/wangzw_Project/TDA_analysis/test/HiCPeaks/40K'}

Chromosomes = ['#', 'X']

Include trans-chromosomal data = False

Genome Assembly = None

Chromosome size file = aa.leng

Number of processes = 1

Log file name = tocooler.log

hicpeaks.utilities INFO @ 10/08/23 16:06:12: Read chromosome sizes from /gpfs/Project/wangzw_Project/TDA_analysis/test/HiCPeaks/aa.leng
hicpeaks.utilities INFO @ 10/08/23 16:06:12: Done
hicpeaks.utilities INFO @ 10/08/23 16:06:12: Extract and save data into cooler format for each resolution ...
hicpeaks.utilities INFO @ 10/08/23 16:06:12: Current resolution: 40000bp
hicpeaks.utilities INFO @ 10/08/23 16:06:12: Generate bin table ...

first, do toCooler convert txt file to cool file format .
then call peaks using pyBHFDR , has some error message . don't know how to solve it.
thanks

@lanyunxin
Copy link

I have the same problem. Have you solved it

@lhqxinghun
Copy link

I have met the same problem. Can someone help me?

@lhqxinghun
Copy link

I have met the same problem. Can someone help me?

I have addressed this by setting the reference genome to hg19 instead of hg38 in toCooler, because I found that using hg38 may cause the matrix in cooler file not square.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants