I'm currently using metadecoder 1.0.12, and running:
# There are 93 sam files
metadecoder coverage -s *.sam -o metadecoder.coverage
and got:
Traceback (most recent call last):
File "/home/ubuntu/miniconda3/envs/magflow/bin/metadecoder", line 216, in <module>
metadecoder_coverage.main(parameters)
File "/home/ubuntu/miniconda3/envs/magflow/lib/python3.7/site-packages/metadecoder/metadecoder_coverage.py", line 56, in main
for block_start, block_end in generate_block(file, parameters.threads):
File "/home/ubuntu/miniconda3/envs/magflow/lib/python3.7/site-packages/metadecoder/sam_utility.py", line 62, in generate_block
block_size = ceil((file_size - block_start) / blocks)
UnboundLocalError: local variable 'block_start' referenced before assignment
I noticed that all the sam files have the valid header, but no alignments, and I would suggest handling this scenario with an informative error to make easier to troubleshoot. Thanks!
Hi Telatin,
Thank you for your suggestion. Version 1.0.16 has solved this problem. Please let me know if you encounter any problems while using it.
Best,
Cong-Cong
Hello, thanks for sharing this tool!
I'm currently using metadecoder 1.0.12, and running:
and got:
I noticed that all the sam files have the valid header, but no alignments, and I would suggest handling this scenario with an informative error to make easier to troubleshoot. Thanks!