<div dir="ltr"><div class="gmail_extra"><div class="gmail_quote">On Mon, Feb 12, 2018 at 10:57 PM, Adrian Croucher <span dir="ltr"><<a href="mailto:a.croucher@auckland.ac.nz" target="_blank">a.croucher@auckland.ac.nz</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">hi,<br>
<br>
I have a DMPlex which I pass in to DMCreateGlobalVector() to create a vector, and then use VecView() to view the vector.<br>
<br>
If the DM happens to contain no points on one process, this still works fine if I view the vector using PETSC_VIEWER_STDOUT_WORLD.<br>
<br>
However if I create an HDF5 viewer using PetscViewerHDF5Open() and try to view the vector using that, it crashes with the error message "Could not classify input Vec for VTK".<br>
<br>
It goes into VecView_Plex_Local_HDF5_Intern<wbr>al(), which calls DMPlexGetFieldType_Internal() (plex.c:93). This has some conditionals testing if vStart < pEnd or cStart < pEnd, which are never satisfied because pEnd = 0. This is what leads to it raising the error.<br>
<br>
This function returns the point range sStart, sEnd and field type ft. To handle the case where there are no points on the process, should it perhaps just return sStart, sEnd = 0,0 and a default (or maybe null) value for ft?</blockquote><div><br></div><div>Crap, this is a problem. I will have to put some parallel code in there because everyone must agree on the ft.</div><div><br></div><div>   Matt</div><div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><span class="HOEnZb"><font color="#888888"><br>
- Adrian<br>
<br>
-- <br>
Dr Adrian Croucher<br>
Senior Research Fellow<br>
Department of Engineering Science<br>
University of Auckland, New Zealand<br>
email: <a href="mailto:a.croucher@auckland.ac.nz" target="_blank">a.croucher@auckland.ac.nz</a><br>
tel: <a href="tel:%2B64%20%280%299%20923%204611" value="+6499234611" target="_blank">+64 (0)9 923 4611</a><br>
<br>
</font></span></blockquote></div><br><br clear="all"><div><br></div>-- <br><div class="gmail_signature" data-smartmail="gmail_signature"><div dir="ltr"><div><div dir="ltr"><div>What most experimenters take for granted before they begin their experiments is infinitely more interesting than any results to which their experiments lead.<br>-- Norbert Wiener</div><div><br></div><div><a href="http://www.caam.rice.edu/~mk51/" target="_blank">https://www.cse.buffalo.edu/~knepley/</a><br></div></div></div></div></div>
</div></div>