[MOAB-dev] Questions about Tags and Topology
Tim Tautges
tautges at mcs.anl.gov
Thu Feb 16 11:24:17 CST 2012
On 02/16/2012 11:13 AM, Christopher Mueller wrote:
>
>
> This has likely not been reflected in the pytaps implementation. Jim?
>
>
> Ultimately, it would be great to be able to do this on a case-by-case basis (via PyTAPS). In the interim, is there any
> way of changing the AdjTable 'statically' (i.e. from a config file or even directly modifying a file) so that the table
> defaults to create all missing entities? At this point, it would be nice to always have all entities as opposed to only
> having the ones explicitly created (and vertices).
>
see itaps/imesh/MBiMesh.hpp, line 59. Alternatively, if you can call into MOAB directly from somewhere, get all the
entities, then ask for all adj edges/faces with create_if_missing flag = true.
- tim
> Thanks,
> Chris
>
>
> - tim
>
>
> In [1]: from itaps import iMesh
> In [2]: mesh=iMesh.Mesh()
> In [3]: mesh.adjTable
> Out[3]:
> array([[7, 4, 4, 1],
> [1, 0, 5, 5],
> [1, 5, 0, 5],
> [1, 5, 5, 7]], dtype=int32)
> In [4]: mesh.adjTable[1,1]
> Out[4]: 0
> In [5]: mesh.adjTable[1,1]=1
> In [6]: mesh.adjTable[1,1]
> Out[6]: 0
> In [7]: import numpy
> In [8]: mesh.adjTable=numpy.array([[7,4,4,1],[1,1,5,5],[1,5,0,5],[1,5,5,7]],dtype='int32')
> ---------------------------------------------------------------------------
> AttributeError Traceback (most recent call last)
> /Users/cmueller/Development/OOI/Dev/datamodel/prototypes/<ipython-input-8-5671b50e588e> in <module>()
> ----> 1 mesh.adjTable=numpy.array([[7,4,4,1],[1,1,5,5],[1,5,0,5],[1,5,5,7]],dtype='int32')
>
> AttributeError: attribute 'adjTable' of 'itaps.iMesh.Mesh' objects is not writable
>
>
>
>
>
>
> - tim
>
> >
> >
> > Thanks in advance,
> > Chris
> >
> > Hope this helps,
> > Iulian
> >
> >
> > Thanks,
> > Chris
>
> --
> ================================================================
> "You will keep in perfect peace him whose mind is
> steadfast, because he trusts in you." Isaiah 26:3
>
> Tim Tautges Argonne National Laboratory
> (tautges at mcs.anl.gov <mailto:tautges at mcs.anl.gov> <mailto:tautges at mcs.anl.gov> <mailto:tautges at mcs.anl.gov>>)
> (telecommuting from UW-Madison)
> phone (gvoice): (608) 354-1459 1500 Engineering Dr.
> fax: (608) 263-4499 Madison, WI 53706
>
>
>
> --
> ================================================================
> "You will keep in perfect peace him whose mind is
> steadfast, because he trusts in you." Isaiah 26:3
>
> Tim Tautges Argonne National Laboratory
> (tautges at mcs.anl.gov <mailto:tautges at mcs.anl.gov>) (telecommuting from UW-Madison)
> phone (gvoice): (608) 354-1459 1500 Engineering Dr.
> fax: (608) 263-4499 Madison, WI 53706
>
>
--
================================================================
"You will keep in perfect peace him whose mind is
steadfast, because he trusts in you." Isaiah 26:3
Tim Tautges Argonne National Laboratory
(tautges at mcs.anl.gov) (telecommuting from UW-Madison)
phone (gvoice): (608) 354-1459 1500 Engineering Dr.
fax: (608) 263-4499 Madison, WI 53706
More information about the moab-dev
mailing list