proteus.Archiver module
Classes for archiving numerical solution data
- class proteus.Archiver.AR_base(dataDir, filename, useTextArchive=False, gatherAtClose=True, useGlobalXMF=True, hotStart=False, readOnly=False, global_sync=True)[source]
Bases:
object
- proteus.Archiver.XdmfArchive[source]
alias of
proteus.Archiver.AR_base
- class proteus.Archiver.XdmfWriter(shareSingleGrid=True, arGridCollection=None, arGrid=None, arTime=None)[source]
Bases:
object
collect functionality for writing data to Xdmf format
Writer is supposed to keep track of grid collection (temporal collection)
as well as current grid under grid collection where data belong, since data are associated with a grid of specific type (e.g., P1 Lagrange, P2 Lagrange, elementQuadrature dictionary, …)
- setGridCollectionAndGridElements(init, ar, arGrid, t, spaceSuffix)[source]
attempt at boiler plate code to grab current arGridCollection and grid for a given type and time level t returns gridName to use in writing mesh
- writeMeshXdmf_elementQuadrature(ar, mesh, spaceDim, x, t=0.0, init=False, meshChanged=False, arGrid=None, tCount=0)[source]
- writeMeshXdmf_elementBoundaryQuadrature(ar, mesh, spaceDim, x, t=0.0, init=False, meshChanged=False, arGrid=None, tCount=0)[source]
- writeMeshXdmf_exteriorElementBoundaryQuadrature(ar, mesh, spaceDim, x, t=0.0, init=False, meshChanged=False, arGrid=None, tCount=0)[source]
- writeMeshXdmf_quadraturePoints(ar, mesh, spaceDim, x, t=0.0, quadratureType='q', init=False, meshChanged=False, arGrid=None, tCount=0)[source]
write out quadrature point mesh for quadrature points that are unique to either elements or elementBoundaries
- quadrature type
q –> element ebq_global –> element boundary ebqe –> exterior element boundary
- writeMeshXdmf_DGP1Lagrange(ar, name, mesh, spaceDim, dofMap, CGDOFMap, t=0.0, init=False, meshChanged=False, arGrid=None, tCount=0)[source]
TODO Not tested yet
- writeMeshXdmf_DGP2Lagrange(ar, name, mesh, spaceDim, dofMap, CGDOFMap, t=0.0, init=False, meshChanged=False, arGrid=None, tCount=0)[source]
- writeMeshXdmf_C0P2Lagrange(ar, name, mesh, spaceDim, dofMap, t=0.0, init=False, meshChanged=False, arGrid=None, tCount=0)[source]
TODO: test new lagrangeNodes convention for 2d,3d
- writeMeshXdmf_C0Q2Lagrange(ar, name, mesh, spaceDim, dofMap, t=0.0, init=False, meshChanged=False, arGrid=None, tCount=0)[source]
TODO: test new lagrangeNodes convention for 2d,3d
- writeMeshXdmf_CrouzeixRaviartP1(ar, mesh, spaceDim, dofMap, t=0.0, init=False, meshChanged=False, arGrid=None, tCount=0)[source]
Write out nonconforming P1 approximation Write out as a (discontinuous) Lagrange P1 function to make visualization easier and dof’s as face centered data on original grid
- writeVectorFunctionXdmf_nodal(ar, uList, components, vectorName, spaceSuffix, tCount=0, init=True)[source]
- writeVectorFunctionXdmf_CrouzeixRaviartP1(ar, uList, components, spaceSuffix, tCount=0, init=True)[source]
- writeMeshXdmf_MonomialDGPK(ar, mesh, spaceDim, interpolationPoints, t=0.0, init=False, meshChanged=False, arGrid=None, tCount=0)[source]
as a first cut, archive DG monomial spaces using same approach as for element quadrature arrays using x = interpolation points (which are just Gaussian quadrature points) as values
- writeFunctionXdmf_MonomialDGPK(ar, interpolationValues, name, tCount=0, init=True, mesh=None)[source]
Different than usual FemFunction Write routines since saves values at interpolation points need to check on way to save dofs as well
- writeVectorFunctionXdmf_MonomialDGPK(ar, interpolationValues, name, tCount=0, init=True)[source]
Different than usual FemFunction Write routines since saves values at interpolation points need to check on way to save dofs as well
- writeMeshXdmf_DGP0(ar, mesh, spaceDim, t=0.0, init=False, meshChanged=False, arGrid=None, tCount=0)[source]
as a first cut, archive piecewise constant space
- writeMeshXdmf_P1Bubble(ar, mesh, spaceDim, dofMap, t=0.0, init=False, meshChanged=False, arGrid=None, tCount=0)[source]
represent P1 bubble space using just vertices for now
- writeVectorFunctionXdmf_P1Bubble(ar, uList, components, vectorName, spaceSuffix, tCount=0, init=True)[source]
- writeMeshXdmf_particles(ar, mesh, spaceDim, x, t=0.0, init=False, meshChanged=False, arGrid=None, tCount=0, spaceSuffix='_particles')[source]
write out arbitrary set of points on a mesh