[MOAB-dev] GEOM_SENSE_2 tag

Iulian Grindeanu iulian at mcs.anl.gov
Mon Jun 13 14:18:40 CDT 2011


Sorry for breaking it;
I didn't know that DagMC loads it directly. 

How urgent is this ? 

I have no clue, anyway, what would be the best solution.
I can look why make check fails if there is no default specified. WHich one is failing, gtt_tool?
Maybe we can adjust that test.

Iulian 

----- Original Message -----
> (Mostly for Iulian and Jason's attention.)
> 
> There's a problem with the GEOM_SENSE_2 tag that is used by
> GeomTopoTool and DagMC.
> 
> The tag is a sparse tag containing a pair of entity handles. DagMC
> does not specify a default value for the tag. GeomTopoTool sets {0, 0}
> as the default value (see GeomTopoTool::check_face_sense_tag()). Using
> the default value this way introduces an ordering dependence. If DagMC
> gets this tag handle before GeomTopoTool does, then GeomTopoTool's
> call to tag_get_handle() will fail, because the first call to
> tag_get_handle() specifies no default value, and the second call (from
> GeomTopoTool) specifies a default. Since this tag is sparse, there is
> no implicit zero default, as there would be for a dense tag.
> 
> This issue is causing DagMC::load_file() to fail for any .sat file,
> because DagMC initializes its tags before loading a file, and ReadCGM
> uses GeomTopoTool. (Unfortunately, there is no MOAB test for this case
> right now; the current DagMC tests use h5m files.) This issue also
> prevents MOAB from successfully loading any .sat file after first
> loading a mesh file that contains the GEOM_SENSE_2 tag without a
> default value. Such files include any .sat file that was converted to
> a mesh using mbconvert or dagmc_preproc before the default value was
> introduced. (It appears to have been introduced in r4843.)
> 
> The simplest fix would be to remove the default value specifier from
> GeomTopoTool, but doing so causes `make check` to fail. Alternatively,
> we could make all get_tag_handle() calls that involve this tag specify
> the same default value. That would fix DagMC::load_file(), but it
> would not fix the issue where loading old mesh files that do not
> contain a default value for the tag will confuse future uses of the
> tag. We could also load the tag using the MB_TAG_DFTOK flag, in order
> to make tag_get_handle() forgo any checking of default tag values, but
> that seems like a hack.
> 
> What is the best way to fix this?
> ~S


More information about the moab-dev mailing list