[Paraview] XDMF Set

Chris Richardson chris at bpi.cam.ac.uk
Fri May 29 04:21:40 EDT 2015


On 29/05/2015 04:20, David E DeMarle wrote:
> Responses in line.
> 
> On Thu, May 14, 2015 at 4:47 AM, Chris Richardson
> <chris at bpi.cam.ac.uk> wrote:
> 
>> I guess that leads to the following questions:
>> 
>> 1) When will Xdmf3 be used by ParaView?
> 
> I want to deprecate Xdmf2 and make Xdmf3 the default the next release.
> Because Xdmf3 adds a dependency on boost Xdmf will have to become
> optional in ParaView. The Kitware binaries will have it on because we
> already Superbuild in boost for the VisItBridge, but other versions
> could easily drop it.
> 
>> 2) Does 2D work properly?
> 
> I don't think I tested that particular path in Xdmf3.  If you can make
> a small test dataset which disproves its working, I'll likely be able
> to fix it and add it to the regression test suite for Xdmf3 in VTK.
> 

I guess this should work...

<?xml version="1.0" ?>
<!DOCTYPE Xdmf SYSTEM "Xdmf.dtd" []>
<Xdmf Version="2">
   <Domain>
     <Grid Name="Unnamed">
       <Topology  Type="TRIANGLE"
          Dimensions="1"><DataStructure
            DataType="Int"
            Dimensions="1 3"
            Format="XML">
         0 1 2
         </DataStructure>
       </Topology>
       <Geometry Type="XYZ">
         <DataStructure
            DataType="Float"
            Precision="4"
            Dimensions="3 3"
            Format="XML">
          0 0 0
          1 0 0
          0 1 0
         </DataStructure>
       </Geometry>

       <Set SetType="Edge" Name="Test">
           <DataItem NumberType="Int" Dimensions="2" Format="XML">
               0 0
           </DataItem>
           <DataItem NumberType="Int" Dimensions="2" Format="XML">
               0 1
           </DataItem>
           <Attribute Name="Set Values" AttributeType="Scalar" 
Center="Edge">
             <DataItem Format="XML" Dimensions="2">
               1 0
             </DataItem>
           </Attribute>
       </Set>
     </Grid>
   </Domain>
</Xdmf>



>> 3) What about Attributes which are not in a "Set". The XDMF pages
>> say this:-
>> 
>> "A Grid centered Attribute might be something like "Material Type"
>> where the value is constant everywhere in the grid. Edge and Face
>> centered values are defined, but do not map well to many
>> visualization systems."
> 
>> But how do you define Edge and Face centered values for the whole
>> mesh, anyway?
> 
> Not sure I understand the question, much less the answer, but lets
> have a go shall we?
> Set's can have their own attributes and those attributes can be grid
> centered. So if the set has all the edges, then the set's grid
> centered attributes apply to all of the edges in the mesh.

OK, I probably confused things by mixing this in. I'll ask it as a 
separate question.


>> 4) Finally, is there any real need (in the case below) to go via the
>> Faces? Maybe, before the standard gets more widespread, this could
>> be eliminated,
>> and just go direct from Cell->Edge... OK, this is just a
>> suggestion...
> 
> Could do. I can't think of a reason off the top of my head why vtk's
> cell->GetEdge is any less well defined than cell->GetFace()->GetEdge()
> and it is probably faster. Maybe that is why the "bug" is there in
> xdmf1/2.
> 

Yes, and this should also help to fix point (2) above, since Triangles 
don't have Faces, only Edges.

Chris R.



More information about the ParaView mailing list