DeepSDFStruct 1.7.2__tar.gz → 1.7.3__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (186) hide show
  1. deepsdfstruct-1.7.3/.github/workflows/publish.yml +56 -0
  2. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/DeepSDFStruct/flexicubes/flexicubes.py +57 -0
  3. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/DeepSDFStruct.egg-info/PKG-INFO +1 -1
  4. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/DeepSDFStruct.egg-info/SOURCES.txt +1 -0
  5. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/DeepSDFStruct.egg-info/scm_file_list.json +129 -128
  6. deepsdfstruct-1.7.3/DeepSDFStruct.egg-info/scm_version.json +8 -0
  7. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/PKG-INFO +1 -1
  8. deepsdfstruct-1.7.3/tests/test_tet_orientation.py +88 -0
  9. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/uv.lock +850 -117
  10. deepsdfstruct-1.7.2/.github/workflows/publish.yml +0 -56
  11. deepsdfstruct-1.7.2/DeepSDFStruct.egg-info/scm_version.json +0 -8
  12. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/.deepsource.toml +0 -0
  13. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/.github/copilot-instructions.md +0 -0
  14. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/.github/workflows/copilot-setup-steps.yml +0 -0
  15. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/.github/workflows/docs.yml +0 -0
  16. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/.github/workflows/test.yml +0 -0
  17. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/.gitignore +0 -0
  18. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/.pre-commit-config.yaml +0 -0
  19. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/AGENT_INSTRUCTIONS.md +0 -0
  20. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/DeepSDFStruct/SDF.py +0 -0
  21. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/DeepSDFStruct/__init__.py +0 -0
  22. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/DeepSDFStruct/deep_sdf/__init__.py +0 -0
  23. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/DeepSDFStruct/deep_sdf/create_screenshots_from_plyfiles.py +0 -0
  24. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/DeepSDFStruct/deep_sdf/data.py +0 -0
  25. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/DeepSDFStruct/deep_sdf/metrics/__init__.py +0 -0
  26. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/DeepSDFStruct/deep_sdf/metrics/mesh_to_analytical.py +0 -0
  27. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/DeepSDFStruct/deep_sdf/models.py +0 -0
  28. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/DeepSDFStruct/deep_sdf/networks/__init__.py +0 -0
  29. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/DeepSDFStruct/deep_sdf/networks/analytic_round_cross.py +0 -0
  30. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/DeepSDFStruct/deep_sdf/networks/deep_sdf_decoder.py +0 -0
  31. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/DeepSDFStruct/deep_sdf/networks/hierarchical_deep_sdf_decoder.py +0 -0
  32. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/DeepSDFStruct/deep_sdf/networks/hierarchical_positional_sdf_decoder.py +0 -0
  33. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/DeepSDFStruct/deep_sdf/networks/resnet_positional_sdf_decoder.py +0 -0
  34. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/DeepSDFStruct/deep_sdf/nn_utils.py +0 -0
  35. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/DeepSDFStruct/deep_sdf/plotting.py +0 -0
  36. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/DeepSDFStruct/deep_sdf/reconstruction.py +0 -0
  37. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/DeepSDFStruct/deep_sdf/training.py +0 -0
  38. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/DeepSDFStruct/deep_sdf/workspace.py +0 -0
  39. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/DeepSDFStruct/design_of_experiments.py +0 -0
  40. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/DeepSDFStruct/flexicubes/__init__.py +0 -0
  41. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/DeepSDFStruct/flexicubes/tables.py +0 -0
  42. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/DeepSDFStruct/flexisquares/__init__.py +0 -0
  43. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/DeepSDFStruct/flexisquares/flexisquares.py +0 -0
  44. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/DeepSDFStruct/flexisquares/tables.py +0 -0
  45. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/DeepSDFStruct/lattice_structure.py +0 -0
  46. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/DeepSDFStruct/local_shapes.py +0 -0
  47. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/DeepSDFStruct/mesh.py +0 -0
  48. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/DeepSDFStruct/optimization.py +0 -0
  49. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/DeepSDFStruct/parametrization.py +0 -0
  50. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/DeepSDFStruct/pretrained_models.py +0 -0
  51. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/DeepSDFStruct/sampling.py +0 -0
  52. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/DeepSDFStruct/sdf_operations.py +0 -0
  53. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/DeepSDFStruct/sdf_primitives.py +0 -0
  54. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/DeepSDFStruct/splinepy_unitcells/__init__.py +0 -0
  55. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/DeepSDFStruct/splinepy_unitcells/chi_3D.py +0 -0
  56. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/DeepSDFStruct/splinepy_unitcells/cross_lattice.py +0 -0
  57. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/DeepSDFStruct/splinepy_unitcells/double_lattice_extruded.py +0 -0
  58. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/DeepSDFStruct/splinepy_unitcells/snappy_3d.py +0 -0
  59. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/DeepSDFStruct/torch_spline.py +0 -0
  60. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/DeepSDFStruct/trained_models/analytic_round_cross/LatentCodes/latest.pth +0 -0
  61. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/DeepSDFStruct/trained_models/analytic_round_cross/ModelParameters/latest.pth +0 -0
  62. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/DeepSDFStruct/trained_models/analytic_round_cross/OptimizerParameters/latest.pth +0 -0
  63. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/DeepSDFStruct/trained_models/analytic_round_cross/specs.json +0 -0
  64. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/DeepSDFStruct/trained_models/chi_and_cross/LatentCodes/latest.pth +0 -0
  65. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/DeepSDFStruct/trained_models/chi_and_cross/Logs.pth +0 -0
  66. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/DeepSDFStruct/trained_models/chi_and_cross/ModelParameters/latest.pth +0 -0
  67. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/DeepSDFStruct/trained_models/chi_and_cross/OptimizerParameters/latest.pth +0 -0
  68. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/DeepSDFStruct/trained_models/chi_and_cross/specs.json +0 -0
  69. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/DeepSDFStruct/trained_models/primitives/LatentCodes/latest.pth +0 -0
  70. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/DeepSDFStruct/trained_models/primitives/ModelParameters/latest.pth +0 -0
  71. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/DeepSDFStruct/trained_models/primitives/OptimizerParameters/latest.pth +0 -0
  72. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/DeepSDFStruct/trained_models/primitives/specs.json +0 -0
  73. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/DeepSDFStruct/trained_models/primitives_2d/LatentCodes/latest.pth +0 -0
  74. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/DeepSDFStruct/trained_models/primitives_2d/ModelParameters/latest.pth +0 -0
  75. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/DeepSDFStruct/trained_models/primitives_2d/OptimizerParameters/latest.pth +0 -0
  76. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/DeepSDFStruct/trained_models/primitives_2d/specs.json +0 -0
  77. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/DeepSDFStruct/trained_models/round_cross/LatentCodes/latest.pth +0 -0
  78. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/DeepSDFStruct/trained_models/round_cross/Logs.pth +0 -0
  79. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/DeepSDFStruct/trained_models/round_cross/ModelParameters/latest.pth +0 -0
  80. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/DeepSDFStruct/trained_models/round_cross/OptimizerParameters/latest.pth +0 -0
  81. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/DeepSDFStruct/trained_models/round_cross/specs.json +0 -0
  82. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/DeepSDFStruct/trained_models/test_experiment/LatentCodes/latent_code_data_map.json +0 -0
  83. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/DeepSDFStruct/trained_models/test_experiment/specs.json +0 -0
  84. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/DeepSDFStruct/trained_models/test_experiment/training_summary.json +0 -0
  85. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/DeepSDFStruct/trained_models/test_experiment_hierarchical/LatentCodes/latent_code_data_map.json +0 -0
  86. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/DeepSDFStruct/trained_models/test_experiment_hierarchical/specs.json +0 -0
  87. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/DeepSDFStruct/trained_models/test_experiment_hierarchical/training_summary.json +0 -0
  88. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/DeepSDFStruct/trained_models/test_experiment_homogenization/LatentCodes/latent_code_data_map.json +0 -0
  89. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/DeepSDFStruct/trained_models/test_experiment_homogenization/LatentCodes/latest.pth +0 -0
  90. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/DeepSDFStruct/trained_models/test_experiment_homogenization/Logs.png +0 -0
  91. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/DeepSDFStruct/trained_models/test_experiment_homogenization/ModelParameters/latest.pth +0 -0
  92. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/DeepSDFStruct/trained_models/test_experiment_homogenization/OptimizerParameters/latest.pth +0 -0
  93. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/DeepSDFStruct/trained_models/test_experiment_homogenization/specs.json +0 -0
  94. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/DeepSDFStruct/trained_models/test_experiment_homogenization/training_summary.json +0 -0
  95. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/DeepSDFStruct/utils.py +0 -0
  96. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/DeepSDFStruct/visualization/latent_viewer.py +0 -0
  97. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/DeepSDFStruct/visualization/latent_viewer_cli.py +0 -0
  98. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/DeepSDFStruct.egg-info/dependency_links.txt +0 -0
  99. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/DeepSDFStruct.egg-info/requires.txt +0 -0
  100. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/DeepSDFStruct.egg-info/top_level.txt +0 -0
  101. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/LICENSE +0 -0
  102. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/MANIFEST.in +0 -0
  103. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/NOTICE +0 -0
  104. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/README.md +0 -0
  105. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/SDF_FEATURE_TRACKING.md +0 -0
  106. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/benchmarks/generate_sdf_showcase.py +0 -0
  107. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/benchmarks/sdf_from_mesh_benchmark.py +0 -0
  108. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/benchmarks/sdf_from_mesh_comparison.md +0 -0
  109. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/benchmarks/sdf_showcase/operations/boolean/difference_sphere_box.png +0 -0
  110. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/benchmarks/sdf_showcase/operations/boolean/union_sphere_box.png +0 -0
  111. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/benchmarks/sdf_showcase/operations/transformations/circular_array_sphere.png +0 -0
  112. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/benchmarks/sdf_showcase/operations/transformations/dilate_sphere.png +0 -0
  113. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/benchmarks/sdf_showcase/operations/transformations/mirror_sphere.png +0 -0
  114. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/benchmarks/sdf_showcase/operations/transformations/repeat_sphere.png +0 -0
  115. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/benchmarks/sdf_showcase/operations/transformations/revolve_circle.png +0 -0
  116. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/benchmarks/sdf_showcase/operations/transformations/shell_sphere.png +0 -0
  117. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/benchmarks/sdf_showcase/operations/transformations/twist_torus.png +0 -0
  118. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/benchmarks/sdf_showcase/primitives/2D/circle.png +0 -0
  119. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/benchmarks/sdf_showcase/primitives/2D/equilateral_triangle.png +0 -0
  120. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/benchmarks/sdf_showcase/primitives/2D/hexagon.png +0 -0
  121. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/benchmarks/sdf_showcase/primitives/2D/polygon_pentagon.png +0 -0
  122. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/benchmarks/sdf_showcase/primitives/2D/rectangle.png +0 -0
  123. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/benchmarks/sdf_showcase/primitives/2D/rounded_rectangle.png +0 -0
  124. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/benchmarks/sdf_showcase/primitives/3D/box.png +0 -0
  125. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/benchmarks/sdf_showcase/primitives/3D/capped_cone.png +0 -0
  126. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/benchmarks/sdf_showcase/primitives/3D/capped_cylinder.png +0 -0
  127. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/benchmarks/sdf_showcase/primitives/3D/capsule.png +0 -0
  128. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/benchmarks/sdf_showcase/primitives/3D/cone.png +0 -0
  129. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/benchmarks/sdf_showcase/primitives/3D/corner_spheres.png +0 -0
  130. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/benchmarks/sdf_showcase/primitives/3D/cross_ms.png +0 -0
  131. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/benchmarks/sdf_showcase/primitives/3D/cylinder.png +0 -0
  132. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/benchmarks/sdf_showcase/primitives/3D/dodecahedron.png +0 -0
  133. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/benchmarks/sdf_showcase/primitives/3D/ellipsoid.png +0 -0
  134. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/benchmarks/sdf_showcase/primitives/3D/icosahedron.png +0 -0
  135. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/benchmarks/sdf_showcase/primitives/3D/octahedron.png +0 -0
  136. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/benchmarks/sdf_showcase/primitives/3D/pyramid.png +0 -0
  137. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/benchmarks/sdf_showcase/primitives/3D/rounded_box.png +0 -0
  138. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/benchmarks/sdf_showcase/primitives/3D/rounded_cone.png +0 -0
  139. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/benchmarks/sdf_showcase/primitives/3D/rounded_cylinder.png +0 -0
  140. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/benchmarks/sdf_showcase/primitives/3D/sphere.png +0 -0
  141. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/benchmarks/sdf_showcase/primitives/3D/tetrahedron.png +0 -0
  142. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/benchmarks/sdf_showcase/primitives/3D/torus.png +0 -0
  143. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/benchmarks/sdf_showcase/primitives/3D/wireframe_box.png +0 -0
  144. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/docs/Makefile +0 -0
  145. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/docs/api_reference.rst +0 -0
  146. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/docs/conf.py +0 -0
  147. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/docs/index.rst +0 -0
  148. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/docs/make.bat +0 -0
  149. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/docs/qr_code_github.png +0 -0
  150. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/docs/qr_code_paper.png +0 -0
  151. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/docs/readme_images/example_output_01.png +0 -0
  152. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/docs/readme_images/example_output_02.png +0 -0
  153. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/docs/readme_images/example_output_03.png +0 -0
  154. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/docs/readme_images/example_output_04.png +0 -0
  155. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/example.ipynb +0 -0
  156. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/pyproject.toml +0 -0
  157. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/setup.cfg +0 -0
  158. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/tests/data/chairs/1005.obj +0 -0
  159. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/tests/data/chairs/1024.obj +0 -0
  160. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/tests/data/chairs/README.md +0 -0
  161. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/tests/data/circular_balls_test_case.stl +0 -0
  162. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/tests/data/cone.stl +0 -0
  163. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/tests/data/example_disconnectd_mesh.inp +0 -0
  164. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/tests/data/example_line_mesh.vtk +0 -0
  165. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/tests/data/stanford_bunny.stl +0 -0
  166. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/tests/data/sweep_test_case.stl +0 -0
  167. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/tests/test_DOE.py +0 -0
  168. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/tests/test_elongate_sdf.py +0 -0
  169. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/tests/test_flexisquares.py +0 -0
  170. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/tests/test_generate_dataset.py +0 -0
  171. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/tests/test_lattice_evaluation.py +0 -0
  172. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/tests/test_mesh_export.py +0 -0
  173. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/tests/test_mesh_functions.py +0 -0
  174. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/tests/test_networks.py +0 -0
  175. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/tests/test_pretrained_models.py +0 -0
  176. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/tests/test_reconstruction.py +0 -0
  177. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/tests/test_sdf_from_mesh.py +0 -0
  178. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/tests/test_sdf_functions.py +0 -0
  179. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/tests/test_sdf_primitives.py +0 -0
  180. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/tests/test_sdf_trimesh_comparison.py +0 -0
  181. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/tests/test_splinepy_unitcells.py +0 -0
  182. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/tests/test_structural_optimization.py +0 -0
  183. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/tests/test_torch_spline.py +0 -0
  184. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/tests/test_train_model.py +0 -0
  185. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/tests/test_training_data_ids.py +0 -0
  186. {deepsdfstruct-1.7.2 → deepsdfstruct-1.7.3}/tests/tmp_outputs/temp_file.txt +0 -0
@@ -0,0 +1,56 @@
1
+ name: Publish to PyPI
2
+
3
+ on:
4
+ push:
5
+ tags:
6
+ - "v*"
7
+
8
+ jobs:
9
+ test:
10
+ uses: ./.github/workflows/test.yml
11
+ secrets: inherit
12
+
13
+ publish:
14
+ needs: test
15
+ if: github.ref_type == 'tag'
16
+
17
+ runs-on: ubuntu-latest
18
+ environment:
19
+ name: pypi
20
+
21
+ permissions:
22
+ contents: read
23
+ id-token: write
24
+
25
+ steps:
26
+ - name: Checkout repository
27
+ uses: actions/checkout@v4
28
+ with:
29
+ fetch-depth: 0
30
+
31
+ - name: Set up Python
32
+ uses: actions/setup-python@v5
33
+ with:
34
+ python-version: "3.13"
35
+
36
+ - name: Install uv
37
+ uses: astral-sh/setup-uv@v6
38
+ with:
39
+ enable-cache: true
40
+
41
+ - name: Verify stable tag format
42
+ shell: bash
43
+ run: |
44
+ if [[ ! "$GITHUB_REF_NAME" =~ ^v[0-9]+\.[0-9]+\.[0-9]+$ ]]; then
45
+ echo "::error::Tag '$GITHUB_REF_NAME' must be in the format vX.Y.Z"
46
+ exit 1
47
+ fi
48
+
49
+ - name: Sync dependencies
50
+ run: uv sync --locked
51
+
52
+ - name: Build package
53
+ run: uv build
54
+
55
+ - name: Publish to PyPI
56
+ run: uv publish
@@ -28,10 +28,14 @@ Licensed under the Apache License, Version 2.0.
28
28
  # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
29
29
  # See the License for the specific language governing permissions and
30
30
  # limitations under the License.
31
+ import logging
32
+
31
33
  import torch
32
34
  import warnings
33
35
  from DeepSDFStruct.flexicubes.tables import *
34
36
 
37
+ logger = logging.getLogger(__name__)
38
+
35
39
  __all__ = ["FlexiCubes"]
36
40
 
37
41
 
@@ -1002,4 +1006,57 @@ class FlexiCubes:
1002
1006
 
1003
1007
  tets = torch.cat([tets_surface, tets_inside])
1004
1008
  vertices = torch.cat([vertices, inside_verts, inside_cubes_center])
1009
+ # The surface (pyramid) and interior sub-procedures above emit tets
1010
+ # with inconsistent winding, so a large fraction come out inverted
1011
+ # (negative signed volume). FEA solvers require a positive signed
1012
+ # volume / Jacobian, so normalize every tet to positive orientation
1013
+ # and drop degenerate (zero-volume) elements.
1014
+ tets = self._orient_tets(vertices, tets)
1005
1015
  return vertices, tets
1016
+
1017
+ @staticmethod
1018
+ def _orient_tets(vertices, tets, threshold_factor=1e-5):
1019
+ """Return ``tets`` with a consistent, strictly positive signed volume.
1020
+
1021
+ For a tetrahedron with vertices ``(v0, v1, v2, v3)`` the signed volume
1022
+ is proportional to ``det([v1 - v0, v2 - v0, v3 - v0])``. Elements with
1023
+ a negative determinant are inverted; swapping the last two vertices
1024
+ flips the orientation so the signed volume becomes positive without
1025
+ changing the element's geometry. The vertex indices are merely
1026
+ reordered, so gradients to ``vertices`` are unaffected.
1027
+
1028
+ Degenerate elements (four coplanar vertices, zero volume) cannot be
1029
+ repaired by reordering and are removed instead. Vertices are left
1030
+ untouched, so indices of the remaining tets stay valid.
1031
+
1032
+ Args:
1033
+ vertices (torch.Tensor): All vertices as coordinates
1034
+ tets (torch.Tensor): Indices of vertices that form tets
1035
+ threshold_factor (float, optional): Maximum element volume
1036
+ up until the elements get removed. Gets multiplied by
1037
+ the Hadamard bound |e1||e2||e3|.
1038
+ """
1039
+ if tets.shape[0] == 0:
1040
+ return tets
1041
+ # Only integer index masks are derived here, so skip autograd
1042
+ # recording even when ``vertices`` requires gradients.
1043
+ with torch.no_grad():
1044
+ v0 = vertices[tets[:, 0]]
1045
+ v1 = vertices[tets[:, 1]]
1046
+ v2 = vertices[tets[:, 2]]
1047
+ v3 = vertices[tets[:, 3]]
1048
+ e1, e2, e3 = v1 - v0, v2 - v0, v3 - v0
1049
+ signed_vol = torch.einsum("ij,ij->i", e1, torch.linalg.cross(e2, e3, dim=1))
1050
+ inverted = signed_vol < 0
1051
+ # Coplanar tets only evaluate to exactly zero up to floating-point
1052
+ # rounding (which depends on the association order of the triple
1053
+ # product), so compare against a tolerance relative to the Hadamard
1054
+ # bound |e1||e2||e3| of the determinant instead of zero itself.
1055
+ scale = e1.norm(dim=1) * e2.norm(dim=1) * e3.norm(dim=1)
1056
+ degenerate = signed_vol.abs() <= threshold_factor * scale
1057
+ tets = tets.clone()
1058
+ tets[inverted] = tets[inverted][:, [0, 1, 3, 2]]
1059
+ if degenerate.any():
1060
+ logger.info(f"removed {int(degenerate.sum())} elements with 0 volume")
1061
+ tets = tets[~degenerate]
1062
+ return tets
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: DeepSDFStruct
3
- Version: 1.7.2
3
+ Version: 1.7.3
4
4
  Summary: Deep Implicit Lattice Geometry
5
5
  Author-email: Michael Kofler <michael.kofler@tuwien.ac.at>
6
6
  Requires-Python: >=3.10
@@ -166,6 +166,7 @@ tests/test_sdf_primitives.py
166
166
  tests/test_sdf_trimesh_comparison.py
167
167
  tests/test_splinepy_unitcells.py
168
168
  tests/test_structural_optimization.py
169
+ tests/test_tet_orientation.py
169
170
  tests/test_torch_spline.py
170
171
  tests/test_train_model.py
171
172
  tests/test_training_data_ids.py
@@ -1,178 +1,179 @@
1
1
  {
2
2
  "files": [
3
- "LICENSE",
4
- "uv.lock",
5
- ".pre-commit-config.yaml",
6
- "pyproject.toml",
7
- "MANIFEST.in",
8
- "NOTICE",
9
- ".deepsource.toml",
10
- "README.md",
11
- "example.ipynb",
12
3
  ".gitignore",
4
+ "README.md",
13
5
  "AGENT_INSTRUCTIONS.md",
6
+ "example.ipynb",
14
7
  "SDF_FEATURE_TRACKING.md",
15
- "tests/test_mesh_functions.py",
16
- "tests/test_torch_spline.py",
17
- "tests/test_DOE.py",
18
- "tests/test_mesh_export.py",
19
- "tests/test_sdf_trimesh_comparison.py",
20
- "tests/test_flexisquares.py",
21
- "tests/test_train_model.py",
22
- "tests/test_pretrained_models.py",
23
- "tests/test_sdf_primitives.py",
24
- "tests/test_structural_optimization.py",
25
- "tests/test_sdf_functions.py",
26
- "tests/test_sdf_from_mesh.py",
27
- "tests/test_networks.py",
28
- "tests/test_training_data_ids.py",
29
- "tests/test_elongate_sdf.py",
30
- "tests/test_lattice_evaluation.py",
31
- "tests/test_generate_dataset.py",
32
- "tests/test_reconstruction.py",
33
- "tests/test_splinepy_unitcells.py",
34
- "tests/tmp_outputs/temp_file.txt",
35
- "tests/data/stanford_bunny.stl",
36
- "tests/data/example_disconnectd_mesh.inp",
37
- "tests/data/sweep_test_case.stl",
38
- "tests/data/cone.stl",
39
- "tests/data/circular_balls_test_case.stl",
40
- "tests/data/example_line_mesh.vtk",
41
- "tests/data/chairs/1024.obj",
42
- "tests/data/chairs/README.md",
43
- "tests/data/chairs/1005.obj",
44
- "docs/index.rst",
45
- "docs/api_reference.rst",
46
- "docs/qr_code_paper.png",
47
- "docs/Makefile",
48
- "docs/qr_code_github.png",
49
- "docs/conf.py",
50
- "docs/make.bat",
51
- "docs/readme_images/example_output_01.png",
52
- "docs/readme_images/example_output_02.png",
53
- "docs/readme_images/example_output_03.png",
54
- "docs/readme_images/example_output_04.png",
8
+ ".deepsource.toml",
9
+ "NOTICE",
10
+ "pyproject.toml",
11
+ "MANIFEST.in",
12
+ ".pre-commit-config.yaml",
13
+ "uv.lock",
14
+ "LICENSE",
55
15
  "benchmarks/generate_sdf_showcase.py",
56
16
  "benchmarks/sdf_from_mesh_benchmark.py",
57
17
  "benchmarks/sdf_from_mesh_comparison.md",
58
- "benchmarks/sdf_showcase/operations/transformations/shell_sphere.png",
59
- "benchmarks/sdf_showcase/operations/transformations/mirror_sphere.png",
60
- "benchmarks/sdf_showcase/operations/transformations/circular_array_sphere.png",
61
- "benchmarks/sdf_showcase/operations/transformations/twist_torus.png",
62
- "benchmarks/sdf_showcase/operations/transformations/dilate_sphere.png",
63
- "benchmarks/sdf_showcase/operations/transformations/repeat_sphere.png",
64
- "benchmarks/sdf_showcase/operations/transformations/revolve_circle.png",
65
- "benchmarks/sdf_showcase/operations/boolean/union_sphere_box.png",
66
- "benchmarks/sdf_showcase/operations/boolean/difference_sphere_box.png",
67
- "benchmarks/sdf_showcase/primitives/3D/icosahedron.png",
68
- "benchmarks/sdf_showcase/primitives/3D/ellipsoid.png",
69
- "benchmarks/sdf_showcase/primitives/3D/rounded_box.png",
18
+ "benchmarks/sdf_showcase/primitives/2D/rectangle.png",
19
+ "benchmarks/sdf_showcase/primitives/2D/rounded_rectangle.png",
20
+ "benchmarks/sdf_showcase/primitives/2D/equilateral_triangle.png",
21
+ "benchmarks/sdf_showcase/primitives/2D/hexagon.png",
22
+ "benchmarks/sdf_showcase/primitives/2D/circle.png",
23
+ "benchmarks/sdf_showcase/primitives/2D/polygon_pentagon.png",
24
+ "benchmarks/sdf_showcase/primitives/3D/capsule.png",
25
+ "benchmarks/sdf_showcase/primitives/3D/cylinder.png",
26
+ "benchmarks/sdf_showcase/primitives/3D/wireframe_box.png",
70
27
  "benchmarks/sdf_showcase/primitives/3D/sphere.png",
28
+ "benchmarks/sdf_showcase/primitives/3D/cross_ms.png",
29
+ "benchmarks/sdf_showcase/primitives/3D/cone.png",
71
30
  "benchmarks/sdf_showcase/primitives/3D/corner_spheres.png",
72
- "benchmarks/sdf_showcase/primitives/3D/torus.png",
73
31
  "benchmarks/sdf_showcase/primitives/3D/dodecahedron.png",
74
- "benchmarks/sdf_showcase/primitives/3D/rounded_cone.png",
75
- "benchmarks/sdf_showcase/primitives/3D/cone.png",
76
- "benchmarks/sdf_showcase/primitives/3D/capsule.png",
32
+ "benchmarks/sdf_showcase/primitives/3D/rounded_box.png",
77
33
  "benchmarks/sdf_showcase/primitives/3D/capped_cylinder.png",
78
- "benchmarks/sdf_showcase/primitives/3D/cross_ms.png",
79
- "benchmarks/sdf_showcase/primitives/3D/wireframe_box.png",
80
- "benchmarks/sdf_showcase/primitives/3D/tetrahedron.png",
81
- "benchmarks/sdf_showcase/primitives/3D/cylinder.png",
82
34
  "benchmarks/sdf_showcase/primitives/3D/octahedron.png",
83
- "benchmarks/sdf_showcase/primitives/3D/pyramid.png",
84
35
  "benchmarks/sdf_showcase/primitives/3D/rounded_cylinder.png",
36
+ "benchmarks/sdf_showcase/primitives/3D/icosahedron.png",
85
37
  "benchmarks/sdf_showcase/primitives/3D/box.png",
38
+ "benchmarks/sdf_showcase/primitives/3D/rounded_cone.png",
39
+ "benchmarks/sdf_showcase/primitives/3D/ellipsoid.png",
86
40
  "benchmarks/sdf_showcase/primitives/3D/capped_cone.png",
87
- "benchmarks/sdf_showcase/primitives/2D/rounded_rectangle.png",
88
- "benchmarks/sdf_showcase/primitives/2D/hexagon.png",
89
- "benchmarks/sdf_showcase/primitives/2D/rectangle.png",
90
- "benchmarks/sdf_showcase/primitives/2D/circle.png",
91
- "benchmarks/sdf_showcase/primitives/2D/polygon_pentagon.png",
92
- "benchmarks/sdf_showcase/primitives/2D/equilateral_triangle.png",
93
- "DeepSDFStruct/pretrained_models.py",
94
- "DeepSDFStruct/sdf_primitives.py",
95
- "DeepSDFStruct/optimization.py",
96
- "DeepSDFStruct/lattice_structure.py",
97
- "DeepSDFStruct/__init__.py",
98
- "DeepSDFStruct/mesh.py",
99
- "DeepSDFStruct/sdf_operations.py",
100
- "DeepSDFStruct/utils.py",
41
+ "benchmarks/sdf_showcase/primitives/3D/torus.png",
42
+ "benchmarks/sdf_showcase/primitives/3D/pyramid.png",
43
+ "benchmarks/sdf_showcase/primitives/3D/tetrahedron.png",
44
+ "benchmarks/sdf_showcase/operations/transformations/repeat_sphere.png",
45
+ "benchmarks/sdf_showcase/operations/transformations/mirror_sphere.png",
46
+ "benchmarks/sdf_showcase/operations/transformations/circular_array_sphere.png",
47
+ "benchmarks/sdf_showcase/operations/transformations/dilate_sphere.png",
48
+ "benchmarks/sdf_showcase/operations/transformations/twist_torus.png",
49
+ "benchmarks/sdf_showcase/operations/transformations/revolve_circle.png",
50
+ "benchmarks/sdf_showcase/operations/transformations/shell_sphere.png",
51
+ "benchmarks/sdf_showcase/operations/boolean/union_sphere_box.png",
52
+ "benchmarks/sdf_showcase/operations/boolean/difference_sphere_box.png",
53
+ ".github/copilot-instructions.md",
54
+ ".github/workflows/copilot-setup-steps.yml",
55
+ ".github/workflows/publish.yml",
56
+ ".github/workflows/test.yml",
57
+ ".github/workflows/docs.yml",
101
58
  "DeepSDFStruct/SDF.py",
102
59
  "DeepSDFStruct/design_of_experiments.py",
60
+ "DeepSDFStruct/lattice_structure.py",
61
+ "DeepSDFStruct/optimization.py",
103
62
  "DeepSDFStruct/sampling.py",
104
- "DeepSDFStruct/local_shapes.py",
63
+ "DeepSDFStruct/pretrained_models.py",
64
+ "DeepSDFStruct/utils.py",
105
65
  "DeepSDFStruct/parametrization.py",
66
+ "DeepSDFStruct/local_shapes.py",
67
+ "DeepSDFStruct/mesh.py",
106
68
  "DeepSDFStruct/torch_spline.py",
69
+ "DeepSDFStruct/sdf_primitives.py",
70
+ "DeepSDFStruct/sdf_operations.py",
71
+ "DeepSDFStruct/__init__.py",
107
72
  "DeepSDFStruct/visualization/latent_viewer_cli.py",
108
73
  "DeepSDFStruct/visualization/latent_viewer.py",
109
- "DeepSDFStruct/flexicubes/__init__.py",
110
74
  "DeepSDFStruct/flexicubes/tables.py",
111
75
  "DeepSDFStruct/flexicubes/flexicubes.py",
112
- "DeepSDFStruct/trained_models/primitives_2d/specs.json",
113
- "DeepSDFStruct/trained_models/primitives_2d/OptimizerParameters/latest.pth",
114
- "DeepSDFStruct/trained_models/primitives_2d/LatentCodes/latest.pth",
115
- "DeepSDFStruct/trained_models/primitives_2d/ModelParameters/latest.pth",
76
+ "DeepSDFStruct/flexicubes/__init__.py",
77
+ "DeepSDFStruct/trained_models/round_cross/specs.json",
78
+ "DeepSDFStruct/trained_models/round_cross/Logs.pth",
79
+ "DeepSDFStruct/trained_models/round_cross/ModelParameters/latest.pth",
80
+ "DeepSDFStruct/trained_models/round_cross/LatentCodes/latest.pth",
81
+ "DeepSDFStruct/trained_models/round_cross/OptimizerParameters/latest.pth",
116
82
  "DeepSDFStruct/trained_models/test_experiment_hierarchical/specs.json",
117
83
  "DeepSDFStruct/trained_models/test_experiment_hierarchical/training_summary.json",
118
84
  "DeepSDFStruct/trained_models/test_experiment_hierarchical/LatentCodes/latent_code_data_map.json",
119
- "DeepSDFStruct/trained_models/test_experiment_homogenization/Logs.png",
85
+ "DeepSDFStruct/trained_models/primitives/specs.json",
86
+ "DeepSDFStruct/trained_models/primitives/ModelParameters/latest.pth",
87
+ "DeepSDFStruct/trained_models/primitives/LatentCodes/latest.pth",
88
+ "DeepSDFStruct/trained_models/primitives/OptimizerParameters/latest.pth",
89
+ "DeepSDFStruct/trained_models/analytic_round_cross/specs.json",
90
+ "DeepSDFStruct/trained_models/analytic_round_cross/ModelParameters/latest.pth",
91
+ "DeepSDFStruct/trained_models/analytic_round_cross/LatentCodes/latest.pth",
92
+ "DeepSDFStruct/trained_models/analytic_round_cross/OptimizerParameters/latest.pth",
120
93
  "DeepSDFStruct/trained_models/test_experiment_homogenization/specs.json",
121
94
  "DeepSDFStruct/trained_models/test_experiment_homogenization/training_summary.json",
122
- "DeepSDFStruct/trained_models/test_experiment_homogenization/OptimizerParameters/latest.pth",
123
- "DeepSDFStruct/trained_models/test_experiment_homogenization/LatentCodes/latent_code_data_map.json",
124
- "DeepSDFStruct/trained_models/test_experiment_homogenization/LatentCodes/latest.pth",
95
+ "DeepSDFStruct/trained_models/test_experiment_homogenization/Logs.png",
125
96
  "DeepSDFStruct/trained_models/test_experiment_homogenization/ModelParameters/latest.pth",
126
- "DeepSDFStruct/trained_models/primitives/specs.json",
127
- "DeepSDFStruct/trained_models/primitives/OptimizerParameters/latest.pth",
128
- "DeepSDFStruct/trained_models/primitives/LatentCodes/latest.pth",
129
- "DeepSDFStruct/trained_models/primitives/ModelParameters/latest.pth",
97
+ "DeepSDFStruct/trained_models/test_experiment_homogenization/LatentCodes/latest.pth",
98
+ "DeepSDFStruct/trained_models/test_experiment_homogenization/LatentCodes/latent_code_data_map.json",
99
+ "DeepSDFStruct/trained_models/test_experiment_homogenization/OptimizerParameters/latest.pth",
100
+ "DeepSDFStruct/trained_models/primitives_2d/specs.json",
101
+ "DeepSDFStruct/trained_models/primitives_2d/ModelParameters/latest.pth",
102
+ "DeepSDFStruct/trained_models/primitives_2d/LatentCodes/latest.pth",
103
+ "DeepSDFStruct/trained_models/primitives_2d/OptimizerParameters/latest.pth",
130
104
  "DeepSDFStruct/trained_models/test_experiment/specs.json",
131
105
  "DeepSDFStruct/trained_models/test_experiment/training_summary.json",
132
106
  "DeepSDFStruct/trained_models/test_experiment/LatentCodes/latent_code_data_map.json",
133
107
  "DeepSDFStruct/trained_models/chi_and_cross/specs.json",
134
108
  "DeepSDFStruct/trained_models/chi_and_cross/Logs.pth",
135
- "DeepSDFStruct/trained_models/chi_and_cross/OptimizerParameters/latest.pth",
136
- "DeepSDFStruct/trained_models/chi_and_cross/LatentCodes/latest.pth",
137
109
  "DeepSDFStruct/trained_models/chi_and_cross/ModelParameters/latest.pth",
138
- "DeepSDFStruct/trained_models/analytic_round_cross/specs.json",
139
- "DeepSDFStruct/trained_models/analytic_round_cross/OptimizerParameters/latest.pth",
140
- "DeepSDFStruct/trained_models/analytic_round_cross/LatentCodes/latest.pth",
141
- "DeepSDFStruct/trained_models/analytic_round_cross/ModelParameters/latest.pth",
142
- "DeepSDFStruct/trained_models/round_cross/specs.json",
143
- "DeepSDFStruct/trained_models/round_cross/Logs.pth",
144
- "DeepSDFStruct/trained_models/round_cross/OptimizerParameters/latest.pth",
145
- "DeepSDFStruct/trained_models/round_cross/LatentCodes/latest.pth",
146
- "DeepSDFStruct/trained_models/round_cross/ModelParameters/latest.pth",
147
- "DeepSDFStruct/deep_sdf/reconstruction.py",
148
- "DeepSDFStruct/deep_sdf/models.py",
110
+ "DeepSDFStruct/trained_models/chi_and_cross/LatentCodes/latest.pth",
111
+ "DeepSDFStruct/trained_models/chi_and_cross/OptimizerParameters/latest.pth",
112
+ "DeepSDFStruct/splinepy_unitcells/cross_lattice.py",
113
+ "DeepSDFStruct/splinepy_unitcells/chi_3D.py",
114
+ "DeepSDFStruct/splinepy_unitcells/double_lattice_extruded.py",
115
+ "DeepSDFStruct/splinepy_unitcells/snappy_3d.py",
116
+ "DeepSDFStruct/splinepy_unitcells/__init__.py",
149
117
  "DeepSDFStruct/deep_sdf/plotting.py",
150
- "DeepSDFStruct/deep_sdf/__init__.py",
151
- "DeepSDFStruct/deep_sdf/workspace.py",
152
118
  "DeepSDFStruct/deep_sdf/create_screenshots_from_plyfiles.py",
119
+ "DeepSDFStruct/deep_sdf/data.py",
153
120
  "DeepSDFStruct/deep_sdf/nn_utils.py",
121
+ "DeepSDFStruct/deep_sdf/workspace.py",
122
+ "DeepSDFStruct/deep_sdf/reconstruction.py",
154
123
  "DeepSDFStruct/deep_sdf/training.py",
155
- "DeepSDFStruct/deep_sdf/data.py",
124
+ "DeepSDFStruct/deep_sdf/models.py",
125
+ "DeepSDFStruct/deep_sdf/__init__.py",
156
126
  "DeepSDFStruct/deep_sdf/metrics/mesh_to_analytical.py",
157
127
  "DeepSDFStruct/deep_sdf/metrics/__init__.py",
158
- "DeepSDFStruct/deep_sdf/networks/__init__.py",
128
+ "DeepSDFStruct/deep_sdf/networks/deep_sdf_decoder.py",
159
129
  "DeepSDFStruct/deep_sdf/networks/analytic_round_cross.py",
160
- "DeepSDFStruct/deep_sdf/networks/resnet_positional_sdf_decoder.py",
161
130
  "DeepSDFStruct/deep_sdf/networks/hierarchical_positional_sdf_decoder.py",
131
+ "DeepSDFStruct/deep_sdf/networks/resnet_positional_sdf_decoder.py",
162
132
  "DeepSDFStruct/deep_sdf/networks/hierarchical_deep_sdf_decoder.py",
163
- "DeepSDFStruct/deep_sdf/networks/deep_sdf_decoder.py",
164
- "DeepSDFStruct/flexisquares/__init__.py",
133
+ "DeepSDFStruct/deep_sdf/networks/__init__.py",
165
134
  "DeepSDFStruct/flexisquares/flexisquares.py",
166
135
  "DeepSDFStruct/flexisquares/tables.py",
167
- "DeepSDFStruct/splinepy_unitcells/cross_lattice.py",
168
- "DeepSDFStruct/splinepy_unitcells/__init__.py",
169
- "DeepSDFStruct/splinepy_unitcells/snappy_3d.py",
170
- "DeepSDFStruct/splinepy_unitcells/chi_3D.py",
171
- "DeepSDFStruct/splinepy_unitcells/double_lattice_extruded.py",
172
- ".github/copilot-instructions.md",
173
- ".github/workflows/publish.yml",
174
- ".github/workflows/test.yml",
175
- ".github/workflows/docs.yml",
176
- ".github/workflows/copilot-setup-steps.yml"
136
+ "DeepSDFStruct/flexisquares/__init__.py",
137
+ "tests/test_sdf_functions.py",
138
+ "tests/test_train_model.py",
139
+ "tests/test_flexisquares.py",
140
+ "tests/test_DOE.py",
141
+ "tests/test_sdf_trimesh_comparison.py",
142
+ "tests/test_mesh_functions.py",
143
+ "tests/test_lattice_evaluation.py",
144
+ "tests/test_networks.py",
145
+ "tests/test_pretrained_models.py",
146
+ "tests/test_elongate_sdf.py",
147
+ "tests/test_training_data_ids.py",
148
+ "tests/test_torch_spline.py",
149
+ "tests/test_reconstruction.py",
150
+ "tests/test_structural_optimization.py",
151
+ "tests/test_generate_dataset.py",
152
+ "tests/test_sdf_primitives.py",
153
+ "tests/test_sdf_from_mesh.py",
154
+ "tests/test_tet_orientation.py",
155
+ "tests/test_splinepy_unitcells.py",
156
+ "tests/test_mesh_export.py",
157
+ "tests/tmp_outputs/temp_file.txt",
158
+ "tests/data/stanford_bunny.stl",
159
+ "tests/data/sweep_test_case.stl",
160
+ "tests/data/example_line_mesh.vtk",
161
+ "tests/data/example_disconnectd_mesh.inp",
162
+ "tests/data/cone.stl",
163
+ "tests/data/circular_balls_test_case.stl",
164
+ "tests/data/chairs/1024.obj",
165
+ "tests/data/chairs/README.md",
166
+ "tests/data/chairs/1005.obj",
167
+ "docs/conf.py",
168
+ "docs/api_reference.rst",
169
+ "docs/Makefile",
170
+ "docs/make.bat",
171
+ "docs/qr_code_paper.png",
172
+ "docs/index.rst",
173
+ "docs/qr_code_github.png",
174
+ "docs/readme_images/example_output_03.png",
175
+ "docs/readme_images/example_output_02.png",
176
+ "docs/readme_images/example_output_04.png",
177
+ "docs/readme_images/example_output_01.png"
177
178
  ]
178
179
  }
@@ -0,0 +1,8 @@
1
+ {
2
+ "tag": "1.7.3",
3
+ "distance": 0,
4
+ "node": "gb86bba507e44fa89f841390b30b8b07983203d4e",
5
+ "dirty": false,
6
+ "branch": "HEAD",
7
+ "node_date": "2026-07-16"
8
+ }
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: DeepSDFStruct
3
- Version: 1.7.2
3
+ Version: 1.7.3
4
4
  Summary: Deep Implicit Lattice Geometry
5
5
  Author-email: Michael Kofler <michael.kofler@tuwien.ac.at>
6
6
  Requires-Python: >=3.10
@@ -0,0 +1,88 @@
1
+ """Regression tests for tetrahedron orientation in FlexiCubes output.
2
+
3
+ FlexiCubes' ``_tetrahedralize`` builds tets from two sub-procedures (surface
4
+ pyramids and interior edges) whose vertex orderings do not share a consistent
5
+ winding, so a large fraction of the elements used to come out inverted
6
+ (negative signed volume). That breaks FEA solvers, which require a positive
7
+ signed volume / Jacobian on every element. The interior sub-procedure can
8
+ additionally emit degenerate (exactly coplanar, zero-volume) tets, which are
9
+ removed during extraction. These tests pin both fixes: every tet returned by
10
+ FlexiCubes must have a strictly positive signed volume.
11
+ """
12
+
13
+ import torch
14
+
15
+ from DeepSDFStruct.flexicubes.flexicubes import FlexiCubes
16
+ from DeepSDFStruct.optimization import tet_signed_vol
17
+
18
+
19
+ def _sphere_volume_mesh(res=16, radius=0.7, center=(0.0, 0.0, 0.0)):
20
+ fc = FlexiCubes(device="cpu")
21
+ x_nx3, cube_fx8 = fc.construct_voxel_grid(
22
+ res, bounds=[[-1.0, -1.0, -1.0], [1.0, 1.0, 1.0]]
23
+ )
24
+ c = torch.tensor(center, dtype=x_nx3.dtype)
25
+ s_n = torch.linalg.norm(x_nx3 - c, dim=1) - radius
26
+ verts, tets, _ = fc(x_nx3, s_n, cube_fx8, res, output_tetmesh=True)
27
+ return verts, tets
28
+
29
+
30
+ def test_orient_tets_flips_inverted_element():
31
+ """A single inverted tet is flipped to positive signed volume."""
32
+ verts = torch.tensor(
33
+ [[0.0, 0.0, 0.0], [1.0, 0.0, 0.0], [0.0, 1.0, 0.0], [0.0, 0.0, 1.0]]
34
+ )
35
+ # [0, 1, 2, 3] is positively oriented; [0, 1, 3, 2] is its inversion.
36
+ tets = torch.tensor([[0, 1, 2, 3], [0, 1, 3, 2]])
37
+
38
+ assert (
39
+ tet_signed_vol(verts, tets) < 0
40
+ ).any(), "fixture should contain an inversion"
41
+
42
+ oriented = FlexiCubes._orient_tets(verts, tets)
43
+ vols = tet_signed_vol(verts, oriented)
44
+ assert (vols > 0).all(), f"expected all positive volumes, got {vols.tolist()}"
45
+ # Orientation is fixed by reordering indices only: |volume| is preserved.
46
+ assert torch.allclose(vols.abs(), tet_signed_vol(verts, tets).abs())
47
+
48
+
49
+ def test_orient_tets_handles_empty():
50
+ verts = torch.zeros((0, 3))
51
+ tets = torch.zeros((0, 4), dtype=torch.long)
52
+ assert FlexiCubes._orient_tets(verts, tets).shape == (0, 4)
53
+
54
+
55
+ def test_orient_tets_removes_degenerate_elements():
56
+ """Zero-volume (coplanar) tets are dropped."""
57
+ verts = torch.tensor(
58
+ [
59
+ [0.0, 0.0, 0.0],
60
+ [1.0, 0.0, 0.0],
61
+ [0.0, 1.0, 0.0],
62
+ [0.0, 0.0, 1.0],
63
+ [1.0, 1.0, 0.0], # coplanar with the first three (z = 0 plane)
64
+ ]
65
+ )
66
+ tets = torch.tensor([[0, 1, 2, 3], [0, 1, 2, 4]])
67
+
68
+ oriented = FlexiCubes._orient_tets(verts, tets)
69
+
70
+ assert oriented.shape == (1, 4)
71
+ assert (tet_signed_vol(verts, oriented) > 0).all()
72
+
73
+
74
+ def test_flexicubes_volume_mesh_has_only_positive_tets():
75
+ """End-to-end: extracted volume mesh has strictly positive signed volumes."""
76
+ for center in [(0.0, 0.0, 0.0), (0.13, 0.07, 0.21)]:
77
+ verts, tets = _sphere_volume_mesh(center=center)
78
+ assert tets.shape[0] > 0
79
+ vols = tet_signed_vol(verts, tets)
80
+ n_bad = int((vols <= 0).sum())
81
+ assert n_bad == 0, f"{n_bad} non-positive tets for center {center}"
82
+
83
+
84
+ if __name__ == "__main__":
85
+ test_orient_tets_flips_inverted_element()
86
+ test_orient_tets_handles_empty()
87
+ test_flexicubes_volume_mesh_has_only_positive_tets()
88
+ print("ok")