You need to first convert the Vec to the "natural" ordering and then bring
that vector down to one rank. Something like
DMDACreateNaturalVector(dm,);
DMDAGlobalToNaturalBegin/End(dm, n);
> VecScatterCreateToZero(n, , );
> VecScatterBegin(scat, n Xseq, INSERT_VALUES, SCATTER_FORWARD);
>
Hello,
I have a code that handles a PETSc Vec on many procs and I would like to use
VecScatterCreateToZero to have all elements of this vector on a single proc,
call VecGetArrayRead on this proc to get the corresponding array to carry out
some diagnostics.
Unfortunately, what I noticed is
"Barletta, Ivano" writes:
> Hello PETSc users
>
> I was wondering if you've got any suggestion for the issue
> mentioned in the topic.
>
> I'm solving a linear system on my unstructured grid that has its
> own partitioning. When I set up the linear system in PETSc I
> use the
On Mon, Feb 13, 2017 at 5:51 AM, Barletta, Ivano wrote:
> Hello PETSc users
>
> I was wondering if you've got any suggestion for the issue
> mentioned in the topic.
>
> I'm solving a linear system on my unstructured grid that has its
> own partitioning. When I set up the
Hello PETSc users
I was wondering if you've got any suggestion for the issue
mentioned in the topic.
I'm solving a linear system on my unstructured grid that has its
own partitioning. When I set up the linear system in PETSc I
use the model partitioning whose grid points might not be
evenly
Hello,
I am trying to use VecScatter to grab values from nonlocal processors, and
I've run into the following error when I try to run for 8+ processors. The
error is as follows:
[0]PETSC ERROR: VecScatterCreate() line 1161 in src/vec/vec/utils/vscat.c
And the code that causes it is
Mat A
There are several problems with this code.
On Jul 1, 2014, at 12:04 PM, Arthur Kurlej akur...@gmail.com wrote:
Hello,
I am trying to use VecScatter to grab values from nonlocal processors, and
I've run into the following error when I try to run for 8+ processors. The
error is as
On Thu, Oct 3, 2013 at 2:07 PM, Randall Mackie rlmackie...@gmail.comwrote:
I am trying to create a VecScatter that will scatter all the values from a
horizontal slice of a 3D DMDA global vector (with dof=3) to a sequential
vector on every processor. So far I have been unsuccessful, most likely
Randy,
Take a look at DMDAGetRay() in src/dm/impls/da/dasub.c (now called
DMDACreateRay()) this takes a row or column from a 2d DADM. You can use the
same kind of approach to get a slice from a 3d DMDA.
Barry
On Oct 3, 2013, at 2:07 PM, Randall Mackie rlmackie...@gmail.com
On Oct 3, 2013, at 12:24 PM, Matthew Knepley knep...@gmail.com wrote:
On Thu, Oct 3, 2013 at 2:07 PM, Randall Mackie rlmackie...@gmail.com wrote:
I am trying to create a VecScatter that will scatter all the values from a
horizontal slice of a 3D DMDA global vector (with dof=3) to a
On Apr 19, 2013, at 5:15 PM, Hui Zhang wrote:
I'm doing something like gasm.c. I can construct one VecScatte from comm to
each subcomm. But I can also construct VecScatter's from comm to the
processors in subcomm. Which mode do you think is good? Why? Thanks for
teaching me!
After
I'm doing something like gasm.c. I can construct one VecScatte from comm to
each subcomm. But I can also construct VecScatter's from comm to the
processors in subcomm. Which mode do you think is good? Why? Thanks for
teaching me!
Hi guys,
I'm just wondering if I understand how the VecScatter works. Considering
(petsc 3.2-p6 manual page 53):
VecScatterCreate(Vec x,IS ix,Vec y,IS iy,VecScatter *ctx);
VecScatterBegin(VecScatter ctx,Vec x,Vec y,INSERT VALUES,SCATTER FORWARD);
VecScatterEnd(VecScatter ctx,Vec x,Vec y,INSERT
On Thu, 9 Feb 2012, Mohammad Mirzadeh wrote:
Hi guys,
I'm just wondering if I understand how the VecScatter works. Considering
(petsc 3.2-p6 manual page 53):
VecScatterCreate(Vec x,IS ix,Vec y,IS iy,VecScatter *ctx);
VecScatterBegin(VecScatter ctx,Vec x,Vec y,INSERT VALUES,SCATTER
So this actually means it somehow matches the local indecies? What i mean
by that is,
y[ iy[i] ] = x[ ix[i] ].
Is that why ix and iy should have the same size?
Mohammad
On Thu, Feb 9, 2012 at 3:17 PM, Satish Balay balay at mcs.anl.gov wrote:
On Thu, 9 Feb 2012, Mohammad Mirzadeh wrote:
Hi
On Thu, 9 Feb 2012, Mohammad Mirzadeh wrote:
So this actually means it somehow matches the local indices?
Hm - no local indices here.
What i mean by that is,
y[ iy[i] ] = x[ ix[i] ].
Sure - with global indices.
Is that why ix and iy should have the same size?
When you specify data
Thanks Satish. That all makes sense.
Truth is I am trying to move data from a parallel vector to a serial one on
rank 0. I make an index set, in parallel, with stride 1 and use it for both
source and destination and i believe that should do the job ... but it does
not. Somehow it seems that the
Alright just got it :D The IS needs to be build in serial otherwise each
processor only copies the portion it owns!
Thanks,
Mohammad
On Thu, Feb 9, 2012 at 3:52 PM, Mohammad Mirzadeh mirzadeh at gmail.comwrote:
Thanks Satish. That all makes sense.
Truth is I am trying to move data from a
Hi all,
When using
PetscErrorCode VecScatterCreate(Vec xin,IS ix,Vec yin,IS iy,VecScatter *newctx)
I want to add those values of xin to the original values of yin.
Is there a way to do this without copy of yin?
Thanks!
Hui
-- next part --
An HTML attachment was
On Wed, Sep 28, 2011 at 3:54 PM, Hui Zhang mike.hui.zhang at hotmail.comwrote:
Hi all,
When using
PetscErrorCode VecScatterCreate(Vec xin,IS ix,Vec yin,IS iy,VecScatter
*newctx)
I want to add those values of xin to the original values of yin.
Is there a way to do this without copy of
On Sep 28, 2011, at 5:58 PM, Matthew Knepley wrote:
On Wed, Sep 28, 2011 at 3:54 PM, Hui Zhang mike.hui.zhang at hotmail.com
wrote:
Hi all,
When using
PetscErrorCode VecScatterCreate(Vec xin,IS ix,Vec yin,IS iy,VecScatter
*newctx)
I want to add those values of xin to the original
On Wed, Sep 28, 2011 at 4:05 PM, Hui Zhang mike.hui.zhang at hotmail.comwrote:
On Sep 28, 2011, at 5:58 PM, Matthew Knepley wrote:
On Wed, Sep 28, 2011 at 3:54 PM, Hui Zhang mike.hui.zhang at
hotmail.comwrote:
Hi all,
When using
PetscErrorCode VecScatterCreate(Vec xin,IS ix,Vec
On Sep 28, 2011, at 6:08 PM, Matthew Knepley wrote:
On Wed, Sep 28, 2011 at 4:05 PM, Hui Zhang mike.hui.zhang at hotmail.com
wrote:
On Sep 28, 2011, at 5:58 PM, Matthew Knepley wrote:
On Wed, Sep 28, 2011 at 3:54 PM, Hui Zhang mike.hui.zhang at hotmail.com
wrote:
Hi all,
When using
On Wed, Sep 28, 2011 at 4:15 PM, Hui Zhang mike.hui.zhang at hotmail.comwrote:
On Sep 28, 2011, at 6:08 PM, Matthew Knepley wrote:
On Wed, Sep 28, 2011 at 4:05 PM, Hui Zhang mike.hui.zhang at
hotmail.comwrote:
On Sep 28, 2011, at 5:58 PM, Matthew Knepley wrote:
On Wed, Sep 28, 2011 at
On Sep 28, 2011, at 6:16 PM, Matthew Knepley wrote:
On Wed, Sep 28, 2011 at 4:15 PM, Hui Zhang mike.hui.zhang at hotmail.com
wrote:
On Sep 28, 2011, at 6:08 PM, Matthew Knepley wrote:
On Wed, Sep 28, 2011 at 4:05 PM, Hui Zhang mike.hui.zhang at hotmail.com
wrote:
On Sep 28, 2011,
On Tue, Aug 30, 2011 at 1:36 AM, Jed Brown jedbrown at mcs.anl.gov wrote:
On Mon, Aug 29, 2011 at 20:32, Tabrez Ali stali at geology.wisc.edu wrote:
If during Vecscatter (say from a global vector x to a local vector y) if
'is' and 'iy' are such that almost all values being scattered happen to
Hello
If during Vecscatter (say from a global vector x to a local vector y) if
'is' and 'iy' are such that almost all values being scattered happen to
be on the local proc then almost 0 or very little MPI calls would be
made internally. Is this correct?
Such a setup would not cause
On Aug 29, 2011, at 8:32 PM, Tabrez Ali wrote:
Hello
If during Vecscatter (say from a global vector x to a local vector y) if 'is'
and 'iy' are such that almost all values being scattered happen to be on the
local proc then almost 0 or very little MPI calls would be made internally.
Is
On Mon, Aug 29, 2011 at 20:32, Tabrez Ali stali at geology.wisc.edu wrote:
If during Vecscatter (say from a global vector x to a local vector y) if
'is' and 'iy' are such that almost all values being scattered happen to be
on the local proc then almost 0 or very little MPI calls would be made
On Wed, Aug 3, 2011 at 04:08, Mohammad Mirzadeh mirzadeh at gmail.com wrote:
I have a question regarding the VecScatter routine. If I make a call like:
VecScatterCreate(old_vec, PETSC_NULL, new_vec, is_scat, vec_scat);
This creates map from the entire old_vec to the subset of new_vec indexed
Thank you Jed.
On Wed, Aug 3, 2011 at 6:47 AM, Jed Brown jedbrown at mcs.anl.gov wrote:
On Wed, Aug 3, 2011 at 04:08, Mohammad Mirzadeh mirzadeh at gmail.comwrote:
I have a question regarding the VecScatter routine. If I make a call like:
VecScatterCreate(old_vec, PETSC_NULL, new_vec,
31 matches
Mail list logo