Hi Roy

I am trying to implement this one: comm().allgather(vector<MyClass>).

The compiler fails.
It says MyClass is not a StandardType.
I tried with a tuple<>, without success.

Any suggestion?
Should I specialize a Packing<MyClass *> or so?
I can see that for vector<string>, everything works fine.


/usr/local/include/libmesh/parallel.h: In instantiation of ‘class
libMesh::Parallel::StandardType<abada_lib::MyClass>’:
/usr/local/include/libmesh/parallel_implementation.h:3251:23:   required
from ‘void
libMesh::Parallel::Communicator::allgather(std::__debug::vector<_RealType>&,
bool) const [with T = abada_lib::MyClass]’
src/abada_lib/Abada_sc10.cxx:323:32:   required from here
/usr/local/include/libmesh/parallel.h:387:3: error: static assertion
failed: Only specializations of StandardType may be used, did you forget to
include a header file (e.g. parallel_algebra.h)?
   static_assert(dependent_false<T>::value,


Renato


On Fri, Jun 29, 2018 at 9:54 AM, Renato Poli <rebp...@gmail.com> wrote:

> Thank you!
>
> On Thu, Jun 28, 2018 at 6:04 PM, Roy Stogner <royst...@ices.utexas.edu>
> wrote:
>
>>
>> On Thu, 28 Jun 2018, Renato Poli wrote:
>>
>> How can I do this (I am not a MPI guy at all, so please be patient ...):
>>>
>>
>> > ... after each processor makes its own local vector, just
>>> > allgather those into a giant serial vector ...
>>>
>>
>> I'm not a big fan of MPI myself, which is why we've got it wrapped up
>> as much as possible.
>>
>> https://github.com/libMesh/libmesh/blob/716878d0c5631a7b7488
>> c88fd1de78025231b115/include/parallel/communicator.h#L664
>>
>> is the comment (with API below) for what I described above.
>> ---
>> Roy
>>
>
>
------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Libmesh-users mailing list
Libmesh-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/libmesh-users

Reply via email to