-
Notifications
You must be signed in to change notification settings - Fork 2
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
err about sam-to-compact #6
Comments
Could you check that the SAM files includes headers at the top? If it does, it would help if you provided some details, i.e., a small file sufficient to reproduce the problem. If it does not, you need to add headers at the start of the file. See http://www.htslib.org/doc/samtools.html to learn how to add a header. |
It does not. And I think a sorted SAM file is supposed to contain no header. |
I tried
|
I think let's continue with the SAM file because the message is clear and it's easier to look at a text file for you to understand what is going on. If the SAM file you provided has no header, and Goby tells you in its error message that a header is required, it looks to me that the path forward is to add a header. File format conversion cannot proceed without the header because it contains reference target/chromosome names and target lengths, which goby stores and uses in many ways. Do you know how to create a SAM header? |
If you need help, it would also be useful if you posted complete reports: exactly what are you doing, including the command line and short examples of files. The exception you posted could be caused by an incorrectly specified reference genome argument, but I have no way of telling from if I can't see the command line and know what the files contain. |
first lines of
cmd
output
|
|
The header looks fine, except it is space delimited as far as I can tell from the GitHub formatting. The SAM spec indicates that the header must be tab delimited. Goby uses samtools to check if the header is present, if the file has spaces it won't be parsed correctly. You can use the following command to check for tabs: od -c SRR001000.sam |head A tab separator should appear as \t, not space and appear between @sq and SN. |
I am pretty sure it is tab delimited.
|
Could you provide the exact file you use somewhere so that I can replicate this? I am upgrading Goby to htsjdk from a very old samtools and I would like to see if this helps with parsing your file. |
Given my network condition is poor, the file is too huge to be transmitted. The project has been ended, so I will not follow up this issue. Your help is truly appreciated. |
I upgraded Goby to the latest HTSJDK (where samtools java implementation was used before). You can download a preview of the jar here: |
Here is the command:
Here is the output:
The text was updated successfully, but these errors were encountered: