millanek / Dsuite

Fast calculation of Patterson's D (ABBA-BABA) and the f4-ratio statistics across many populations/species
160 stars 26 forks source link

Dinvestigate issue: D.cpp:80: void doAbbaBaba(): Assertion `threePops.size() == 3' failed #90

Closed drew-olson-tmru closed 6 months ago

drew-olson-tmru commented 8 months ago

Hi, I am having issues with Dsuite investigate. It seems like this should be straightforward to use, but I'm running into this issue:

There are 3 sets (populations/species) excluding the Outgroup Dsuite: D.cpp:80: void doAbbaBaba(): Assertion `threePops.size() == 3' failed. Aborted (core dumped)

My command is: $DSUITE Dinvestigate $VCFFILE $SETSTXT $TRIOSTEXT

dsuite_trios.txt dsuite.sets.txt

I can include parts of the VCF if needed.

I have been following this tutorial (https://github.com/mmatschiner/tutorials/blob/master/analysis_of_introgression_with_snp_data/README.md#simulation), however, I don't see why my script is not running in comparison to the tutorial.

Can someone please help me with this?

Thank you!

shangshanzhizhe commented 6 months ago

Popping out for similar experience.

Removing the last empty line in the trio file would work.

drew-olson-tmru commented 6 months ago

That did not work for me. But now I am getting this:

There are 3 sets (populations/species) excluding the Outgroup /builddir/build/BUILD/gcc-11.4.1-20230605/obj-x86_64-redhat-linux/x86_64-redhat-linux/libstdc++-v3/include/bits/basic_string.h:1040: std::cxx11::basic_string<_CharT, _Traits, _Alloc>::const_reference std::cxx11::basic_string<_CharT, _Traits, _Alloc>::operator[](std::cxx11::basic_string<_CharT, _Traits, _Alloc>::size_type) const [with _CharT = char; _Traits = std::char_traits; _Alloc = std::allocator; std::cxx11::basic_string<_CharT, _Traits, _Alloc>::const_reference = const char&; std::__cxx11::basic_string<_CharT, _Traits, _Alloc>::size_type = long unsigned int]: Assertion '__pos <= size()' failed. Aborted (core dumped)

I know it is not a compilation error with the software because I can run the tutorial dataset just fine.