@mat3ra/made 2026.8.13-0 → 2026.8.26-0

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 (493) hide show
  1. package/package.json +9 -5
  2. package/.babelrc +0 -10
  3. package/.eslintrc.json +0 -11
  4. package/.gitattributes +0 -1
  5. package/.husky/post-checkout +0 -3
  6. package/.husky/post-commit +0 -3
  7. package/.husky/post-merge +0 -3
  8. package/.husky/pre-commit +0 -6
  9. package/.husky/pre-push +0 -3
  10. package/.mocharc.json +0 -5
  11. package/.pre-commit-config.yaml +0 -26
  12. package/.prettierignore +0 -2
  13. package/.prettierrc +0 -6
  14. package/AGENTS.md +0 -133
  15. package/MANIFEST.in +0 -1
  16. package/data/constants.json +0 -13
  17. package/data/reciprocal_paths.json +0 -111
  18. package/images/made/tools/tools_diagram_general.png +0 -3
  19. package/images/made/tools/tools_diagram_interface.png +0 -3
  20. package/pyproject.toml +0 -123
  21. package/scripts/generate-mixins.ts +0 -28
  22. package/src/__init__.py +0 -0
  23. package/src/js/Material.ts +0 -618
  24. package/src/js/basis/basis.ts +0 -634
  25. package/src/js/basis/constrained_basis.ts +0 -115
  26. package/src/js/basis/coordinates.ts +0 -92
  27. package/src/js/basis/elements.ts +0 -24
  28. package/src/js/basis/helpers.ts +0 -20
  29. package/src/js/basis/labels.ts +0 -6
  30. package/src/js/cell/cell.ts +0 -149
  31. package/src/js/cell/conventional_cell.ts +0 -86
  32. package/src/js/cell/primitive_cell.ts +0 -166
  33. package/src/js/constants/molecule.ts +0 -18
  34. package/src/js/constants.ts +0 -4
  35. package/src/js/constraints/constraints.ts +0 -45
  36. package/src/js/generated/MaterialSchemaMixin.ts +0 -79
  37. package/src/js/lattice/lattice.ts +0 -308
  38. package/src/js/lattice/lattice_types.ts +0 -134
  39. package/src/js/lattice/reciprocal/lattice_reciprocal.ts +0 -206
  40. package/src/js/lattice/reciprocal/paths.ts +0 -39
  41. package/src/js/lattice/reciprocal/symmetry_points.ts +0 -886
  42. package/src/js/lattice/unit_cell.ts +0 -66
  43. package/src/js/made.ts +0 -62
  44. package/src/js/parsers/cif.ts +0 -25
  45. package/src/js/parsers/errors.ts +0 -6
  46. package/src/js/parsers/espresso.ts +0 -29
  47. package/src/js/parsers/native_format_parsers.ts +0 -52
  48. package/src/js/parsers/parsers.ts +0 -13
  49. package/src/js/parsers/poscar.ts +0 -218
  50. package/src/js/parsers/xyz.ts +0 -190
  51. package/src/js/parsers/xyz_combinatorial_basis.ts +0 -268
  52. package/src/js/tools/basis.ts +0 -131
  53. package/src/js/tools/cell.ts +0 -40
  54. package/src/js/tools/index.ts +0 -11
  55. package/src/js/tools/material.ts +0 -64
  56. package/src/js/tools/supercell.ts +0 -89
  57. package/src/js/tools/surface.ts +0 -213
  58. package/src/py/__init__.py +0 -0
  59. package/src/py/mat3ra/__init__.py +0 -1
  60. package/src/py/mat3ra/made/__init__.py +0 -7
  61. package/src/py/mat3ra/made/basis/__init__.py +0 -255
  62. package/src/py/mat3ra/made/basis/coordinates.py +0 -43
  63. package/src/py/mat3ra/made/cell/__init__.py +0 -55
  64. package/src/py/mat3ra/made/cell/primitive_cell.py +0 -156
  65. package/src/py/mat3ra/made/data_helper.py +0 -5
  66. package/src/py/mat3ra/made/lattice.py +0 -195
  67. package/src/py/mat3ra/made/material.py +0 -135
  68. package/src/py/mat3ra/made/metadata.py +0 -45
  69. package/src/py/mat3ra/made/reciprocal/__init__.py +0 -5
  70. package/src/py/mat3ra/made/reciprocal/lattice_reciprocal.py +0 -147
  71. package/src/py/mat3ra/made/reciprocal/paths.py +0 -30
  72. package/src/py/mat3ra/made/reciprocal/symmetry_points.py +0 -385
  73. package/src/py/mat3ra/made/tools/README.md +0 -173
  74. package/src/py/mat3ra/made/tools/__init__.py +0 -0
  75. package/src/py/mat3ra/made/tools/analyze/__init__.py +0 -31
  76. package/src/py/mat3ra/made/tools/analyze/basis/__init__.py +0 -3
  77. package/src/py/mat3ra/made/tools/analyze/basis/analyzer.py +0 -50
  78. package/src/py/mat3ra/made/tools/analyze/build_metadata_analyzer.py +0 -32
  79. package/src/py/mat3ra/made/tools/analyze/build_metadata_analyzer_factory.py +0 -31
  80. package/src/py/mat3ra/made/tools/analyze/coordination.py +0 -56
  81. package/src/py/mat3ra/made/tools/analyze/crystal_site/__init__.py +0 -0
  82. package/src/py/mat3ra/made/tools/analyze/crystal_site/adatom_crystal_site_material_analyzer.py +0 -35
  83. package/src/py/mat3ra/made/tools/analyze/crystal_site/adatom_material_analyzer.py +0 -49
  84. package/src/py/mat3ra/made/tools/analyze/crystal_site/crystal_site_analyzer.py +0 -65
  85. package/src/py/mat3ra/made/tools/analyze/crystal_site/voronoi_crystal_site_analyzer.py +0 -47
  86. package/src/py/mat3ra/made/tools/analyze/enums.py +0 -33
  87. package/src/py/mat3ra/made/tools/analyze/fingerprint/__init__.py +0 -4
  88. package/src/py/mat3ra/made/tools/analyze/fingerprint/layers/__init__.py +0 -0
  89. package/src/py/mat3ra/made/tools/analyze/fingerprint/layers/layered_fingerprint_along_axis.py +0 -83
  90. package/src/py/mat3ra/made/tools/analyze/fingerprint/layers/unique_element_string_per_layer.py +0 -9
  91. package/src/py/mat3ra/made/tools/analyze/interface/__init__.py +0 -20
  92. package/src/py/mat3ra/made/tools/analyze/interface/commensurate.py +0 -156
  93. package/src/py/mat3ra/made/tools/analyze/interface/enums.py +0 -60
  94. package/src/py/mat3ra/made/tools/analyze/interface/grain_boundary.py +0 -80
  95. package/src/py/mat3ra/made/tools/analyze/interface/simple.py +0 -251
  96. package/src/py/mat3ra/made/tools/analyze/interface/twisted_nanoribbons.py +0 -91
  97. package/src/py/mat3ra/made/tools/analyze/interface/utils/__init__.py +0 -77
  98. package/src/py/mat3ra/made/tools/analyze/interface/utils/holders.py +0 -14
  99. package/src/py/mat3ra/made/tools/analyze/interface/utils/vector.py +0 -56
  100. package/src/py/mat3ra/made/tools/analyze/interface/zsl.py +0 -259
  101. package/src/py/mat3ra/made/tools/analyze/interface_material.py +0 -45
  102. package/src/py/mat3ra/made/tools/analyze/lattice/__init__.py +0 -2
  103. package/src/py/mat3ra/made/tools/analyze/lattice/analyzer.py +0 -126
  104. package/src/py/mat3ra/made/tools/analyze/lattice/helpers.py +0 -31
  105. package/src/py/mat3ra/made/tools/analyze/lattice_lines.py +0 -30
  106. package/src/py/mat3ra/made/tools/analyze/lattice_planes.py +0 -192
  107. package/src/py/mat3ra/made/tools/analyze/lattice_swap_analyzer.py +0 -105
  108. package/src/py/mat3ra/made/tools/analyze/material.py +0 -276
  109. package/src/py/mat3ra/made/tools/analyze/other.py +0 -434
  110. package/src/py/mat3ra/made/tools/analyze/rdf.py +0 -74
  111. package/src/py/mat3ra/made/tools/analyze/slab.py +0 -76
  112. package/src/py/mat3ra/made/tools/analyze/solid_solution_analyzer.py +0 -171
  113. package/src/py/mat3ra/made/tools/analyze/terrace.py +0 -105
  114. package/src/py/mat3ra/made/tools/analyze/utils.py +0 -162
  115. package/src/py/mat3ra/made/tools/bond_directions/__init__.py +0 -0
  116. package/src/py/mat3ra/made/tools/bond_directions/bond_directions.py +0 -150
  117. package/src/py/mat3ra/made/tools/bond_directions/bond_directions_for_element_list.py +0 -7
  118. package/src/py/mat3ra/made/tools/bond_directions/bond_directions_templates_enum.py +0 -8
  119. package/src/py/mat3ra/made/tools/bond_directions/bond_directions_templates_for_element.py +0 -16
  120. package/src/py/mat3ra/made/tools/build/__init__.py +0 -25
  121. package/src/py/mat3ra/made/tools/build/compound_pristine_structures/two_dimensional/heterostructure/__init__.py +0 -7
  122. package/src/py/mat3ra/made/tools/build/compound_pristine_structures/two_dimensional/heterostructure/helpers.py +0 -59
  123. package/src/py/mat3ra/made/tools/build/compound_pristine_structures/two_dimensional/heterostructure/types.py +0 -26
  124. package/src/py/mat3ra/made/tools/build/compound_pristine_structures/two_dimensional/heterostructure/utils.py +0 -139
  125. package/src/py/mat3ra/made/tools/build/compound_pristine_structures/two_dimensional/interface/__init__.py +0 -47
  126. package/src/py/mat3ra/made/tools/build/compound_pristine_structures/two_dimensional/interface/base/__init__.py +0 -11
  127. package/src/py/mat3ra/made/tools/build/compound_pristine_structures/two_dimensional/interface/base/build_parameters.py +0 -5
  128. package/src/py/mat3ra/made/tools/build/compound_pristine_structures/two_dimensional/interface/base/builder.py +0 -164
  129. package/src/py/mat3ra/made/tools/build/compound_pristine_structures/two_dimensional/interface/base/configuration.py +0 -48
  130. package/src/py/mat3ra/made/tools/build/compound_pristine_structures/two_dimensional/interface/base/helpers.py +0 -134
  131. package/src/py/mat3ra/made/tools/build/compound_pristine_structures/two_dimensional/interface/commensurate/__init__.py +0 -6
  132. package/src/py/mat3ra/made/tools/build/compound_pristine_structures/two_dimensional/interface/commensurate/helpers.py +0 -157
  133. package/src/py/mat3ra/made/tools/build/compound_pristine_structures/two_dimensional/interface/enums.py +0 -7
  134. package/src/py/mat3ra/made/tools/build/compound_pristine_structures/two_dimensional/interface/twisted/__init__.py +0 -7
  135. package/src/py/mat3ra/made/tools/build/compound_pristine_structures/two_dimensional/interface/twisted/configuration.py +0 -13
  136. package/src/py/mat3ra/made/tools/build/compound_pristine_structures/two_dimensional/interface/twisted/helpers.py +0 -70
  137. package/src/py/mat3ra/made/tools/build/compound_pristine_structures/two_dimensional/interface/utils.py +0 -87
  138. package/src/py/mat3ra/made/tools/build/compound_pristine_structures/two_dimensional/interface/zsl/__init__.py +0 -6
  139. package/src/py/mat3ra/made/tools/build/compound_pristine_structures/two_dimensional/interface/zsl/helpers.py +0 -129
  140. package/src/py/mat3ra/made/tools/build/defective_structures/__init__.py +0 -0
  141. package/src/py/mat3ra/made/tools/build/defective_structures/one_dimensional/__init__.py +0 -0
  142. package/src/py/mat3ra/made/tools/build/defective_structures/one_dimensional/grain_boundary_linear/__init__.py +0 -0
  143. package/src/py/mat3ra/made/tools/build/defective_structures/one_dimensional/grain_boundary_linear/build_parameters.py +0 -12
  144. package/src/py/mat3ra/made/tools/build/defective_structures/one_dimensional/grain_boundary_linear/builder.py +0 -17
  145. package/src/py/mat3ra/made/tools/build/defective_structures/one_dimensional/grain_boundary_linear/configuration.py +0 -40
  146. package/src/py/mat3ra/made/tools/build/defective_structures/one_dimensional/grain_boundary_linear/helpers.py +0 -82
  147. package/src/py/mat3ra/made/tools/build/defective_structures/three_dimensional/__init__.py +0 -1
  148. package/src/py/mat3ra/made/tools/build/defective_structures/three_dimensional/solid_solution/__init__.py +0 -9
  149. package/src/py/mat3ra/made/tools/build/defective_structures/three_dimensional/solid_solution/builder.py +0 -37
  150. package/src/py/mat3ra/made/tools/build/defective_structures/three_dimensional/solid_solution/configuration.py +0 -30
  151. package/src/py/mat3ra/made/tools/build/defective_structures/three_dimensional/solid_solution/enums.py +0 -8
  152. package/src/py/mat3ra/made/tools/build/defective_structures/three_dimensional/solid_solution/helpers.py +0 -76
  153. package/src/py/mat3ra/made/tools/build/defective_structures/two_dimensional/__init__.py +0 -0
  154. package/src/py/mat3ra/made/tools/build/defective_structures/two_dimensional/adatom/__init__.py +0 -0
  155. package/src/py/mat3ra/made/tools/build/defective_structures/two_dimensional/adatom/builder.py +0 -11
  156. package/src/py/mat3ra/made/tools/build/defective_structures/two_dimensional/adatom/configuration.py +0 -18
  157. package/src/py/mat3ra/made/tools/build/defective_structures/two_dimensional/adatom/helpers.py +0 -137
  158. package/src/py/mat3ra/made/tools/build/defective_structures/two_dimensional/adatom/types.py +0 -22
  159. package/src/py/mat3ra/made/tools/build/defective_structures/two_dimensional/grain_boundary_planar/__init__.py +0 -0
  160. package/src/py/mat3ra/made/tools/build/defective_structures/two_dimensional/grain_boundary_planar/builder.py +0 -28
  161. package/src/py/mat3ra/made/tools/build/defective_structures/two_dimensional/grain_boundary_planar/configuration.py +0 -55
  162. package/src/py/mat3ra/made/tools/build/defective_structures/two_dimensional/grain_boundary_planar/helpers.py +0 -75
  163. package/src/py/mat3ra/made/tools/build/defective_structures/two_dimensional/island/builder.py +0 -15
  164. package/src/py/mat3ra/made/tools/build/defective_structures/two_dimensional/island/configuration.py +0 -16
  165. package/src/py/mat3ra/made/tools/build/defective_structures/two_dimensional/island/helpers.py +0 -116
  166. package/src/py/mat3ra/made/tools/build/defective_structures/two_dimensional/terrace/build_parameters.py +0 -10
  167. package/src/py/mat3ra/made/tools/build/defective_structures/two_dimensional/terrace/builder.py +0 -30
  168. package/src/py/mat3ra/made/tools/build/defective_structures/two_dimensional/terrace/configuration.py +0 -11
  169. package/src/py/mat3ra/made/tools/build/defective_structures/two_dimensional/terrace/helpers.py +0 -78
  170. package/src/py/mat3ra/made/tools/build/defective_structures/zero_dimensional/__init__.py +0 -0
  171. package/src/py/mat3ra/made/tools/build/defective_structures/zero_dimensional/pair_defect/__init__.py +0 -0
  172. package/src/py/mat3ra/made/tools/build/defective_structures/zero_dimensional/pair_defect/builder.py +0 -31
  173. package/src/py/mat3ra/made/tools/build/defective_structures/zero_dimensional/pair_defect/configuration.py +0 -45
  174. package/src/py/mat3ra/made/tools/build/defective_structures/zero_dimensional/pair_defect/helpers.py +0 -80
  175. package/src/py/mat3ra/made/tools/build/defective_structures/zero_dimensional/point_defect/__init__.py +0 -40
  176. package/src/py/mat3ra/made/tools/build/defective_structures/zero_dimensional/point_defect/atom_placement_method_enum.py +0 -14
  177. package/src/py/mat3ra/made/tools/build/defective_structures/zero_dimensional/point_defect/base/__init__.py +0 -7
  178. package/src/py/mat3ra/made/tools/build/defective_structures/zero_dimensional/point_defect/base/builder.py +0 -42
  179. package/src/py/mat3ra/made/tools/build/defective_structures/zero_dimensional/point_defect/base/configuration.py +0 -27
  180. package/src/py/mat3ra/made/tools/build/defective_structures/zero_dimensional/point_defect/complex_defect_type_enum.py +0 -5
  181. package/src/py/mat3ra/made/tools/build/defective_structures/zero_dimensional/point_defect/factories.py +0 -69
  182. package/src/py/mat3ra/made/tools/build/defective_structures/zero_dimensional/point_defect/helpers.py +0 -92
  183. package/src/py/mat3ra/made/tools/build/defective_structures/zero_dimensional/point_defect/interstitial/__init__.py +0 -7
  184. package/src/py/mat3ra/made/tools/build/defective_structures/zero_dimensional/point_defect/interstitial/builder.py +0 -8
  185. package/src/py/mat3ra/made/tools/build/defective_structures/zero_dimensional/point_defect/interstitial/configuration.py +0 -29
  186. package/src/py/mat3ra/made/tools/build/defective_structures/zero_dimensional/point_defect/interstitial/helpers.py +0 -48
  187. package/src/py/mat3ra/made/tools/build/defective_structures/zero_dimensional/point_defect/interstitial/interstitial_placement_method_enum.py +0 -8
  188. package/src/py/mat3ra/made/tools/build/defective_structures/zero_dimensional/point_defect/point_defect_type_enum.py +0 -8
  189. package/src/py/mat3ra/made/tools/build/defective_structures/zero_dimensional/point_defect/substitutional/__init__.py +0 -7
  190. package/src/py/mat3ra/made/tools/build/defective_structures/zero_dimensional/point_defect/substitutional/builder.py +0 -6
  191. package/src/py/mat3ra/made/tools/build/defective_structures/zero_dimensional/point_defect/substitutional/configuration.py +0 -41
  192. package/src/py/mat3ra/made/tools/build/defective_structures/zero_dimensional/point_defect/substitutional/helpers.py +0 -43
  193. package/src/py/mat3ra/made/tools/build/defective_structures/zero_dimensional/point_defect/substitutional/substitution_placement_method_enum.py +0 -7
  194. package/src/py/mat3ra/made/tools/build/defective_structures/zero_dimensional/point_defect/types.py +0 -24
  195. package/src/py/mat3ra/made/tools/build/defective_structures/zero_dimensional/point_defect/vacancy/__init__.py +0 -7
  196. package/src/py/mat3ra/made/tools/build/defective_structures/zero_dimensional/point_defect/vacancy/builder.py +0 -19
  197. package/src/py/mat3ra/made/tools/build/defective_structures/zero_dimensional/point_defect/vacancy/configuration.py +0 -27
  198. package/src/py/mat3ra/made/tools/build/defective_structures/zero_dimensional/point_defect/vacancy/helpers.py +0 -42
  199. package/src/py/mat3ra/made/tools/build/defective_structures/zero_dimensional/point_defect/vacancy/vacancy_placement_method_enum.py +0 -7
  200. package/src/py/mat3ra/made/tools/build/pristine_structures/__init__.py +0 -0
  201. package/src/py/mat3ra/made/tools/build/pristine_structures/three_dimensional/ideal_crystal/__init__.py +0 -0
  202. package/src/py/mat3ra/made/tools/build/pristine_structures/three_dimensional/ideal_crystal/builder.py +0 -80
  203. package/src/py/mat3ra/made/tools/build/pristine_structures/three_dimensional/ideal_crystal/configurations.py +0 -22
  204. package/src/py/mat3ra/made/tools/build/pristine_structures/three_dimensional/ideal_crystal/helpers.py +0 -40
  205. package/src/py/mat3ra/made/tools/build/pristine_structures/two_dimensional/__init__.py +0 -0
  206. package/src/py/mat3ra/made/tools/build/pristine_structures/two_dimensional/nanoribbon/__init__.py +0 -29
  207. package/src/py/mat3ra/made/tools/build/pristine_structures/two_dimensional/nanoribbon/build_parameters.py +0 -5
  208. package/src/py/mat3ra/made/tools/build/pristine_structures/two_dimensional/nanoribbon/builders.py +0 -56
  209. package/src/py/mat3ra/made/tools/build/pristine_structures/two_dimensional/nanoribbon/configuration.py +0 -33
  210. package/src/py/mat3ra/made/tools/build/pristine_structures/two_dimensional/nanoribbon/helpers.py +0 -76
  211. package/src/py/mat3ra/made/tools/build/pristine_structures/two_dimensional/nanotape/__init__.py +0 -11
  212. package/src/py/mat3ra/made/tools/build/pristine_structures/two_dimensional/nanotape/build_parameters.py +0 -9
  213. package/src/py/mat3ra/made/tools/build/pristine_structures/two_dimensional/nanotape/builders.py +0 -83
  214. package/src/py/mat3ra/made/tools/build/pristine_structures/two_dimensional/nanotape/configuration.py +0 -35
  215. package/src/py/mat3ra/made/tools/build/pristine_structures/two_dimensional/nanotape/helpers.py +0 -62
  216. package/src/py/mat3ra/made/tools/build/pristine_structures/two_dimensional/slab/__init__.py +0 -9
  217. package/src/py/mat3ra/made/tools/build/pristine_structures/two_dimensional/slab/build_parameters.py +0 -8
  218. package/src/py/mat3ra/made/tools/build/pristine_structures/two_dimensional/slab/builder.py +0 -42
  219. package/src/py/mat3ra/made/tools/build/pristine_structures/two_dimensional/slab/configuration.py +0 -99
  220. package/src/py/mat3ra/made/tools/build/pristine_structures/two_dimensional/slab/helpers.py +0 -95
  221. package/src/py/mat3ra/made/tools/build/pristine_structures/two_dimensional/slab/termination_utils.py +0 -14
  222. package/src/py/mat3ra/made/tools/build/pristine_structures/two_dimensional/slab/utils.py +0 -61
  223. package/src/py/mat3ra/made/tools/build/pristine_structures/two_dimensional/slab_strained_supercell/builder.py +0 -22
  224. package/src/py/mat3ra/made/tools/build/pristine_structures/two_dimensional/slab_strained_supercell/configuration.py +0 -17
  225. package/src/py/mat3ra/made/tools/build/pristine_structures/zero_dimensional/__init__.py +0 -0
  226. package/src/py/mat3ra/made/tools/build/pristine_structures/zero_dimensional/nanoparticle/__init__.py +0 -19
  227. package/src/py/mat3ra/made/tools/build/pristine_structures/zero_dimensional/nanoparticle/analyzer.py +0 -86
  228. package/src/py/mat3ra/made/tools/build/pristine_structures/zero_dimensional/nanoparticle/ase_based/__init__.py +0 -7
  229. package/src/py/mat3ra/made/tools/build/pristine_structures/zero_dimensional/nanoparticle/ase_based/builder.py +0 -54
  230. package/src/py/mat3ra/made/tools/build/pristine_structures/zero_dimensional/nanoparticle/ase_based/configuration.py +0 -19
  231. package/src/py/mat3ra/made/tools/build/pristine_structures/zero_dimensional/nanoparticle/enums.py +0 -42
  232. package/src/py/mat3ra/made/tools/build/pristine_structures/zero_dimensional/nanoparticle/helpers.py +0 -127
  233. package/src/py/mat3ra/made/tools/build/pristine_structures/zero_dimensional/nanoparticle/merge_based/__init__.py +0 -7
  234. package/src/py/mat3ra/made/tools/build/pristine_structures/zero_dimensional/nanoparticle/merge_based/builder.py +0 -33
  235. package/src/py/mat3ra/made/tools/build/pristine_structures/zero_dimensional/nanoparticle/merge_based/configuration.py +0 -16
  236. package/src/py/mat3ra/made/tools/build/processed_structures/__init__.py +0 -0
  237. package/src/py/mat3ra/made/tools/build/processed_structures/two_dimensional/__init__.py +0 -0
  238. package/src/py/mat3ra/made/tools/build/processed_structures/two_dimensional/passivation/__init__.py +0 -0
  239. package/src/py/mat3ra/made/tools/build/processed_structures/two_dimensional/passivation/analyzers/__init__.py +0 -9
  240. package/src/py/mat3ra/made/tools/build/processed_structures/two_dimensional/passivation/analyzers/coordination_based_passivation_material_analyzer.py +0 -112
  241. package/src/py/mat3ra/made/tools/build/processed_structures/two_dimensional/passivation/analyzers/passivation_material_analyzer.py +0 -16
  242. package/src/py/mat3ra/made/tools/build/processed_structures/two_dimensional/passivation/analyzers/surface_passivation_material_analyzer.py +0 -32
  243. package/src/py/mat3ra/made/tools/build/processed_structures/two_dimensional/passivation/builder.py +0 -23
  244. package/src/py/mat3ra/made/tools/build/processed_structures/two_dimensional/passivation/configuration.py +0 -31
  245. package/src/py/mat3ra/made/tools/build/processed_structures/two_dimensional/passivation/enums.py +0 -7
  246. package/src/py/mat3ra/made/tools/build/processed_structures/two_dimensional/passivation/helpers.py +0 -151
  247. package/src/py/mat3ra/made/tools/build_components/__init__.py +0 -10
  248. package/src/py/mat3ra/made/tools/build_components/entities/__init__.py +0 -0
  249. package/src/py/mat3ra/made/tools/build_components/entities/auxiliary/__init__.py +0 -0
  250. package/src/py/mat3ra/made/tools/build_components/entities/auxiliary/one_dimensional/miller_indices_2d.py +0 -0
  251. package/src/py/mat3ra/made/tools/build_components/entities/auxiliary/two_dimensional/miller_indices.py +0 -18
  252. package/src/py/mat3ra/made/tools/build_components/entities/auxiliary/two_dimensional/termination.py +0 -33
  253. package/src/py/mat3ra/made/tools/build_components/entities/auxiliary/zero_dimensional/__init__.py +0 -0
  254. package/src/py/mat3ra/made/tools/build_components/entities/auxiliary/zero_dimensional/crystal_site/__init__.py +0 -2
  255. package/src/py/mat3ra/made/tools/build_components/entities/auxiliary/zero_dimensional/crystal_site/crystal_site.py +0 -24
  256. package/src/py/mat3ra/made/tools/build_components/entities/auxiliary/zero_dimensional/crystal_site/crystal_site_list.py +0 -9
  257. package/src/py/mat3ra/made/tools/build_components/entities/auxiliary/zero_dimensional/point_defect_site/builder.py +0 -32
  258. package/src/py/mat3ra/made/tools/build_components/entities/auxiliary/zero_dimensional/point_defect_site/configuration.py +0 -14
  259. package/src/py/mat3ra/made/tools/build_components/entities/auxiliary/zero_dimensional/void_region/__init__.py +0 -0
  260. package/src/py/mat3ra/made/tools/build_components/entities/auxiliary/zero_dimensional/void_region/builder.py +0 -29
  261. package/src/py/mat3ra/made/tools/build_components/entities/auxiliary/zero_dimensional/void_region/configuration.py +0 -19
  262. package/src/py/mat3ra/made/tools/build_components/entities/core/two_dimensional/vacuum/builder.py +0 -48
  263. package/src/py/mat3ra/made/tools/build_components/entities/core/two_dimensional/vacuum/configuration.py +0 -17
  264. package/src/py/mat3ra/made/tools/build_components/entities/core/zero_dimensional/atom/builder.py +0 -25
  265. package/src/py/mat3ra/made/tools/build_components/entities/core/zero_dimensional/atom/configuration.py +0 -8
  266. package/src/py/mat3ra/made/tools/build_components/entities/reusable/__init__.py +0 -0
  267. package/src/py/mat3ra/made/tools/build_components/entities/reusable/base_builder/__init__.py +0 -16
  268. package/src/py/mat3ra/made/tools/build_components/entities/reusable/base_builder/base_configuration_pydantic.py +0 -5
  269. package/src/py/mat3ra/made/tools/build_components/entities/reusable/base_builder/base_single_builder.py +0 -87
  270. package/src/py/mat3ra/made/tools/build_components/entities/reusable/base_builder/build_parameters.py +0 -5
  271. package/src/py/mat3ra/made/tools/build_components/entities/reusable/one_dimensional/__init__.py +0 -0
  272. package/src/py/mat3ra/made/tools/build_components/entities/reusable/one_dimensional/crystal_lattice_lines/__init__.py +0 -4
  273. package/src/py/mat3ra/made/tools/build_components/entities/reusable/one_dimensional/crystal_lattice_lines/builder.py +0 -46
  274. package/src/py/mat3ra/made/tools/build_components/entities/reusable/one_dimensional/crystal_lattice_lines/configuration.py +0 -19
  275. package/src/py/mat3ra/made/tools/build_components/entities/reusable/one_dimensional/crystal_lattice_lines/edge_types.py +0 -51
  276. package/src/py/mat3ra/made/tools/build_components/entities/reusable/one_dimensional/crystal_lattice_lines/helpers.py +0 -58
  277. package/src/py/mat3ra/made/tools/build_components/entities/reusable/one_dimensional/crystal_lattice_lines_unique_repeated/__init__.py +0 -4
  278. package/src/py/mat3ra/made/tools/build_components/entities/reusable/one_dimensional/crystal_lattice_lines_unique_repeated/builder.py +0 -42
  279. package/src/py/mat3ra/made/tools/build_components/entities/reusable/one_dimensional/crystal_lattice_lines_unique_repeated/configuration.py +0 -21
  280. package/src/py/mat3ra/made/tools/build_components/entities/reusable/three_dimensional/supercell/__init__.py +0 -0
  281. package/src/py/mat3ra/made/tools/build_components/entities/reusable/three_dimensional/supercell/configuration.py +0 -11
  282. package/src/py/mat3ra/made/tools/build_components/entities/reusable/three_dimensional/supercell/helpers.py +0 -38
  283. package/src/py/mat3ra/made/tools/build_components/entities/reusable/two_dimensional/__init__.py +0 -24
  284. package/src/py/mat3ra/made/tools/build_components/entities/reusable/two_dimensional/atomic_layers_unique_repeated/__init__.py +0 -7
  285. package/src/py/mat3ra/made/tools/build_components/entities/reusable/two_dimensional/atomic_layers_unique_repeated/builder.py +0 -62
  286. package/src/py/mat3ra/made/tools/build_components/entities/reusable/two_dimensional/atomic_layers_unique_repeated/configuration.py +0 -14
  287. package/src/py/mat3ra/made/tools/build_components/entities/reusable/two_dimensional/atomic_layers_unique_repeated/helpers.py +0 -42
  288. package/src/py/mat3ra/made/tools/build_components/entities/reusable/two_dimensional/crystal_lattice_planes/__init__.py +0 -7
  289. package/src/py/mat3ra/made/tools/build_components/entities/reusable/two_dimensional/crystal_lattice_planes/builder.py +0 -39
  290. package/src/py/mat3ra/made/tools/build_components/entities/reusable/two_dimensional/crystal_lattice_planes/configuration.py +0 -24
  291. package/src/py/mat3ra/made/tools/build_components/entities/reusable/two_dimensional/slab_stack/__init__.py +0 -10
  292. package/src/py/mat3ra/made/tools/build_components/entities/reusable/two_dimensional/slab_stack/builder.py +0 -36
  293. package/src/py/mat3ra/made/tools/build_components/entities/reusable/two_dimensional/slab_stack/configuration.py +0 -31
  294. package/src/py/mat3ra/made/tools/build_components/entities/reusable/two_dimensional/slab_stack/helpers.py +0 -80
  295. package/src/py/mat3ra/made/tools/build_components/entities/reusable/zero_dimensional/__init__.py +0 -0
  296. package/src/py/mat3ra/made/tools/build_components/entities/reusable/zero_dimensional/coordinates_shape_enum.py +0 -8
  297. package/src/py/mat3ra/made/tools/build_components/metadata/__init__.py +0 -2
  298. package/src/py/mat3ra/made/tools/build_components/metadata/build_metadata.py +0 -7
  299. package/src/py/mat3ra/made/tools/build_components/metadata/material_build_metadata.py +0 -35
  300. package/src/py/mat3ra/made/tools/build_components/metadata/material_with_build_metadata.py +0 -8
  301. package/src/py/mat3ra/made/tools/build_components/mixins/__init__.py +0 -2
  302. package/src/py/mat3ra/made/tools/build_components/mixins/convert_generated_items_ase_atoms_mixin.py +0 -8
  303. package/src/py/mat3ra/made/tools/build_components/mixins/convert_generated_items_pymatgen_structure_mixin.py +0 -8
  304. package/src/py/mat3ra/made/tools/build_components/operations/core/combinations/__init__.py +0 -0
  305. package/src/py/mat3ra/made/tools/build_components/operations/core/combinations/enums.py +0 -11
  306. package/src/py/mat3ra/made/tools/build_components/operations/core/combinations/merge/__init__.py +0 -6
  307. package/src/py/mat3ra/made/tools/build_components/operations/core/combinations/merge/build_parameters.py +0 -18
  308. package/src/py/mat3ra/made/tools/build_components/operations/core/combinations/merge/builder.py +0 -93
  309. package/src/py/mat3ra/made/tools/build_components/operations/core/combinations/merge/configuration.py +0 -20
  310. package/src/py/mat3ra/made/tools/build_components/operations/core/combinations/stack/builder.py +0 -83
  311. package/src/py/mat3ra/made/tools/build_components/operations/core/combinations/stack/configuration.py +0 -24
  312. package/src/py/mat3ra/made/tools/build_components/operations/core/modifications/perturb/__init__.py +0 -15
  313. package/src/py/mat3ra/made/tools/build_components/operations/core/modifications/perturb/build_parameters.py +0 -5
  314. package/src/py/mat3ra/made/tools/build_components/operations/core/modifications/perturb/builders/base.py +0 -33
  315. package/src/py/mat3ra/made/tools/build_components/operations/core/modifications/perturb/builders/isometric.py +0 -25
  316. package/src/py/mat3ra/made/tools/build_components/operations/core/modifications/perturb/configuration.py +0 -24
  317. package/src/py/mat3ra/made/tools/build_components/operations/core/modifications/perturb/functions/__init__.py +0 -13
  318. package/src/py/mat3ra/made/tools/build_components/operations/core/modifications/perturb/functions/atomic_mass_dependent_function_holder.py +0 -32
  319. package/src/py/mat3ra/made/tools/build_components/operations/core/modifications/perturb/functions/function_holder.py +0 -80
  320. package/src/py/mat3ra/made/tools/build_components/operations/core/modifications/perturb/functions/maxwell_boltzmann.py +0 -39
  321. package/src/py/mat3ra/made/tools/build_components/operations/core/modifications/perturb/functions/perturbation_function_holder.py +0 -45
  322. package/src/py/mat3ra/made/tools/build_components/operations/core/modifications/perturb/functions/sine_wave_perturbation_function_holder.py +0 -29
  323. package/src/py/mat3ra/made/tools/build_components/operations/core/modifications/perturb/helpers.py +0 -83
  324. package/src/py/mat3ra/made/tools/build_components/operations/core/modifications/strain/__init__.py +0 -5
  325. package/src/py/mat3ra/made/tools/build_components/operations/core/modifications/strain/builder.py +0 -25
  326. package/src/py/mat3ra/made/tools/build_components/operations/core/modifications/strain/configuration.py +0 -23
  327. package/src/py/mat3ra/made/tools/build_components/operations/core/modifications/strain/helpers.py +0 -49
  328. package/src/py/mat3ra/made/tools/build_components/utils.py +0 -44
  329. package/src/py/mat3ra/made/tools/calculate/__init__.py +0 -149
  330. package/src/py/mat3ra/made/tools/calculate/ase/__init__.py +0 -133
  331. package/src/py/mat3ra/made/tools/calculate/ase/constraints.py +0 -91
  332. package/src/py/mat3ra/made/tools/calculate/calculators/__init__.py +0 -4
  333. package/src/py/mat3ra/made/tools/calculate/calculators/interface_material_calculator.py +0 -70
  334. package/src/py/mat3ra/made/tools/calculate/calculators/interface_material_calculator_parameters.py +0 -14
  335. package/src/py/mat3ra/made/tools/calculate/calculators/material_calculator.py +0 -32
  336. package/src/py/mat3ra/made/tools/calculate/calculators/material_calculator_parameters.py +0 -17
  337. package/src/py/mat3ra/made/tools/calculate/interaction_functions.py +0 -23
  338. package/src/py/mat3ra/made/tools/convert/__init__.py +0 -286
  339. package/src/py/mat3ra/made/tools/convert/interface_parts_enum.py +0 -9
  340. package/src/py/mat3ra/made/tools/convert/utils.py +0 -96
  341. package/src/py/mat3ra/made/tools/entities/__init__.py +0 -5
  342. package/src/py/mat3ra/made/tools/entities/coordinate/__init__.py +0 -14
  343. package/src/py/mat3ra/made/tools/entities/coordinate/box_coordinate_condition.py +0 -15
  344. package/src/py/mat3ra/made/tools/entities/coordinate/coordinate_condition.py +0 -16
  345. package/src/py/mat3ra/made/tools/entities/coordinate/coordinate_functions.py +0 -158
  346. package/src/py/mat3ra/made/tools/entities/coordinate/cylinder_coordinate_condition.py +0 -17
  347. package/src/py/mat3ra/made/tools/entities/coordinate/plane_coordinate_condition.py +0 -14
  348. package/src/py/mat3ra/made/tools/entities/coordinate/sphere_coordinate_condition.py +0 -15
  349. package/src/py/mat3ra/made/tools/entities/coordinate/triangular_prism_coordinate_condition.py +0 -26
  350. package/src/py/mat3ra/made/tools/entities/termination_holder.py +0 -12
  351. package/src/py/mat3ra/made/tools/helpers.py +0 -168
  352. package/src/py/mat3ra/made/tools/modify.py +0 -627
  353. package/src/py/mat3ra/made/tools/operations/core/binary.py +0 -106
  354. package/src/py/mat3ra/made/tools/operations/core/unary.py +0 -170
  355. package/src/py/mat3ra/made/tools/operations/core/utils.py +0 -138
  356. package/src/py/mat3ra/made/tools/operations/reusable/unary.py +0 -53
  357. package/src/py/mat3ra/made/tools/optimize.py +0 -55
  358. package/src/py/mat3ra/made/tools/third_party.py +0 -69
  359. package/src/py/mat3ra/made/tools/utils.py +0 -182
  360. package/src/py/mat3ra/made/utils.py +0 -144
  361. package/tests/.gitattributes +0 -1
  362. package/tests/fixtures/AsGe-basis.json +0 -3
  363. package/tests/fixtures/C2H4-translated.json +0 -3
  364. package/tests/fixtures/C2H4.json +0 -3
  365. package/tests/fixtures/FeLiSi-basis.json +0 -3
  366. package/tests/fixtures/FeO.json +0 -3
  367. package/tests/fixtures/Ge2-basis.json +0 -3
  368. package/tests/fixtures/Graphene.json +0 -3
  369. package/tests/fixtures/Graphene.poscar +0 -3
  370. package/tests/fixtures/H2+H-final.json +0 -3
  371. package/tests/fixtures/H2+H-image.json +0 -3
  372. package/tests/fixtures/H2+H-initial.json +0 -3
  373. package/tests/fixtures/H2O.poscar +0 -3
  374. package/tests/fixtures/LiFeSi-basis-labels.json +0 -3
  375. package/tests/fixtures/LiFeSi-basis.json +0 -3
  376. package/tests/fixtures/Na.json +0 -3
  377. package/tests/fixtures/Na4Cl4-cartesian.json +0 -3
  378. package/tests/fixtures/Na4Cl4.json +0 -3
  379. package/tests/fixtures/Na4Cl4.poscar +0 -3
  380. package/tests/fixtures/Ni-hex.json +0 -3
  381. package/tests/fixtures/Ni-hex.poscar +0 -3
  382. package/tests/fixtures/OSi-basis.json +0 -3
  383. package/tests/fixtures/Si-hex.poscar +0 -3
  384. package/tests/fixtures/Si-pwscf.in +0 -3
  385. package/tests/fixtures/Si-slab.json +0 -3
  386. package/tests/fixtures/Si-supercell.json +0 -3
  387. package/tests/fixtures/Si2-basis-repeated.json +0 -3
  388. package/tests/fixtures/Si2-basis.json +0 -3
  389. package/tests/fixtures/Zr1H23Zr1H1.json +0 -3
  390. package/tests/fixtures/Zr1H23Zr1H1.poscar +0 -3
  391. package/tests/fixtures/atomic-constraints.json +0 -3
  392. package/tests/fixtures/hashes.json +0 -3
  393. package/tests/fixtures/si-slab-100.json +0 -3
  394. package/tests/fixtures/si-slab-111-0-vacuum.json +0 -3
  395. package/tests/fixtures/si-slab-111-0.5-vacuum-gamma-120.json +0 -3
  396. package/tests/fixtures/si-slab-111-0.5-vacuum-ratio.json +0 -3
  397. package/tests/fixtures/si-standata.json +0 -3
  398. package/tests/js/basis/basis.ts +0 -247
  399. package/tests/js/cell/cell.ts +0 -182
  400. package/tests/js/cell/primitive_cell.ts +0 -21
  401. package/tests/js/constraints/constraints.ts +0 -11
  402. package/tests/js/fixtures.ts +0 -123
  403. package/tests/js/lattice/lattice.ts +0 -43
  404. package/tests/js/lattice/lattice_reciprocal.ts +0 -104
  405. package/tests/js/material/material.ts +0 -161
  406. package/tests/js/parsers/espresso.ts +0 -12
  407. package/tests/js/parsers/native_formats.ts +0 -35
  408. package/tests/js/parsers/poscar.ts +0 -89
  409. package/tests/js/parsers/xyz.ts +0 -33
  410. package/tests/js/parsers/xyz_combinatorial_basis.ts +0 -156
  411. package/tests/js/register-esse-schemas.cjs +0 -10
  412. package/tests/js/setup.ts +0 -6
  413. package/tests/js/tools/basis.ts +0 -22
  414. package/tests/js/tools/supercell.ts +0 -58
  415. package/tests/js/tools/surface.ts +0 -111
  416. package/tests/py/conftest.py +0 -34
  417. package/tests/py/mat3ra/debug_utils.py +0 -75
  418. package/tests/py/unit/__init__.py +0 -0
  419. package/tests/py/unit/fixtures/__init__.py +0 -0
  420. package/tests/py/unit/fixtures/adatom.py +0 -60
  421. package/tests/py/unit/fixtures/bulk.py +0 -162
  422. package/tests/py/unit/fixtures/cuts.py +0 -118
  423. package/tests/py/unit/fixtures/grain_boundary.py +0 -875
  424. package/tests/py/unit/fixtures/interface/commensurate.py +0 -498
  425. package/tests/py/unit/fixtures/interface/gaas_dia.py +0 -837
  426. package/tests/py/unit/fixtures/interface/gr_ni_111_top_hcp.py +0 -123
  427. package/tests/py/unit/fixtures/interface/simple.py +0 -84
  428. package/tests/py/unit/fixtures/interface/twisted_nanoribbons.py +0 -131
  429. package/tests/py/unit/fixtures/interface/zsl.py +0 -756
  430. package/tests/py/unit/fixtures/island.py +0 -336
  431. package/tests/py/unit/fixtures/merge.py +0 -147
  432. package/tests/py/unit/fixtures/monolayer.py +0 -46
  433. package/tests/py/unit/fixtures/nanoparticle.py +0 -116
  434. package/tests/py/unit/fixtures/nanoribbon/__init__.py +0 -0
  435. package/tests/py/unit/fixtures/nanoribbon/armchair.py +0 -102
  436. package/tests/py/unit/fixtures/nanoribbon/nanoribbon.py +0 -145
  437. package/tests/py/unit/fixtures/nanoribbon/zigzag.py +0 -54
  438. package/tests/py/unit/fixtures/pair_defects.py +0 -41
  439. package/tests/py/unit/fixtures/passivated/nanoribbon.py +0 -69
  440. package/tests/py/unit/fixtures/passivated/slab.py +0 -58
  441. package/tests/py/unit/fixtures/point_defects.py +0 -158
  442. package/tests/py/unit/fixtures/slab.py +0 -606
  443. package/tests/py/unit/fixtures/strain.py +0 -42
  444. package/tests/py/unit/fixtures/supercell.py +0 -64
  445. package/tests/py/unit/fixtures/terrace.py +0 -70
  446. package/tests/py/unit/fixtures/thrid_party/ase_atoms.py +0 -13
  447. package/tests/py/unit/test_analyze_lattice_planes.py +0 -131
  448. package/tests/py/unit/test_cell.py +0 -104
  449. package/tests/py/unit/test_data_files.py +0 -68
  450. package/tests/py/unit/test_lattice.py +0 -103
  451. package/tests/py/unit/test_lattice_type_extended.py +0 -53
  452. package/tests/py/unit/test_material.py +0 -158
  453. package/tests/py/unit/test_operations.py +0 -126
  454. package/tests/py/unit/test_primitive_cell.py +0 -118
  455. package/tests/py/unit/test_reciprocal_lattice.py +0 -86
  456. package/tests/py/unit/test_reciprocal_paths.py +0 -64
  457. package/tests/py/unit/test_symmetry_points.py +0 -151
  458. package/tests/py/unit/test_tools_analyze.py +0 -219
  459. package/tests/py/unit/test_tools_analyze_basis.py +0 -105
  460. package/tests/py/unit/test_tools_analyze_interface.py +0 -223
  461. package/tests/py/unit/test_tools_analyze_interface_material.py +0 -63
  462. package/tests/py/unit/test_tools_analyze_interface_zsl.py +0 -187
  463. package/tests/py/unit/test_tools_analyze_lattice.py +0 -74
  464. package/tests/py/unit/test_tools_analyze_swap.py +0 -80
  465. package/tests/py/unit/test_tools_build.py +0 -158
  466. package/tests/py/unit/test_tools_build_defect/__init__.py +0 -0
  467. package/tests/py/unit/test_tools_build_defect/test_adatom.py +0 -84
  468. package/tests/py/unit/test_tools_build_defect/test_island.py +0 -45
  469. package/tests/py/unit/test_tools_build_defect/test_pair_defect.py +0 -84
  470. package/tests/py/unit/test_tools_build_defect/test_point_defect.py +0 -196
  471. package/tests/py/unit/test_tools_build_defect/test_slab_stack.py +0 -30
  472. package/tests/py/unit/test_tools_build_defect/test_solid_solution.py +0 -90
  473. package/tests/py/unit/test_tools_build_defect/test_terrace.py +0 -44
  474. package/tests/py/unit/test_tools_build_grain_boundary.py +0 -133
  475. package/tests/py/unit/test_tools_build_heterostructure.py +0 -46
  476. package/tests/py/unit/test_tools_build_interface.py +0 -292
  477. package/tests/py/unit/test_tools_build_interface_zsl.py +0 -263
  478. package/tests/py/unit/test_tools_build_maxwell_disorder.py +0 -123
  479. package/tests/py/unit/test_tools_build_metadata.py +0 -79
  480. package/tests/py/unit/test_tools_build_monolayer.py +0 -33
  481. package/tests/py/unit/test_tools_build_nanoparticle.py +0 -42
  482. package/tests/py/unit/test_tools_build_nanoribbon.py +0 -45
  483. package/tests/py/unit/test_tools_build_passivation.py +0 -85
  484. package/tests/py/unit/test_tools_build_perturbation.py +0 -103
  485. package/tests/py/unit/test_tools_build_slab.py +0 -382
  486. package/tests/py/unit/test_tools_build_strain.py +0 -36
  487. package/tests/py/unit/test_tools_build_supercell.py +0 -47
  488. package/tests/py/unit/test_tools_calculate.py +0 -67
  489. package/tests/py/unit/test_tools_convert.py +0 -174
  490. package/tests/py/unit/test_tools_modify.py +0 -248
  491. package/tests/py/unit/utils.py +0 -142
  492. package/tsconfig-transpile.json +0 -3
  493. package/tsconfig.json +0 -3
@@ -1,151 +0,0 @@
1
- """Tests for Brillouin zone symmetry points."""
2
-
3
- import pytest
4
- from mat3ra.made.lattice import Lattice
5
- from mat3ra.made.reciprocal.symmetry_points import get_symmetry_points
6
- from mat3ra.utils import assertion as assertion_utils
7
-
8
-
9
- def test_symmetry_points_gamma_always_first():
10
- """Gamma point should always be the first symmetry point."""
11
- lattice = Lattice(a=1.0, b=1.0, c=1.0, type="CUB")
12
- points = get_symmetry_points(lattice)
13
- assert points[0]["point"] == "Γ"
14
- assert points[0]["coordinates"] == [0.0, 0.0, 0.0]
15
-
16
-
17
- def test_symmetry_points_cub():
18
- lattice = Lattice(a=5.64, b=5.64, c=5.64, type="CUB")
19
- points = get_symmetry_points(lattice)
20
- labels = [p["point"] for p in points]
21
- assert labels == ["Γ", "R", "X", "M"]
22
- # Verify specific coordinates
23
- r_point = next(p for p in points if p["point"] == "R")
24
- assertion_utils.assert_deep_almost_equal(r_point["coordinates"], [0.5, 0.5, 0.5])
25
- x_point = next(p for p in points if p["point"] == "X")
26
- assertion_utils.assert_deep_almost_equal(x_point["coordinates"], [0.0, 0.5, 0.0])
27
- m_point = next(p for p in points if p["point"] == "M")
28
- assertion_utils.assert_deep_almost_equal(m_point["coordinates"], [0.5, 0.5, 0.0])
29
-
30
-
31
- def test_symmetry_points_fcc():
32
- lattice = Lattice(a=5.43, b=5.43, c=5.43, type="FCC")
33
- points = get_symmetry_points(lattice)
34
- labels = [p["point"] for p in points]
35
- assert "K" in labels
36
- assert "L" in labels
37
- assert "U" in labels
38
- assert "W" in labels
39
- assert "X" in labels
40
- k_point = next(p for p in points if p["point"] == "K")
41
- assertion_utils.assert_deep_almost_equal(k_point["coordinates"], [3 / 8, 3 / 8, 3 / 4])
42
-
43
-
44
- def test_symmetry_points_bcc():
45
- lattice = Lattice(a=3.0, b=3.0, c=3.0, type="BCC")
46
- points = get_symmetry_points(lattice)
47
- labels = [p["point"] for p in points]
48
- assert labels == ["Γ", "H", "P", "N"]
49
- h_point = next(p for p in points if p["point"] == "H")
50
- assertion_utils.assert_deep_almost_equal(h_point["coordinates"], [0.5, -0.5, 0.5])
51
-
52
-
53
- def test_symmetry_points_hex():
54
- lattice = Lattice(a=2.46, b=2.46, c=6.71, type="HEX")
55
- points = get_symmetry_points(lattice)
56
- labels = [p["point"] for p in points]
57
- assert set(labels) == {"Γ", "A", "H", "K", "L", "M"}
58
- k_point = next(p for p in points if p["point"] == "K")
59
- assertion_utils.assert_deep_almost_equal(k_point["coordinates"], [1 / 3, 1 / 3, 0.0])
60
-
61
-
62
- def test_symmetry_points_bct1():
63
- """BCT with c < a should give BCT-1 points."""
64
- lattice = Lattice(a=4.0, b=4.0, c=2.0, type="BCT")
65
- points = get_symmetry_points(lattice)
66
- labels = [p["point"] for p in points]
67
- assert "Z" in labels
68
- assert "Z1" in labels
69
- # BCT-1: n = (1 + c²/a²) / 4 = (1 + 4/16) / 4 = 1.25/4 = 0.3125
70
- z_point = next(p for p in points if p["point"] == "Z")
71
- n = (1 + 4.0 / 16.0) / 4
72
- assertion_utils.assert_deep_almost_equal(z_point["coordinates"], [n, n, -n])
73
-
74
-
75
- def test_symmetry_points_bct2():
76
- """BCT with c >= a should give BCT-2 points."""
77
- lattice = Lattice(a=2.0, b=2.0, c=4.0, type="BCT")
78
- points = get_symmetry_points(lattice)
79
- labels = [p["point"] for p in points]
80
- assert "∑" in labels
81
- assert "Y" in labels
82
- assert "Z" not in [p["point"] for p in points if p["point"] == "Z1"]
83
-
84
-
85
- def test_symmetry_points_tet():
86
- lattice = Lattice(a=3.0, b=3.0, c=5.0, type="TET")
87
- points = get_symmetry_points(lattice)
88
- labels = [p["point"] for p in points]
89
- assert set(labels) == {"Γ", "A", "M", "R", "X", "Z"}
90
-
91
-
92
- def test_symmetry_points_orc():
93
- lattice = Lattice(a=2.0, b=3.0, c=4.0, type="ORC")
94
- points = get_symmetry_points(lattice)
95
- labels = [p["point"] for p in points]
96
- assert set(labels) == {"Γ", "R", "S", "T", "U", "X", "Y", "Z"}
97
-
98
-
99
- def test_symmetry_points_rhl1():
100
- """RHL with cos(alpha) > 0 should give RHL-1 points."""
101
- lattice = Lattice(a=3.0, b=3.0, c=3.0, alpha=60.0, beta=60.0, gamma=60.0, type="RHL")
102
- points = get_symmetry_points(lattice)
103
- labels = [p["point"] for p in points]
104
- assert "B" in labels
105
- assert "B1" in labels
106
- assert "F" in labels
107
-
108
-
109
- def test_symmetry_points_rhl2():
110
- """RHL with cos(alpha) < 0 should give RHL-2 points."""
111
- lattice = Lattice(a=3.0, b=3.0, c=3.0, alpha=120.0, beta=120.0, gamma=120.0, type="RHL")
112
- points = get_symmetry_points(lattice)
113
- labels = [p["point"] for p in points]
114
- assert "Q" in labels
115
- assert "Q1" in labels
116
- # RHL-2 should NOT have B, B1 points
117
- assert "B" not in labels
118
-
119
-
120
- def test_symmetry_points_tri_1a():
121
- """TRI with alpha, beta > 90 and gamma >= 90."""
122
- lattice = Lattice(a=1.0, b=2.0, c=3.0, alpha=95.0, beta=100.0, gamma=110.0, type="TRI")
123
- points = get_symmetry_points(lattice)
124
- # TRI-1a,2a: L at [1/2, 1/2, 0]
125
- l_point = next(p for p in points if p["point"] == "L")
126
- assertion_utils.assert_deep_almost_equal(l_point["coordinates"], [0.5, 0.5, 0.0])
127
-
128
-
129
- def test_symmetry_points_tri_1b():
130
- """TRI without all angles > 90."""
131
- lattice = Lattice(a=1.0, b=2.0, c=3.0, alpha=80.0, beta=85.0, gamma=75.0, type="TRI")
132
- points = get_symmetry_points(lattice)
133
- # TRI-1b,2b: L at [1/2, -1/2, 0]
134
- l_point = next(p for p in points if p["point"] == "L")
135
- assertion_utils.assert_deep_almost_equal(l_point["coordinates"], [0.5, -0.5, 0.0])
136
-
137
-
138
- @pytest.mark.parametrize(
139
- "lattice_type",
140
- ["CUB", "FCC", "BCC", "TET", "BCT", "ORC", "ORCF", "ORCI", "ORCC", "HEX", "RHL", "MCL", "MCLC", "TRI"],
141
- )
142
- def test_symmetry_points_all_lattice_types(lattice_type):
143
- """Every supported lattice type should return at least the Gamma point."""
144
- lattice = Lattice(a=3.0, b=4.0, c=5.0, alpha=80.0, beta=85.0, gamma=75.0, type=lattice_type)
145
- points = get_symmetry_points(lattice)
146
- assert len(points) >= 1
147
- assert points[0]["point"] == "Γ"
148
- # All coordinates should be lists of 3 floats
149
- for p in points:
150
- assert len(p["coordinates"]) == 3
151
- assert all(isinstance(c, (int, float)) for c in p["coordinates"])
@@ -1,219 +0,0 @@
1
- import numpy as np
2
- import pytest
3
- from mat3ra.made.material import Material, defaultMaterialConfig
4
- from mat3ra.made.tools.analyze.crystal_site.adatom_crystal_site_material_analyzer import (
5
- AdatomCrystalSiteMaterialAnalyzer,
6
- )
7
- from mat3ra.made.tools.analyze.crystal_site.adatom_material_analyzer import AdatomMaterialAnalyzer
8
- from mat3ra.made.tools.analyze.crystal_site.crystal_site_analyzer import CrystalSiteAnalyzer
9
- from mat3ra.made.tools.analyze.crystal_site.voronoi_crystal_site_analyzer import VoronoiCrystalSiteAnalyzer
10
- from mat3ra.made.tools.analyze.other import (
11
- SurfaceTypesEnum,
12
- get_average_interlayer_distance,
13
- get_surface_area,
14
- get_surface_atom_indices,
15
- )
16
- from mat3ra.made.tools.analyze.rdf import RadialDistributionFunction
17
- from mat3ra.made.tools.analyze.utils import calculate_von_mises_strain
18
- from mat3ra.made.tools.build import MaterialWithBuildMetadata
19
- from mat3ra.made.tools.build.defective_structures.zero_dimensional.point_defect.atom_placement_method_enum import (
20
- AtomPlacementMethodEnum,
21
- )
22
- from mat3ra.made.tools.build_components.operations.core.combinations.enums import AdatomPlacementMethodEnum
23
- from unit.fixtures.nanoribbon.nanoribbon import GRAPHENE_ZIGZAG_NANORIBBON
24
- from unit.utils import OSPlatform, get_platform_specific_value
25
-
26
- from .fixtures.bulk import BULK_Si_CONVENTIONAL, BULK_Si_PRIMITIVE
27
- from .fixtures.interface.zsl import GRAPHENE_NICKEL_INTERFACE
28
- from .fixtures.slab import SI_CONVENTIONAL_SLAB_001
29
-
30
- COMPARISON_PRECISION = 1e-4
31
-
32
-
33
- @pytest.mark.parametrize(
34
- "material_config, layer_indices, expected_distance",
35
- [
36
- (GRAPHENE_NICKEL_INTERFACE, [0, 1], 3.0),
37
- ],
38
- )
39
- def test_calculate_average_interlayer_distance(material_config, layer_indices, expected_distance):
40
- material = Material.create(material_config)
41
- distance = get_average_interlayer_distance(material, *layer_indices)
42
- assert np.isclose(distance, expected_distance)
43
-
44
-
45
- @pytest.mark.parametrize(
46
- "material_config, expected_area",
47
- [
48
- (defaultMaterialConfig, 12.950),
49
- ],
50
- )
51
- def test_calculate_surface_area(material_config, expected_area):
52
- material = Material.create(material_config)
53
- area = get_surface_area(material)
54
- assert np.isclose(area, expected_area, atol=1e-3)
55
-
56
-
57
- @pytest.mark.parametrize(
58
- "material_config, rdf_params, expected_first_peak_distance",
59
- [
60
- (GRAPHENE_ZIGZAG_NANORIBBON, {"cutoff": 10.0, "bin_size": 0.1}, 1.42),
61
- (BULK_Si_CONVENTIONAL, {"cutoff": 10.0, "bin_size": 0.1}, 2.35),
62
- ],
63
- )
64
- def test_radial_distribution_function(material_config, rdf_params, expected_first_peak_distance):
65
- material = Material.create(material_config)
66
-
67
- rdf = RadialDistributionFunction.from_material(material, **rdf_params)
68
-
69
- # Test that RDF is non-negative
70
- assert np.all(rdf.rdf >= 0), "RDF contains negative values."
71
-
72
- # Test the first peak properties
73
- assert rdf.first_peak_index > 0, "First peak index should be greater than 0."
74
- assert rdf.first_peak_value > 0, "First peak value should be greater than 0."
75
- assert rdf.first_peak_width > 0, "First peak width should be greater than 0."
76
- assert rdf.first_peak_distance > 0, "First peak distance should be greater than 0."
77
-
78
- # Test that `is_within_first_peak` works as expected
79
- assert rdf.is_within_first_peak(rdf.first_peak_distance), "First peak distance should be within the first peak."
80
- assert not rdf.is_within_first_peak(0), "Zero distance should not be within the first peak."
81
- assert not rdf.is_within_first_peak(rdf_params["cutoff"]), "Cutoff distance should not be within the first peak."
82
-
83
- # Test that RDF drops to zero near the cutoff
84
- assert np.isclose(rdf.rdf[-1], 0, atol=1e-2), "RDF should approach zero near the cutoff."
85
-
86
- # Specific material related tests
87
- assert np.isclose(rdf.first_peak_distance, expected_first_peak_distance, atol=0.1)
88
-
89
-
90
- VORONOI_SITE_EXPECTED = {OSPlatform.DARWIN: [0.625, 0.625, 0.125], OSPlatform.OTHER: [0.5, 0.5, 0.5]}
91
-
92
-
93
- @pytest.mark.parametrize(
94
- "placement_method, coordinate, expected_coordinate",
95
- [
96
- (AtomPlacementMethodEnum.EXACT_COORDINATE, [0.25, 0.25, 0.5], [0.25, 0.25, 0.5]),
97
- (AtomPlacementMethodEnum.CLOSEST_SITE, [0.25, 0.25, 0.5], [0.25, 0.25, 0.25]),
98
- (AtomPlacementMethodEnum.EQUIDISTANT, [0.5432, 0.5123, 0.5], [0.58333, 0.58333, 0.25]),
99
- (AtomPlacementMethodEnum.VORONOI_SITE, [0.25, 0.25, 0.5], VORONOI_SITE_EXPECTED),
100
- ],
101
- )
102
- def test_crystal_site_analyzer(placement_method, coordinate, expected_coordinate):
103
- crystal = Material.create(BULK_Si_PRIMITIVE)
104
-
105
- if placement_method == AtomPlacementMethodEnum.VORONOI_SITE:
106
- analyzer = VoronoiCrystalSiteAnalyzer(material=crystal, coordinate=coordinate)
107
- final_coordinate = analyzer.voronoi_site_coordinate
108
- expected_coordinate = get_platform_specific_value(expected_coordinate)
109
- else:
110
- analyzer = CrystalSiteAnalyzer(material=crystal, coordinate=coordinate)
111
- if placement_method == AtomPlacementMethodEnum.EXACT_COORDINATE:
112
- final_coordinate = analyzer.exact_coordinate
113
- elif placement_method == AtomPlacementMethodEnum.CLOSEST_SITE:
114
- final_coordinate = analyzer.closest_site_coordinate
115
- elif placement_method == AtomPlacementMethodEnum.EQUIDISTANT:
116
- final_coordinate = analyzer.get_equidistant_coordinate()
117
- else:
118
- raise ValueError(f"Unknown method: {placement_method}")
119
-
120
- if placement_method == AtomPlacementMethodEnum.VORONOI_SITE:
121
- allowed_coords = [[0.625, 0.625, 0.125], [0.625, 0.625, 0.625], [0.5, 0.5, 0.5]]
122
- assert any(
123
- np.allclose(final_coordinate, allowed, atol=COMPARISON_PRECISION) for allowed in allowed_coords
124
- ), f"Voronoi coordinate {final_coordinate} not in allowed list"
125
- else:
126
- assert np.allclose(final_coordinate, expected_coordinate, atol=COMPARISON_PRECISION)
127
-
128
-
129
- @pytest.mark.parametrize(
130
- "material_config, coordinate, placement_method, distance_z, element, expected_coordinate",
131
- [
132
- (
133
- SI_CONVENTIONAL_SLAB_001,
134
- [0.25, 0.25],
135
- AdatomPlacementMethodEnum.EXACT_COORDINATE,
136
- 1.0,
137
- "Si",
138
- [0.25, 0.25, 0.1828],
139
- ),
140
- ],
141
- )
142
- def test_adatom_material_analyzer(
143
- material_config, coordinate, placement_method, distance_z, element, expected_coordinate
144
- ):
145
- crystal = MaterialWithBuildMetadata.create(material_config)
146
-
147
- analyzer = AdatomMaterialAnalyzer(
148
- material=crystal, coordinate_2d=coordinate, distance_z=distance_z, element=element
149
- )
150
- resolved_coord = analyzer.coordinate_in_added_component
151
-
152
- assert np.allclose(resolved_coord, expected_coordinate, atol=COMPARISON_PRECISION)
153
-
154
-
155
- @pytest.mark.parametrize(
156
- "material_config, coordinate, placement_method, distance_z, element,expected_coordinate",
157
- [
158
- (
159
- SI_CONVENTIONAL_SLAB_001,
160
- [0.25, 0.25],
161
- AdatomPlacementMethodEnum.NEW_CRYSTAL_SITE,
162
- 1.0,
163
- "Si",
164
- [0.25, 0.25, 0.5],
165
- ),
166
- ],
167
- )
168
- def test_adatom_crystal_site_material_analyzer(
169
- material_config, coordinate, placement_method, distance_z, element, expected_coordinate
170
- ):
171
- crystal = MaterialWithBuildMetadata.create(material_config)
172
-
173
- # Test NEW_CRYSTAL_SITE method
174
- analyzer = AdatomCrystalSiteMaterialAnalyzer(
175
- material=crystal,
176
- coordinate_2d=coordinate,
177
- distance_z=distance_z,
178
- element=element,
179
- )
180
- resolved_coord = analyzer.coordinate_in_added_component
181
-
182
- assert np.allclose(resolved_coord, expected_coordinate, atol=COMPARISON_PRECISION)
183
-
184
-
185
- @pytest.mark.parametrize(
186
- "material_config, expected_indices_top, expected_indices_bottom",
187
- [
188
- (
189
- SI_CONVENTIONAL_SLAB_001,
190
- [8, 14],
191
- [3, 4, 5],
192
- ),
193
- ],
194
- )
195
- def test_get_surface_atom_indices_top_and_bottom(material_config, expected_indices_top, expected_indices_bottom):
196
- material = Material.create(material_config)
197
- top_indices = get_surface_atom_indices(material, SurfaceTypesEnum.TOP)
198
- bottom_indices = get_surface_atom_indices(material, SurfaceTypesEnum.BOTTOM)
199
- assert set(top_indices) == set(expected_indices_top)
200
- assert set(bottom_indices) == set(expected_indices_bottom)
201
-
202
-
203
- @pytest.mark.parametrize(
204
- "strain_matrix, expected_strain",
205
- [
206
- # Identity matrix - no strain
207
- ([[1.0, 0.0, 0.0], [0.0, 1.0, 0.0], [0.0, 0.0, 1.0]], 0.0),
208
- # Uniaxial compression (5% x only)
209
- ([[0.95, 0.0, 0.0], [0.0, 1.0, 0.0], [0.0, 0.0, 1.0]], 4.875),
210
- # Biaxial compression (5% x and y)
211
- ([[0.95, 0.0, 0.0], [0.0, 0.95, 0.0], [0.0, 0.0, 1.0]], 4.875),
212
- # Shear strain
213
- ([[1.0, 0.1, 0.0], [0.0, 1.0, 0.0], [0.0, 0.0, 1.0]], 8.675),
214
- ],
215
- )
216
- def test_calculate_von_mises_strain(strain_matrix, expected_strain):
217
- """Test von Mises strain calculation used in ZSL interface analysis."""
218
- strain_percentage = calculate_von_mises_strain(np.array(strain_matrix))
219
- assert np.isclose(strain_percentage, expected_strain, atol=0.01)
@@ -1,105 +0,0 @@
1
- import pytest
2
- from mat3ra.esse.models.core.reusable.axis_enum import AxisEnum
3
- from mat3ra.made.material import Material
4
- from mat3ra.made.tools.analyze.basis import BasisMaterialAnalyzer
5
- from mat3ra.made.tools.analyze.fingerprint import LayeredFingerprintAlongAxis
6
- from mat3ra.made.tools.operations.core.unary import supercell
7
-
8
- from .fixtures.bulk import BULK_Si_CONVENTIONAL
9
- from .fixtures.slab import SI_CONVENTIONAL_SLAB_001, SLAB_SrTiO3_011_TERMINATION_O2, SLAB_SrTiO3_011_TERMINATION_SrTiO
10
-
11
-
12
- @pytest.mark.parametrize(
13
- "material_config",
14
- [SLAB_SrTiO3_011_TERMINATION_O2, SLAB_SrTiO3_011_TERMINATION_SrTiO, SI_CONVENTIONAL_SLAB_001],
15
- )
16
- def test_basis_analyzer_fingerprint(material_config):
17
- material = Material.create(material_config)
18
- analyzer = BasisMaterialAnalyzer(material=material)
19
-
20
- fingerprint = analyzer.get_layer_fingerprint(layer_thickness=1.0)
21
- assert isinstance(fingerprint, LayeredFingerprintAlongAxis)
22
- assert len(fingerprint.layers) > 0
23
- assert fingerprint.axis == AxisEnum.z
24
- assert fingerprint.layer_thickness == 1.0
25
-
26
- for layer in fingerprint.layers:
27
- assert hasattr(layer, "min_coord")
28
- assert hasattr(layer, "max_coord")
29
- assert hasattr(layer, "elements")
30
- assert isinstance(layer.min_coord, float)
31
- assert isinstance(layer.max_coord, float)
32
- assert layer.max_coord > layer.min_coord
33
- assert isinstance(layer.elements, list)
34
- assert all(isinstance(elem, str) for elem in layer.elements)
35
-
36
- non_empty_layers = fingerprint.non_empty_layers
37
- assert isinstance(non_empty_layers, list)
38
- assert all(isinstance(layer, type(fingerprint.layers[0])) for layer in non_empty_layers)
39
-
40
- element_sequence = fingerprint.element_sequence
41
- assert isinstance(element_sequence, list)
42
- assert all(isinstance(elements, list) for elements in element_sequence)
43
-
44
-
45
- @pytest.mark.parametrize(
46
- "material_config, layer_thickness",
47
- [
48
- (BULK_Si_CONVENTIONAL, 1.0),
49
- (SI_CONVENTIONAL_SLAB_001, 1.0),
50
- (SLAB_SrTiO3_011_TERMINATION_O2, 0.5),
51
- ],
52
- )
53
- def test_get_layer_fingerprint(material_config, layer_thickness):
54
- material = Material.create(material_config)
55
- analyzer = BasisMaterialAnalyzer(material=material)
56
-
57
- fingerprint = analyzer.get_layer_fingerprint(layer_thickness=layer_thickness)
58
- assert isinstance(fingerprint, LayeredFingerprintAlongAxis)
59
- assert len(fingerprint.layers) > 0
60
- assert fingerprint.axis == AxisEnum.z
61
- assert fingerprint.layer_thickness == layer_thickness
62
-
63
- for axis in [AxisEnum.x, AxisEnum.y, AxisEnum.z]:
64
- fingerprint = analyzer.get_layer_fingerprint(layer_thickness=layer_thickness, axis=axis)
65
- assert isinstance(fingerprint, LayeredFingerprintAlongAxis)
66
- assert fingerprint.axis == axis
67
- assert fingerprint.layer_thickness == layer_thickness
68
- assert len(fingerprint.layers) > 0
69
-
70
-
71
- @pytest.mark.parametrize(
72
- "material_config, supercell_matrix, repetition_axis",
73
- [
74
- (SLAB_SrTiO3_011_TERMINATION_O2, [[2, 0, 0], [0, 2, 0], [0, 0, 1]], AxisEnum.y),
75
- (SLAB_SrTiO3_011_TERMINATION_SrTiO, [[2, 0, 0], [0, 2, 0], [0, 0, 1]], AxisEnum.y),
76
- (SI_CONVENTIONAL_SLAB_001, [[2, 0, 0], [0, 2, 0], [0, 0, 1]], AxisEnum.x),
77
- ],
78
- )
79
- def test_fingerprint_similarity_scores(material_config, supercell_matrix, repetition_axis):
80
- slab = Material.create(material_config)
81
- supercell_material = supercell(slab, supercell_matrix)
82
-
83
- analyzer_slab = BasisMaterialAnalyzer(material=slab)
84
- analyzer_supercell = BasisMaterialAnalyzer(material=supercell_material)
85
-
86
- layer_thickness = 1.0
87
-
88
- fingerprint_slab = analyzer_slab.get_layer_fingerprint(layer_thickness=layer_thickness, axis=repetition_axis)
89
- fingerprint_supercell = analyzer_supercell.get_layer_fingerprint(
90
- layer_thickness=layer_thickness, axis=repetition_axis
91
- )
92
-
93
- assert fingerprint_slab.get_similarity_score(fingerprint_supercell) == 0.0
94
-
95
- score_periodic = fingerprint_slab.get_similarity_score_ignore_periodicity(fingerprint_supercell)
96
- assert score_periodic > 0.0
97
- assert len(fingerprint_supercell.layers) % len(fingerprint_slab.layers) == 0
98
-
99
- assert fingerprint_supercell.get_similarity_score_ignore_periodicity(fingerprint_slab) > 0.0
100
-
101
- fingerprint_slab_z = analyzer_slab.get_layer_fingerprint(layer_thickness=layer_thickness, axis=AxisEnum.z)
102
- fingerprint_supercell_z = analyzer_supercell.get_layer_fingerprint(layer_thickness=layer_thickness, axis=AxisEnum.z)
103
-
104
- assert len(fingerprint_slab_z.layers) == len(fingerprint_supercell_z.layers)
105
- assert fingerprint_slab_z.get_similarity_score(fingerprint_supercell_z) == 1.0