mortazavilab / cerberus

16 stars 1 forks source link

ValueError: Buffer dtype mismatch, expected 'const long' but got 'long long' #7

Open sterneck opened 4 months ago

sterneck commented 4 months ago

Hi,

I am using a GFF file produced by SMRT LInk from Pacific Biosciences. This was converted to a GTF file (version 3) by AGAT using Galaxy. I sorted the GTF file using IGV tools. Then, I tried to use Cerberus to generate the list of TSS and TES sites.

At first, I received the error "Cannot compute TSSes or TESes without strand info", which was described in an earlier case. I followed the advice to install your version of pyranges (https://github.com/fairliereese/pyranges). However, when I tried again, I obtained this message:

Traceback (most recent call last): File "C:\Users\sterneck.conda\envs\cerberus6\lib\runpy.py", line 197, in _run_module_as_main return _run_code(code, main_globals, None, File "C:\Users\sterneck.conda\envs\cerberus6\lib\runpy.py", line 87, in _run_code exec(code, run_globals) File "C:\Users\sterneck.conda\envs\cerberus6\Scripts\cerberus.exe__main.py", line 7, in File "C:\Users\sterneck.conda\envs\cerberus6\lib\site-packages\click\core.py", line 1130, in call return self.main(*args, kwargs) File "C:\Users\sterneck.conda\envs\cerberus6\lib\site-packages\click\core.py", line 1055, in main rv = self.invoke(ctx) File "C:\Users\sterneck.conda\envs\cerberus6\lib\site-packages\click\core.py", line 1657, in invoke return _process_result(sub_ctx.command.invoke(sub_ctx)) File "C:\Users\sterneck.conda\envs\cerberus6\lib\site-packages\click\core.py", line 1404, in invoke return ctx.invoke(self.callback, ctx.params) File "C:\Users\sterneck.conda\envs\cerberus6\lib\site-packages\click\core.py", line 760, in invoke return callback(*args, kwargs) File "C:\Users\sterneck.conda\envs\cerberus6\lib\site-packages\cerberus\main.py", line 29, in gtf_to_bed_command return gtf_to_bed(gtf, mode, o, dist, slack) File "C:\Users\sterneck.conda\envs\cerberus6\lib\site-packages\cerberus\cerberus.py", line 2245, in gtf_to_bed bed = get_ends_from_gtf(gtf, mode, dist, slack) File "C:\Users\sterneck.conda\envs\cerberus6\lib\site-packages\cerberus\cerberus.py", line 1784, in get_ends_from_gtf bed = bed.merge(strand=True, File "C:\Users\sterneck.conda\envs\cerberus6\lib\site-packages\pyranges\pyranges_main.py", line 3145, in merge df = pyrange_apply_single(_merge_by, self, kwargs) File "C:\Users\sterneck.conda\envs\cerberus6\lib\site-packages\pyranges\multithreaded.py", line 331, in pyrange_apply_single result = call_f_single(function, nparams, df, kwargs) File "C:\Users\sterneck.conda\envs\cerberus6\lib\site-packages\pyranges\multithreaded.py", line 28, in call_f_single return f.remote(df, kwargs) File "C:\Users\sterneck.conda\envs\cerberus6\lib\site-packages\pyranges\methods\merge.py", line 65, in _merge_by ids, starts, ends, number = merge_by(cdf.Start.values, cdf.End.values, cdf.ClusterBy.values, slack) File "sorted_nearest\src\merge_by.pyx", line 10, in sorted_nearest.src.merge_by.merge_by ValueError: Buffer dtype mismatch, expected 'const long' but got 'long long'

Any helpful suggestions?

Very many thanks!

sterneck commented 4 months ago

I was able to make it work by making two changes.

First, instead of using python 3.9, I used python 3.8.6 Second, I used pyranges version 0.0.125.