Skip to content

[BUG] fixelcfestats: -mask fix#2022

Merged
Lestropie merged 6 commits intodevfrom
fixelcfestats_mask_fix
Apr 18, 2020
Merged

[BUG] fixelcfestats: -mask fix#2022
Lestropie merged 6 commits intodevfrom
fixelcfestats_mask_fix

Conversation

@Lestropie
Copy link
Copy Markdown
Member

Description in 486267a.

Must have used relatively full fixel masks during testing on a release build, so the buffer overrun was never detected...

@diagiraldo: Please re-run using this code branch.

As part of #1693, fixelcfestats was modified to construct the subject data matrix based on all fixels, and then restrict processing to only those fixels inside the mask by filling subject data outside of the mask with NaNs and propagating the mask information to various functions. Previously, an index remapping was performed so that the subject data matrix would contain as many columns as there were fixels in the mask, and so input fixel indices would need to be projected to internal fixel indices. It appears as though during this change the allocation of the subject fixel data matrix was not properly updated to reflect its requisite larger size when the -mask option is used.
Reported in #1543.
@diagiraldo
Copy link
Copy Markdown

Did it, It runs to encounter another error:

fixelcfestats: [100%] Loading fixel data (no smoothing)
fixelcfestats: Non-finite values present in data; rows will be removed from fixel-wise design matrices accordingly
fixelcfestats: (Note that this will result in slower execution than if such values were not present)
fixelcfestats: [  3%] Calculating basic properties of default permutation... 
fixelcfestats: [SYSTEM FATAL CODE: SIGSEGV (11)] Segmentation fault: Invalid memory access

and the debugging backtrace is quite long:

fixelcfestats: [  3%] Calculating basic properties of default permutation... fixelcfestats: /usr/include/eigen3/Eigen/src/Core/DenseCoeffsBase.h:408: Eigen::DenseCoeffsBase<Derived, 1>::Scalar& Eigen::DenseCoeffsBase<Derived, 1>::operator[](Eigen::Index) [with Derived = Eigen::Array<double, -1, 1>; Eigen::DenseCoeffsBase<Derived, 1>::Scalar = double; Eigen::Index = long int]: Assertion `index >= 0 && index < size()' failed.

Thread 14 "fixelcfestats" received signal SIGABRT, Aborted.
[Switching to Thread 0x7fffea84e700 (LWP 22653)]
__GI_raise (sig=sig@entry=6) at ../sysdeps/unix/sysv/linux/raise.c:51
51	../sysdeps/unix/sysv/linux/raise.c: No such file or directory.
(gdb) bt
#0  __GI_raise (sig=sig@entry=6) at ../sysdeps/unix/sysv/linux/raise.c:51
#1  0x00007ffff5766801 in __GI_abort () at abort.c:79
#2  0x00007ffff575639a in __assert_fail_base (fmt=0x7ffff58dd7d8 "%s%s%s:%u: %s%sAssertion `%s' failed.\n%n", 
    assertion=assertion@entry=0x7ffff77dc63c "index >= 0 && index < size()", 
    file=file@entry=0x7ffff77dc590 "/usr/include/eigen3/Eigen/src/Core/DenseCoeffsBase.h", line=line@entry=408, 
    function=function@entry=0x7ffff77dec60 <Eigen::DenseCoeffsBase<Eigen::Array<double, -1, 1, 0, -1, 1>, 1>::operator[](long)::__PRETTY_FUNCTION__> "Eigen::DenseCoeffsBase<Derived, 1>::Scalar& Eigen::DenseCoeffsBase<Derived, 1>::operator[](Eigen::Index) [with Derived = Eigen::Array<double, -1, 1>; Eigen::DenseCoeffsBase<Derived, 1>::Scalar = doubl"...) at assert.c:92
#3  0x00007ffff5756412 in __GI___assert_fail (assertion=0x7ffff77dc63c "index >= 0 && index < size()", 
    file=0x7ffff77dc590 "/usr/include/eigen3/Eigen/src/Core/DenseCoeffsBase.h", line=408, 
    function=0x7ffff77dec60 <Eigen::DenseCoeffsBase<Eigen::Array<double, -1, 1, 0, -1, 1>, 1>::operator[](long)::__PRETTY_FUNCTION__> "Eigen::DenseCoeffsBase<Derived, 1>::Scalar& Eigen::DenseCoeffsBase<Derived, 1>::operator[](Eigen::Index) [with Derived = Eigen::Array<double, -1, 1>; Eigen::DenseCoeffsBase<Derived, 1>::Scalar = doubl"...) at assert.c:101
#4  0x00007ffff7369cb6 in Eigen::DenseCoeffsBase<Eigen::Array<double, -1, 1, 0, -1, 1>, 1>::operator[] (this=0x7fffffffd5c0, index=1920)
    at /usr/include/eigen3/Eigen/src/Core/DenseCoeffsBase.h:408
#5  0x00007ffff757071f in MR::Math::Stats::GLM::Functor::operator() (this=0x7fffffffcf98, element_index=@0x7fffd0004da0: 1920)
    at core/math/stats/glm.cpp:443
#6  0x00007ffff7579366 in MR::Thread::(anonymous namespace)::__Sink<MR::Thread::(anonymous namespace)::__Batch<long unsigned int>, MR::Thread::(anonymous namespace)::__Multi<MR::Math::Stats::GLM::all_stats(const matrix_type&, const matrix_type&, const MR::vector<MR::Math::Stats::CohortDataImport>&, const MR::vector<MR::Math::Stats::GLM::Hypothesis>&, const index_array_type&, MR::Math::Stats::vector_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&)::Functor> >::execute(void)
    (this=0x7fffffffcf90) at ./core/thread_queue.h:832
#7  0x00007ffff757a4be in std::__invoke_impl<void, void (MR::Thread::(anonymous namespace)::__Sink<MR::Thread::(anonymous namespace)::__Batch<long unsigned int>, MR::Thread::(anonymous namespace)::__Multi<MR::Math::Stats::GLM::all_stats(const matrix_type&, const matrix_type&, const MR::vector<MR::Math::Stats::CohortDataImport>&, const MR::vector<MR::Math::Stats::GLM::Hypothesis>&, const index_array_type&, MR::Math::Stats::vector_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&)::Functor> >::*)(), MR::Thread::(anonymous namespace)::__Sink<MR::Thread::(anonymous namespace)::__Batch<long unsigned int>, MR::Thread::(anonymous namespace)::__Multi<MR::Math::Stats::GLM::all_stats(const matrix_type&, const matrix_type&, const MR::vector<MR::Math::Stats::CohortDataImport>&, const MR::vector<MR::Math::Stats::GLM::Hypothesis>&, const index_array_type&, MR::Math::Stats::vector_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&)::Functor> >*>(std::__invoke_memfun_deref, void (MR::Thread::(anonymous namespace)::__Sink<MR::Thread::(anonymous namespace)::__Batch<long unsigned int>, MR::Thread::(anon---Type <return> to continue, or q <return> to quit---
ymous namespace)::__Multi<MR::Math::Stats::GLM::all_stats(const matrix_type&, const matrix_type&, const MR::vector<MR::Math::Stats::CohortDataImport>&, const MR::vector<MR::Math::Stats::GLM::Hypothesis>&, const index_array_type&, MR::Math::Stats::vector_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&)::Functor> >::*&&)(MR::Thread::(anonymous namespace)::__Sink<MR::Thread::(anonymous namespace)::__Batch<long unsigned int>, MR::Thread::(anonymous namespace)::__Multi<MR::Math::Stats::GLM::all_stats(const matrix_type&, const matrix_type&, const MR::vector<MR::Math::Stats::CohortDataImport>&, const MR::vector<MR::Math::Stats::GLM::Hypothesis>&, const index_array_type&, MR::Math::Stats::vector_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&)::Functor> > * const), MR::Thread::(anonymous namespace)::__Sink<MR::Thread::(anonymous namespace)::__Batch<long unsigned int>, MR::Thread::(anonymous namespace)::__Multi<MR::Math::Stats::GLM::all_stats(const matrix_type&, const matrix_type&, const MR::vector<MR::Math::Stats::CohortDataImport>&, const MR::vector<MR::Math::Stats::GLM::Hypothesis>&, const index_array_type&, MR::Math::Stats::vector_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&)::Functor> > *&&) (
    __f=@0x555555ecf5d0: (void (MR::Thread::(anonymous namespace)::__Sink<MR::Thread::(anonymous namespace)::__Batch<long unsigned int>, MR::Thread::(anonymous namespace)::__Multi<MR::Math::Stats::GLM::all_stats(const matrix_type&, const matrix_type&, const MR::vector<MR::Math::Stats::CohortDataImport>&, const MR::vector<MR::Math::Stats::GLM::Hypothesis>&, const index_array_type&, MR::Math::Stats::vector_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&)::Functor> >::*)(MR::Thread::(anonymous namespace)::__Sink<MR::Thread::(anonymous namespace)::__Batch<long unsigned int>, MR::Thread::(anonymous namespace)::__Multi<MR::Math::Stats::GLM::all_stats(const matrix_type&, const matrix_type&, const MR::vector<MR::Math::Stats::CohortDataImport>&, const MR::vector<MR::Math::Stats::GLM::Hypothesis>&, const index_array_type&, MR::Math::Stats::vector_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&)::Functor> > * const)) 0x7ffff7579308 <MR::Thread::(anonymous namespace)::__Sink<MR::Thread::(anonymous namespace)::__Batch<long unsigned int>, MR::Thread::(anonymous namespace)::__Multi<MR::Math::Stats::GLM::all_stats(const matrix_type&, const matrix_type&, const MR::vector<MR::Math::Stats::CohortDataImport>&, const MR::vector<MR::Math::Stats::GLM::Hypothesis>&, const index_array_type&, MR::Math::Stats::vector_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&)::Functor> >::execute(void)>, __t=@0x555555ecf5c8: 0x7fffffffcf90)
    at /usr/include/c++/7/bits/invoke.h:73
#8  0x00007ffff757942a in std::__invoke<void (MR::Thread::(anonymous namespace)::__Sink<MR::Thread::(anonymous namespace)::__Batch<long unsigned int>, MR::Thread::(anonymous namespace)::__Multi<MR::Math::Stats::GLM::all_stats(const matrix_type&, const matrix_type&, const MR::vector<MR::Math::Stats::CohortDataImport>&, const MR::vector<MR::Math::Stats::GLM::Hypothesis>&, const index_array_type&, MR::Math::Stats::vector_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&)::Functor> >::*)(), MR::Thread::(anonymous namespace)::__Sink<MR::Thread::(anonymous namespace)::__Batch<long unsigned int>, MR::Thread::(anonymous namespace)::__Multi<MR::Math::Stats::GLM::all_stats(const matrix_type&, const matrix_type&, const MR::vector<MR::Math::Stats::CohortDataImport>&, const MR::vector<MR::Math::Stats::GLM::Hypothesis>&, const index_array_type&, MR::Math::Stats::vector_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&)::Functor> >*>(void (MR::Thread::(anonymous namespace)::__Sink<MR::Thread::(anonymous namespace)::__Batch<long unsigned int>, MR::Thread::(anonymous namespace)::__Multi<MR::Math::Stats::GLM::all_stats(const matrix_type&, const matrix_type&, const MR::vector<MR::Math::Stats::CohortDataImport>&, const MR::vector<MR::Math::Stats::GLM::Hypothesis>&, const index_array_type&, MR::Math::Stats::vector_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&)::Functor> >::*&&)(MR::Thread::(anonymous namespace)::__Sink<MR::Thread::(anonymous namespace)::__Batch<long unsigned int>, MR::Thread::(anonymous namespace)::__Multi<MR::Math::Stats::GLM::all_stats(const matrix_type&, const matrix_type&, const MR::vector<MR::Math::Stats::CohortDataImport>&, const MR::vector<MR::Math::Stats::GLM::Hypothesis>&, const index_array_type&, MR::Math::Stats::vector_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&)::Functor> > * const)) (
    __fn=@0x555555ecf5d0: (void (MR::Thread::(anonymous namespace)::__Sink<MR::Thread::(anonymous namespace)::__Batch<long unsigned int>, MR::Thread::(anonymous namespace)::__Multi<MR::Math::Stats::GLM::all_stats(const matrix_type&, const matrix_type&, const MR::vector<MR::Math::Stats::CohortDataImport>&, const MR::vector<MR::Math::Stats::GLM::Hypothesis>&, const index_array_type&, MR::Math::Stats::vector_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&)::Functor> >::*)(MR::Thread::(anonymous namespace)::__Sink<MR::Thread::(anonymous namespace)::__Batch<long unsigned int>, MR::Thread::(anonymous namespace)::__Multi<MR::Math::Stats::GLM::all_stats(const matrix_type&, const matrix_type&, const MR::vector<MR::Math::Stats::CohortDataImport>&, const MR::vector<MR::Math::Stats::GLM::Hypothesis>&, const index_array_type&, MR::Math::Stats::vector_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&)::Functor> > * const)) 0x7ffff7579308 <MR::Thread::(anonym---Type <return> to continue, or q <return> to quit---
ous namespace)::__Sink<MR::Thread::(anonymous namespace)::__Batch<long unsigned int>, MR::Thread::(anonymous namespace)::__Multi<MR::Math::Stats::GLM::all_stats(const matrix_type&, const matrix_type&, const MR::vector<MR::Math::Stats::CohortDataImport>&, const MR::vector<MR::Math::Stats::GLM::Hypothesis>&, const index_array_type&, MR::Math::Stats::vector_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&)::Functor> >::execute(void)>) at /usr/include/c++/7/bits/invoke.h:95
#9  0x00007ffff757ef6b in std::thread::_Invoker<std::tuple<void (MR::Thread::(anonymous namespace)::__Sink<MR::Thread::(anonymous namespace)::__Batch<long unsigned int>, MR::Thread::(anonymous namespace)::__Multi<MR::Math::Stats::GLM::all_stats(const matrix_type&, const matrix_type&, const MR::vector<MR::Math::Stats::CohortDataImport>&, const MR::vector<MR::Math::Stats::GLM::Hypothesis>&, const index_array_type&, MR::Math::Stats::vector_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&)::Functor> >::*)(), MR::Thread::(anonymous namespace)::__Sink<MR::Thread::(anonymous namespace)::__Batch<long unsigned int>, MR::Thread::(anonymous namespace)::__Multi<MR::Math::Stats::GLM::all_stats(const matrix_type&, const matrix_type&, const MR::vector<MR::Math::Stats::CohortDataImport>&, const MR::vector<MR::Math::Stats::GLM::Hypothesis>&, const index_array_type&, MR::Math::Stats::vector_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&)::Functor> >*> >::_M_invoke<0, 1>(std::_Index_tuple<0, 1>) (this=0x555555ecf5c8) at /usr/include/c++/7/thread:234
#10 0x00007ffff757ee6a in std::thread::_Invoker<std::tuple<void (MR::Thread::(anonymous namespace)::__Sink<MR::Thread::(anonymous namespace)::__Batch<long unsigned int>, MR::Thread::(anonymous namespace)::__Multi<MR::Math::Stats::GLM::all_stats(const matrix_type&, const matrix_type&, const MR::vector<MR::Math::Stats::CohortDataImport>&, const MR::vector<MR::Math::Stats::GLM::Hypothesis>&, const index_array_type&, MR::Math::Stats::vector_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&)::Functor> >::*)(), MR::Thread::(anonymous namespace)::__Sink<MR::Thread::(anonymous namespace)::__Batch<long unsigned int>, MR::Thread::(anonymous namespace)::__Multi<MR::Math::Stats::GLM::all_stats(const matrix_type&, const matrix_type&, const MR::vector<MR::Math::Stats::CohortDataImport>&, const MR::vector<MR::Math::Stats::GLM::Hypothesis>&, const index_array_type&, MR::Math::Stats::vector_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&)::Functor> >*> >::operator()(void) (this=0x555555ecf5c8) at /usr/include/c++/7/thread:243
#11 0x00007ffff757eb52 in std::__future_base::_Task_setter<std::unique_ptr<std::__future_base::_Result<void>, std::__future_base::_Result_base::_Deleter>, std::thread::_Invoker<std::tuple<void (MR::Thread::(anonymous namespace)::__Sink<MR::Thread::(anonymous namespace)::__Batch<long unsigned int>, MR::Thread::(anonymous namespace)::__Multi<MR::Math::Stats::GLM::all_stats(const matrix_type&, const matrix_type&, const MR::vector<MR::Math::Stats::CohortDataImport>&, const MR::vector<MR::Math::Stats::GLM::Hypothesis>&, const index_array_type&, MR::Math::Stats::vector_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&)::Functor> >::*)(), MR::Thread::(anonymous namespace)::__Sink<MR::Thread::(anonymous namespace)::__Batch<long unsigned int>, MR::Thread::(anonymous namespace)::__Multi<MR::Math::Stats::GLM::all_stats(const matrix_type&, const matrix_type&, const MR::vector<MR::Math::Stats::CohortDataImport>&, const MR::vector<MR::Math::Stats::GLM::Hypothesis>&, const index_array_type&, MR::Math::Stats::vector_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&)::Functor> >*> >, void>::operator()(void) const (this=0x7fffea84ca20) at /usr/include/c++/7/future:1362
#12 0x00007ffff757e52a in std::_Function_handler<std::unique_ptr<std::__future_base::_Result_base, std::__future_base::_Result_base::_Deleter>(), std::__future_base::_Task_setter<std::unique_ptr<std::__future_base::_Result<void>, std::__future_base::_Result_base::_Deleter>, std::thread::_Invoker<std::tuple<void (MR::Thread::(anonymous namespace)::__Sink<MR::Thread::(anonymous namespace)::__Batch<long unsigned int>, MR::Thread::(anonymous namespace)::__Multi<MR::Math::Stats::GLM::all_stats(const matrix_type&, const matrix_type&, const MR::vector<MR::Math::Stats::CohortDataImport>&, const MR::vector<MR::Math::Stats::GLM::Hypothesis>&, const index_array_type&, MR::Math::Stats::vector_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&)::Functor> >::*)(), MR::Thread::(anonymous namespace)::__Sink<MR::Thread::(anonymous namespace)::__Batch<long unsigned int>, MR::Thread::(anonymous namespace)::__Multi<MR::Math::Stats::GLM::all_stats(const matrix_type&, const matrix_type&, const MR::vector<MR::Math::Stats::CohortDataImport>&, const MR::vector<MR::Math::Stats::GLM::Hypothesis>&, const index_array_type&, MR::Math::Stats::vector_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&)::Functor> >*> >, void> >::_M_invoke(const std::_Any_data &) (__functor=...) at /usr/include/c++/7/bits/std_function.h:302
#13 0x00005555556fa50c in std::function<std::unique_ptr<std::__future_base::_Result_base, std::__future_base::_Result_base::_Deleter> ()>::operator()() const (this=0x7fffea84ca20) at /usr/include/c++/7/bits/std_function.h:706
#14 0x00005555556f66b0 in std::__future_base::_State_baseV2::_M_do_set(std::function<std::unique_ptr<std::__future_base::_Result_base, std::__future_base::_Result_base::_Deleter> ()>*, bool*) (this=0x555555ecf590, __f=0x7fffea84ca20, __did_set=0x7fffea84c98f)
    at /usr/include/c++/7/future:561
#15 0x00005555557064ff in std::__invoke_impl<void, void (std::__future_base::_State_baseV2::*)(std::function<std::unique_ptr<std::__future_base::_Result_base, std::__future_base::_Result_base::_Deleter> ()>*, bool*), std::__future_base::_State_baseV2*, std::function<std::unique_ptr<std::__future_base::_Result_base, std::__future_base::_Result_base::_Deleter> ()>*, bool*>(std::__invoke_memfun_deref, void (std::__future_base::_State_baseV2::*&&)(std::function<std::unique_ptr<std::__future_base::_Result_base, std::__future_base::_Result_base::_Deleter> ()>*, bool*), std::__future_base::_State_baseV2*&&, std::function<std::unique_ptr<std::__future_base::_Result_base, std::__future_base::_Result_base::_Deleter> ()>*&&, bool*&&) (__f=
    @0x7fffea84c9d0: (void (std::__future_base::_State_baseV2::*)(std::__future_base::_State_baseV2 * const, std::function<std::unique_ptr<std::__future_base::_Result_base, std::__future_base::_Result_base::_Deleter>()> *, bool *)) 0x5555556f667a <std::__future_base::_State_baseV2::_M_do_set(std::function<std::unique_ptr<std::__future_base::_Result_base, std::__future_base::_Result_base::_Deleter> ()>*, bool*)>, 
    __t=@0x7fffea84c9a0: 0x555555ecf590) at /usr/include/c++/7/bits/invoke.h:73
#16 0x00005555556ffa74 in std::__invoke<void (std::__future_base::_State_baseV2::*)(std::function<std::unique_ptr<std::__future_base::_Result_base, std::__future_base::_Result_base::_Deleter> ()>*, bool*), std::__future_base::_State_baseV2*, std::function<std::unique_ptr<std::__future_base::_Result_base, std::__future_base::_Result_base::_Deleter> ()>*, bool*>(void (std::__future_base::_State_baseV2::*&&)(std::function<std::unique_ptr<std::__future_base::_Result_base, std::__future_base::_Result_base::_Deleter> ()>*, bool*), std::__future_base::_State_baseV2*&&, std::function<std::unique_ptr<std::__future_base::_Result_base, std::__future_base::_Result_base::_Deleter> ()>*&&, bool*&&) (
    __fn=
    @0x7fffea84c9d0: (void (std::__future_base::_State_baseV2::*)(std::__future_base::_State_baseV2 * const, std::function<std::unique_ptr<std::__future_base::_Result_base, std::__future_base::_Result_base::_Deleter>()> *, bool *)) 0x5555556f667a <std::__future_base::_State_baseV2::_M_do_set(std::function<std::unique_ptr<std::__future_base::_Result_base, std::__future_base::_Result_base::_Deleter> ()>*, bool*)>)
    at /usr/include/c++/7/bits/invoke.h:95
#17 0x00005555556fa1de in void std::call_once<void (std::__future_base::_State_baseV2::*)(std::function<std::unique_ptr<std::__future_base::_Result_base, std::__future_base::_Result_base::_Deleter> ()>*, bool*), std::__future_base::_State_baseV2*, std::function<std::unique_ptr<std::__future_base::_Result_base, std::__future_base::_Result_base::_Deleter> ()>*, bool*>(std::once_flag&, void (std::__future_base::_State_baseV2::*&&)(std::function<std::unique_ptr<std::__future_base::_Result_base, std::__future_base::_Result_base::_Deleter> ()>*, bool*), std::__future_base::_State_baseV2*&&, std::function<std::unique_ptr<std::__future_base::_Result_base, std::__future_base::_Result_base::_Deleter> ()>*&&, bool*&&)::{lambda()#1}::operator()() const (__closure=0x7fffea84c910) at /usr/include/c++/7/mutex:672
#18 0x00005555556fa249 in void std::call_once<void (std::__future_base::_State_baseV2::*)(std::function<std::unique_ptr<std::__future_base::_Result_base, std::__future_base::_Result_base::_Deleter> ()>*, bool*), std::__future_base::_State_baseV2*, std::function<std::unique_ptr<std::__future_base::_Result_base, std::__future_base::_Result_base::_Deleter> ()>*, bool*>(std::once_flag&, void (std::__future_base::_State_baseV2::*&&)(std::function<std::unique_ptr<std::__future_base::_Result_base, std::__future_base::_Result_base::_Deleter> ()>*, bool*), std::__future_base::_State_baseV2*&&, std::function<std::unique_ptr<std::__future_base::_Result_base, std::__future_base::_Result_base::_Deleter> ()>*&&, bool*&&)::{lambda()#2}::operator()() const (__closure=0x0) at /usr/include/c++/7/mutex:677
#19 0x00005555556fa25a in void std::call_once<void (std::__future_base::_State_baseV2::*)(std::function<std::unique_ptr<std::__future_base::_Result_base, std::__future_base::_Result_base::_Deleter> ()>*, bool*), std::__future_base::_State_baseV2*, std::function<std::unique_ptr<std::__future_base::_Result_base, std::__future_base::_Result_base::_Deleter> ()>*, bool*>(std::once_flag&, void (std::__future_base::_State_baseV2::*&&)(std::function<std::unique_ptr<std::__future_base::_Result_base, std::__future_base::_Result_base::_Deleter> ()>*, bool*), std::__future_base::_State_baseV2*&&, std::function<std::unique_ptr<std::__future_base::_Result_base, std::__future_base::_Result_base::_Deleter> ()>*&&, bool*&&)::{lambda()#2}::_FUN() () at /usr/include/c++/7/mutex:677
#20 0x00007ffff5b26827 in __pthread_once_slow (once_control=0x555555ecf5a8, init_routine=0x7ffff63a88a0 <__once_proxy>)
    at pthread_once.c:116
#21 0x00005555556d80a5 in __gthread_once (__once=0x555555ecf5a8, __func=0x7ffff63a88a0 <__once_proxy>)
    at /usr/include/x86_64-linux-gnu/c++/7/bits/gthr-default.h:699
#22 0x00005555556fa313 in std::call_once<void (std::__future_base::_State_baseV2::*)(std::function<std::unique_ptr<std::__future_base::_Result_base, std::__future_base::_Result_base::_Deleter> ()>*, bool*), std::__future_base::_State_baseV2*, std::function<std::unique_ptr<std::__future_base::_Result_base, std::__future_base::_Result_base::_Deleter> ()>*, bool*>(std::once_flag&, void (std::__future_base::_State_baseV2::*&&)(std::function<std::unique_ptr<std::__future_base::_Result_base, std::__future_base::_Result_base::_Deleter> ()>*, bool*), std::__future_base::_State_baseV2*&&, std::function<std::unique_ptr<std::__future_base::_Result_base, std::__future_base::_Result_base::_Deleter> ()>*&&, bool*&&) (__once=..., __f=
 @0x7fffea84c9d0: (void (std::__future_base::_State_baseV2::*)(std::__future_base::_State_baseV2 * const, std::function<std::unique_ptr<std::__future_base::_Result_base, std::__future_base::_Result_base::_Deleter>()> *, bool *)) 0x5555556f667a <std::__future_base::_State_baseV2::_M_do_set(std::function<std::unique_ptr<std::__future_base::_Result_base, std::__future_base::_Result_base::_Deleter> ()>*, bool*)>)
    at /usr/include/c++/7/mutex:684
#23 0x00005555556f6450 in std::__future_base::_State_baseV2::_M_set_result(std::function<std::unique_ptr<std::__future_base::_Result_base, std::__future_base::_Result_base::_Deleter> ()>, bool) (this=0x555555ecf590, __res=..., __ignore_failure=false)
    at /usr/include/c++/7/future:401
#24 0x00007ffff757d9be in std::__future_base::_Async_state_impl<std::thread::_Invoker<std::tuple<void (MR::Thread::(anonymous namespace)::__Sink<MR::Thread::(anonymous namespace)::__Batch<long unsigned int>, MR::Thread::(anonymous namespace)::__Multi<MR::Math::Stats::GLM::all_stats(const matrix_type&, const matrix_type&, const MR::vector<MR::Math::Stats::CohortDataImport>&, const MR::vector<MR::Math::Stats::GLM::Hypothesis>&, const index_array_type&, MR::Math::Stats::vector_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&)::Functor> >::*)(), MR::Thread::(anonymous namespace)::__Sink<MR::Thread::(anonymous namespace)::__Batch<long unsigned int>, MR::Thread::(anonymous namespace)::__Multi<MR::Math::Stats::GLM::all_stats(const matrix_type&, const matrix_type&, const MR::vector<MR::Math::Stats::CohortDataImport>&, const MR::vector<MR::Math::Stats::GLM::Hypothesis>&, const index_array_type&, MR::Math::Stats::vector_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&)::Functor> >*> >, void>::<lambda()>::operator()(void) const (__closure=0x555555ed1db8) at /usr/include/c++/7/future:1667
#25 0x00007ffff757e745 in std::__invoke_impl<void, std::__future_base::_Async_state_impl<_BoundFn, _Res>::_Async_state_impl(_BoundFn&&) [with _BoundFn = std::thread::_Invoker<std::tuple<void (MR::Thread::(anonymous namespace)::__Sink<MR::Thread::(anonymous namespace)::__Batch<long unsigned int>, MR::Thread::(anonymous namespace)::__Multi<MR::Math::Stats::GLM::all_stats(const matrix_type&, const matrix_type&, const MR::vector<MR::Math::Stats::CohortDataImport>&, const MR::vector<MR::Math::Stats::GLM::Hypothesis>&, const index_array_type&, MR::Math::Stats::vector_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&)::Functor> >::*)(), MR::Thread::(anonymous namespace)::__Sink<MR::Thread::(anonymous namespace)::__Batch<long unsigned int>, MR::Thread::(anonymous namespace)::__Multi<MR::Math::Stats::GLM::all_stats(const matrix_type&, const matrix_type&, const MR::vector<MR::Math::Stats::CohortDataImport>&, const MR::vector<MR::Math::Stats::GLM::Hypothesis>&, const index_array_type&, MR::Math::Stats::vector_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&)::Functor> >*> >; _Res = void]::<lambda()> >(std::__invoke_other, std::__future_base::_Async_state_impl<std::thread::_Invoker<std::tuple<void (MR::Thread::(anonymous namespace)::__Sink<MR::Thread::(anonymous namespace)::__Batch<long unsigned int>, MR::Thread::(anonymous namespace)::__Multi<MR::Math::Stats::GLM::all_stats(const matrix_type&, const matrix_type&, const MR::vector<MR::Math::Stats::CohortDataImport>&, const MR::vector<MR::Math::Stats::GLM::Hypothesis>&, const index_array_type&, MR::Math::Stats::vector_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&)::Functor> >::*)(), MR::Thread::(anonymous namespace)::__Sink<MR::Thread::(anonymous namespace)::__Batch<long unsigned int>, MR::Thread::(anonymous namespace)::__Multi<MR::Math::Stats::GLM::all_stats(const matrix_type&, const matrix_type&, const MR::vector<MR::Math::Stats::CohortDataImport>&, const MR::vector<MR::Math::Stats::GLM::Hypothesis>&, const index_array_type&, MR::Math::Stats::vector_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&)::Functor> >*> >, void>::<lambda()> &&) (__f=...) at /usr/include/c++/7/bits/invoke.h:60
#26 0x00007ffff757e02d in std::__invoke<std::__future_base::_Async_state_impl<_BoundFn, _Res>::_Async_state_impl(_BoundFn&&) [with _BoundFn = std::thread::_Invoker<std::tuple<void (MR::Thread::(anonymous namespace)::__Sink<MR::Thread::(anonymous namespace)::__Batch<long unsigned int>, MR::Thread::(anonymous namespace)::__Multi<MR::Math::Stats::GLM::all_stats(const matrix_type&, const matrix_type&, const MR::vector<MR::Math::Stats::CohortDataImport>&, const MR::vector<MR::Math::Stats::GLM::Hypothesis>&, const index_array_type&, MR::Math::Stats::vector_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&)::Functor> >::*)(), MR::Thread::(anonymous namespace)::__Sink<MR::Thread::(anonymous namespace)::__Batch<long unsigned int>, MR::Thread::(anonymous namespace)::__Multi<MR::Math::Stats::GLM::all_stats(const matrix_type&, const matrix_type&, const MR::vector<MR::Math::Stats::CohortDataImport>&, const MR::vector<MR::Math::Stats::GLM::Hypothesis>&, const index_array_type&, MR::Math::Stats::vector_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&)::Functor> >*> >; _Res = void]::<lambda()> >(std::__future_base::_Async_state_impl<std::thread::_Invoker<std::tuple<void (MR::Thread::(anonymous namespace)::__Sink<MR::Thread::(anonymous namespace)::__Batch<long unsigned int>, MR::Thread::(anonymous namespace)::__Multi<MR::Math::Stats::GLM::all_stats(const matrix_type&, const matrix_type&, const MR::vector<MR::Math::Stats::CohortDataImport>&, const MR::vector<MR::Math::Stats::GLM::Hypothesis>&, const index_array_type&, MR::Math::Stats::vector_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&)::Functor> >::*)(), MR::Thread::(anonymous namespace)::__Sink<MR::Thread::(anonymous namespace)::__Batch<long unsigned ---Type <return> to continue, or q <return> to quit---
int>, MR::Thread::(anonymous namespace)::__Multi<MR::Math::Stats::GLM::all_stats(const matrix_type&, const matrix_type&, const MR::vector<MR::Math::Stats::CohortDataImport>&, const MR::vector<MR::Math::Stats::GLM::Hypothesis>&, const index_array_type&, MR::Math::Stats::vector_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&)::Functor> >*> >, void>::<lambda()> &&) (__fn=...) at /usr/include/c++/7/bits/invoke.h:95
#27 0x00007ffff757fd9c in std::thread::_Invoker<std::tuple<std::__future_base::_Async_state_impl<_BoundFn, _Res>::_Async_state_impl(_BoundFn&&) [with _BoundFn = std::thread::_Invoker<std::tuple<void (MR::Thread::(anonymous namespace)::__Sink<MR::Thread::(anonymous namespace)::__Batch<long unsigned int>, MR::Thread::(anonymous namespace)::__Multi<MR::Math::Stats::GLM::all_stats(const matrix_type&, const matrix_type&, const MR::vector<MR::Math::Stats::CohortDataImport>&, const MR::vector<MR::Math::Stats::GLM::Hypothesis>&, const index_array_type&, MR::Math::Stats::vector_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&)::Functor> >::*)(), MR::Thread::(anonymous namespace)::__Sink<MR::Thread::(anonymous namespace)::__Batch<long unsigned int>, MR::Thread::(anonymous namespace)::__Multi<MR::Math::Stats::GLM::all_stats(const matrix_type&, const matrix_type&, const MR::vector<MR::Math::Stats::CohortDataImport>&, const MR::vector<MR::Math::Stats::GLM::Hypothesis>&, const index_array_type&, MR::Math::Stats::vector_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&)::Functor> >*> >; _Res = void]::<lambda()> > >::_M_invoke<0>(std::_Index_tuple<0>) (this=0x555555ed1db8) at /usr/include/c++/7/thread:234
#28 0x00007ffff757fc10 in std::thread::_Invoker<std::tuple<std::__future_base::_Async_state_impl<_BoundFn, _Res>::_Async_state_impl(_BoundFn&&) [with _BoundFn = std::thread::_Invoker<std::tuple<void (MR::Thread::(anonymous namespace)::__Sink<MR::Thread::(anonymous namespace)::__Batch<long unsigned int>, MR::Thread::(anonymous namespace)::__Multi<MR::Math::Stats::GLM::all_stats(const matrix_type&, const matrix_type&, const MR::vector<MR::Math::Stats::CohortDataImport>&, const MR::vector<MR::Math::Stats::GLM::Hypothesis>&, const index_array_type&, MR::Math::Stats::vector_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&)::Functor> >::*)(), MR::Thread::(anonymous namespace)::__Sink<MR::Thread::(anonymous namespace)::__Batch<long unsigned int>, MR::Thread::(anonymous namespace)::__Multi<MR::Math::Stats::GLM::all_stats(const matrix_type&, const matrix_type&, const MR::vector<MR::Math::Stats::CohortDataImport>&, const MR::vector<MR::Math::Stats::GLM::Hypothesis>&, const index_array_type&, MR::Math::Stats::vector_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&)::Functor> >*> >; _Res = void]::<lambda()> > >::operator()(void) (this=0x555555ed1db8) at /usr/include/c++/7/thread:243
#29 0x00007ffff757f380 in std::thread::_State_impl<std::thread::_Invoker<std::tuple<std::__future_base::_Async_state_impl<_BoundFn, _Res>::_Async_state_impl(_BoundFn&&) [with _BoundFn = std::thread::_Invoker<std::tuple<void (MR::Thread::(anonymous namespace)::__Sink<MR::Thread::(anonymous namespace)::__Batch<long unsigned int>, MR::Thread::(anonymous namespace)::__Multi<MR::Math::Stats::GLM::all_stats(const matrix_type&, const matrix_type&, const MR::vector<MR::Math::Stats::CohortDataImport>&, const MR::vector<MR::Math::Stats::GLM::Hypothesis>&, const index_array_type&, MR::Math::Stats::vector_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&)::Functor> >::*)(), MR::Thread::(anonymous namespace)::__Sink<MR::Thread::(anonymous namespace)::__Batch<long unsigned int>, MR::Thread::(anonymous namespace)::__Multi<MR::Math::Stats::GLM::all_stats(const matrix_type&, const matrix_type&, const MR::vector<MR::Math::Stats::CohortDataImport>&, const MR::vector<MR::Math::Stats::GLM::Hypothesis>&, const index_array_type&, MR::Math::Stats::vector_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&, MR::Math::Stats::matrix_type&)::Functor> >*> >; _Res = void]::<lambda()> > > >::_M_run(void) (this=0x555555ed1db0) at /usr/include/c++/7/thread:186
#30 0x00007ffff63a96df in ?? () from /usr/lib/x86_64-linux-gnu/libstdc++.so.6
#31 0x00007ffff5b1e6db in start_thread (arg=0x7fffea84e700) at pthread_create.c:463
#32 0x00007ffff584788f in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:95

Resulted in omission of connectivity for a small-indexed fixel in some circumstances.
@Lestropie
Copy link
Copy Markdown
Member Author

Turns out bug fixed in 0a97144 has been lying around for a while... Not likely to be of consequence though, basically there's a chance that one or two fixels near the bottom corner of the image won't get smoothed.

@Lestropie
Copy link
Copy Markdown
Member Author

Given I failed to adequately test the changes to fixelcfestats -mask handling in #1693, I wanted to yet again check this stuff before it goes out. Where possible, the test data brought in in d2de9cc were generated using 3.0_RC3 (incorporating fixes in 0a97144 and #1759) in order to ensure consistency with results prior to #1543.

@diagiraldo
Copy link
Copy Markdown

I tried it today,
The command with the small fixel mask and -notest option works,
With the small fixel mask and permutations, it works too.
With the entire analysis mask and permutations it also works!!! 😃 🎉

@Lestropie Lestropie merged commit dc13e35 into dev Apr 18, 2020
@Lestropie Lestropie deleted the fixelcfestats_mask_fix branch April 18, 2020 16:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants