[petsc-users] Scatter parallel Vec to sequential Vec on non-zeroth process

Peder Jørgensgaard Olesen pjool at mek.dtu.dk
Thu Jul 1 07:20:04 CDT 2021


Dear Jed


I'm not really sure what it is you're asking (that's on me, still a rookie in the field), but I'll try to describe what I've done:


Each process is assigned an indexed subset of the tasks (the tasks are of constant size), and, for each task index, the relevant data is scattered as a SEQVEC to the process (this is done for all processes in each step, using an adaption of the code in Matt's link). This way each process only receives just the data it needs to complete the task. While I'm currently working with very moderate size data sets I'll eventually need to handle something rather more massive, so I want to economize memory where possible and give each process only the data it needs.


Med venlig hilsen / Best regards

Peder

________________________________
Fra: Jed Brown <jed at jedbrown.org>
Sendt: 30. juni 2021 16:41:25
Til: Peder Jørgensgaard Olesen; Junchao Zhang
Cc: petsc-users at mcs.anl.gov
Emne: Re: [petsc-users] Scatter parallel Vec to sequential Vec on non-zeroth process

Peder Jørgensgaard Olesen via petsc-users       <petsc-users at mcs.anl.gov> writes:

> I'm distributing a set of independent tasks over different processes, so I'm afraid sending everything to the zeroth process would rather thoroughly defeat the purpose of what I'm doing.

It sounds like you're going to run this a bunch of times. Does it have to be sequential (gather to one rank at a time) or can it be an alltoall?
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mcs.anl.gov/pipermail/petsc-users/attachments/20210701/33a34a95/attachment-0001.html>


More information about the petsc-users mailing list