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

Error: Found chromosome in region file not in reference genome. Skipping #138

Open
shguturu opened this issue May 24, 2024 · 5 comments
Open

Comments

@shguturu
Copy link

Hello! I am trying to run svaba for targeted SV detection.

The command works with Svaba v1.1.0 but with v1.2.0 it throws the following error:

"Found chromosome in region file /rtsess01/juno/home/arorak/resources/ACCESSv2_targets_coverage.100bp_padding.bed not in reference genome. Skipping.
   Caught error: regex_error
ERROR: Cannot read region file: /rtsess01/juno/home/arorak/resources/ACCESSv2_targets_coverage.100bp_padding.bed or something wrong with bam header ('chr' prefix mismatch?)"

I am using the same region file that was working with Svaba v1.1.0 so am unsure why it is not working with the new version. Is there a change that needs to be made to the region file? Thanks in advance!

Here is the command for reference:
"svaba run -G $REF_GENOME.fa -t $TUMOR.bam -n $NORMAL.bam -k $targets.bed -C 5000 -p 4 -a svaba_trial"

@walaj
Copy link
Owner

walaj commented May 24, 2024

The error comment I think could be better worded. What it is catching is an attempt to find a chromosome string from the BED file in the BAM header. Can you confirm that there are no chromosome names in the *bed file that are not in the tumor bam header? For this, it actually doesn't check the reference fasta, since that is done elsewhere.

If still an issue, I can try to recreate if you provide the BAM header (as a txt file aka SAM file) and the targets bed file. Dropbox link is fine. Should be no actual data in those files.

@walaj
Copy link
Owner

walaj commented May 28, 2024

I'm not able to re-create, but you could try adding this to the try block of svabaUtils.cpp right after file_regions = SeqLib::GRC(region_file, h);

for (const auto& a : file_regions) { std::cerr << a.ToString(h) << std::endl; assert(a.pos2 >= a.pos1); } std::cerr << h.AsString() << std::endl;

And then recompiling and rerunning and inspecting the output

@shguturu
Copy link
Author

shguturu commented May 30, 2024 via email

@kanika-arora
Copy link

@walaj I modified the svabaUtils.cpp file like you suggested, but it doesn't change anything. It doesn't write any other output and simply gives the error message that Shivani mentioned previously. Moreover, if instead of providing a bed file, I specify a chromosome, for example -k 1, then I get the following message:

terminate called after throwing an instance of 'std::regex_error'
  what():  regex_error
Aborted (core dumped)

And as mentioned in the previous comments, these exact same commands seem to work and produce results when run on SvABA v1.1.0 installed from Bioconda.

@kanika-arora
Copy link

Hi @walaj, do you have any other suggestions for debugging this issue? I tried running the tool without the -k option as well. That runs for a little bit, generates some intermediate files but eventually throws a different error and fails.

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