Skip to content

Commit

Permalink
small changes and README.md update
Browse files Browse the repository at this point in the history
  • Loading branch information
YuXHe15 committed Jun 28, 2023
1 parent 1aa4319 commit 5020181
Show file tree
Hide file tree
Showing 7 changed files with 69 additions and 5 deletions.
Empty file.
Binary file not shown.
Binary file not shown.
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
<?xml version="1.0"?>
<!DOCTYPE Xdmf SYSTEM "Xdmf.dtd" []>
<Xdmf Version="3.0" xmlns:xi="http://www.w3.org/2001/XInclude">
<Domain>
<Grid Name="19c75b5f57504a5887c060d43d23a83f" GridType="Uniform">
<Topology TopologyType="Tetrahedron" NumberOfElements="101821" NodesPerElement="4">
<DataItem Dimensions="101821 4" NumberType="Int" Format="HDF">7abcad0bbd3249eeabc121a353ea88f5.h5:/Mesh/19c75b5f57504a5887c060d43d23a83f/topology</DataItem>
</Topology>
<Geometry GeometryType="XYZ">
<DataItem Dimensions="19846 3" Format="HDF">7abcad0bbd3249eeabc121a353ea88f5.h5:/Mesh/19c75b5f57504a5887c060d43d23a83f/geometry</DataItem>
</Geometry>
</Grid>
<Grid Name="19c75b5f57504a5887c060d43d23a83f_cells" GridType="Uniform">
<xi:include xpointer="xpointer(/Xdmf/Domain/Grid/Geometry)" />
<Topology TopologyType="Tetrahedron" NumberOfElements="101821" NodesPerElement="4">
<DataItem Dimensions="101821 4" NumberType="Int" Format="HDF">7abcad0bbd3249eeabc121a353ea88f5.h5:/MeshTags/19c75b5f57504a5887c060d43d23a83f_cells/topology</DataItem>
</Topology>
<Attribute Name="19c75b5f57504a5887c060d43d23a83f_cells" AttributeType="Scalar" Center="Cell">
<DataItem Dimensions="101821 1" Format="HDF">7abcad0bbd3249eeabc121a353ea88f5.h5:/MeshTags/19c75b5f57504a5887c060d43d23a83f_cells/Values</DataItem>
</Attribute>
</Grid>
<Grid Name="19c75b5f57504a5887c060d43d23a83f_facets" GridType="Uniform">
<xi:include xpointer="xpointer(/Xdmf/Domain/Grid/Geometry)" />
<Topology TopologyType="Triangle" NumberOfElements="0" NodesPerElement="3">
<DataItem Dimensions="0 3" NumberType="Int" Format="HDF">7abcad0bbd3249eeabc121a353ea88f5.h5:/MeshTags/19c75b5f57504a5887c060d43d23a83f_facets/topology</DataItem>
</Topology>
<Attribute Name="19c75b5f57504a5887c060d43d23a83f_facets" AttributeType="Scalar" Center="Cell">
<DataItem Dimensions="0 1" Format="HDF">7abcad0bbd3249eeabc121a353ea88f5.h5:/MeshTags/19c75b5f57504a5887c060d43d23a83f_facets/Values</DataItem>
</Attribute>
</Grid>
</Domain>
</Xdmf>
Binary file not shown.
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
<?xml version="1.0"?>
<!DOCTYPE Xdmf SYSTEM "Xdmf.dtd" []>
<Xdmf Version="3.0" xmlns:xi="http://www.w3.org/2001/XInclude">
<Domain>
<Grid Name="ce09389d3ab047f19fd6eece61f7f58b" GridType="Uniform">
<Topology TopologyType="Tetrahedron" NumberOfElements="36089" NodesPerElement="4">
<DataItem Dimensions="36089 4" NumberType="Int" Format="HDF">f0eacc849bc945788d019e7d2450e074.h5:/Mesh/ce09389d3ab047f19fd6eece61f7f58b/topology</DataItem>
</Topology>
<Geometry GeometryType="XYZ">
<DataItem Dimensions="7824 3" Format="HDF">f0eacc849bc945788d019e7d2450e074.h5:/Mesh/ce09389d3ab047f19fd6eece61f7f58b/geometry</DataItem>
</Geometry>
</Grid>
<Grid Name="ce09389d3ab047f19fd6eece61f7f58b_cells" GridType="Uniform">
<xi:include xpointer="xpointer(/Xdmf/Domain/Grid/Geometry)" />
<Topology TopologyType="Tetrahedron" NumberOfElements="36089" NodesPerElement="4">
<DataItem Dimensions="36089 4" NumberType="Int" Format="HDF">f0eacc849bc945788d019e7d2450e074.h5:/MeshTags/ce09389d3ab047f19fd6eece61f7f58b_cells/topology</DataItem>
</Topology>
<Attribute Name="ce09389d3ab047f19fd6eece61f7f58b_cells" AttributeType="Scalar" Center="Cell">
<DataItem Dimensions="36089 1" Format="HDF">f0eacc849bc945788d019e7d2450e074.h5:/MeshTags/ce09389d3ab047f19fd6eece61f7f58b_cells/Values</DataItem>
</Attribute>
</Grid>
<Grid Name="ce09389d3ab047f19fd6eece61f7f58b_facets" GridType="Uniform">
<xi:include xpointer="xpointer(/Xdmf/Domain/Grid/Geometry)" />
<Topology TopologyType="Triangle" NumberOfElements="0" NodesPerElement="3">
<DataItem Dimensions="0 3" NumberType="Int" Format="HDF">f0eacc849bc945788d019e7d2450e074.h5:/MeshTags/ce09389d3ab047f19fd6eece61f7f58b_facets/topology</DataItem>
</Topology>
<Attribute Name="ce09389d3ab047f19fd6eece61f7f58b_facets" AttributeType="Scalar" Center="Cell">
<DataItem Dimensions="0 1" Format="HDF">f0eacc849bc945788d019e7d2450e074.h5:/MeshTags/ce09389d3ab047f19fd6eece61f7f58b_facets/Values</DataItem>
</Attribute>
</Grid>
</Domain>
</Xdmf>
10 changes: 5 additions & 5 deletions amworkflow/src/infrastructure/database/models/model.py
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ class SliceFile(Base):
# slice_id: Mapped[int] = mapped_column(primary_key=True, autoincrement=True)
slice_hashname: Mapped[str] = mapped_column(String(32), nullable=False, primary_key=True)
step_length: Mapped[float] = mapped_column(nullable=False)
stl_hashname = mapped_column(ForeignKey('GeometryFile.stl_hashname', ondelete="CASCADE"))
stl_hashname_ = mapped_column(ForeignKey('GeometryFile.stl_hashname', ondelete="CASCADE"))
created_date: Mapped[datetime] = mapped_column(nullable=False, default=datetime.now)
batch_num: Mapped[str] = mapped_column(nullable=True)
GCode = relationship("GCode", cascade="all, delete", back_populates="SliceFile")
Expand All @@ -47,7 +47,7 @@ class SliceFile(Base):
class XdmfFile(Base):
__tablename__ = "XdmfFile"
# mesh_id : Mapped[int] = mapped_column(primary_key=True, autoincrement=True)
filename: Mapped[str] = mapped_column(nullable=False)
xdmf_name: Mapped[str] = mapped_column(nullable=False)
xdmf_hashname: Mapped[str] = mapped_column(String(32), nullable=False, primary_key=True)
mesh_size_factor: Mapped[float] = mapped_column(nullable=False)
layer_thickness: Mapped[float] = mapped_column(nullable=True)
Expand All @@ -61,7 +61,7 @@ class XdmfFile(Base):
class H5File(Base):
__tablename__ = "H5File"
# mesh_id : Mapped[int] = mapped_column(primary_key=True, autoincrement=True)
filename: Mapped[str] = mapped_column(nullable=False)
h5_name: Mapped[str] = mapped_column(nullable=False)
h5_hashname: Mapped[str] = mapped_column(String(32), nullable=False, primary_key=True)
created_date: Mapped[datetime] = mapped_column(nullable=False, default=datetime.now)
batch_num: Mapped[str] = mapped_column(nullable=True)
Expand All @@ -74,7 +74,7 @@ class GCode(Base):
gcode_hashname: Mapped[str] = mapped_column(String(32), nullable=False, primary_key=True)
created_date: Mapped[datetime] = mapped_column(nullable=False, default=datetime.now)
batch_num: Mapped[str] = mapped_column(nullable=True)
stl_hashname = mapped_column(ForeignKey('GeometryFile.stl_hashname', ondelete="CASCADE"))
stl_hashname_ = mapped_column(ForeignKey('GeometryFile.stl_hashname', ondelete="CASCADE"))
slice_hashname_ = mapped_column(ForeignKey('SliceFile.slice_hashname', ondelete="CASCADE"))
GeometryFile = relationship("GeometryFile", back_populates="GCode")
SliceFile = relationship("SliceFile", back_populates="GCode")
Expand All @@ -85,6 +85,6 @@ class FEResult(Base):
fe_hashname: Mapped[str] = mapped_column(String(32), nullable=False, primary_key=True)
created_date: Mapped[datetime] = mapped_column(nullable=False, default=datetime.now)
batch_num: Mapped[str] = mapped_column(nullable=True)
stl_hashname = mapped_column(ForeignKey('GeometryFile.stl_hashname', ondelete="CASCADE"))
stl_hashname_ = mapped_column(ForeignKey('GeometryFile.stl_hashname', ondelete="CASCADE"))
GeometryFile = relationship("GeometryFile", back_populates="FEResult")

0 comments on commit 5020181

Please sign in to comment.