mlatom 3.18.2__tar.gz → 3.19.0__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 (169) hide show
  1. {mlatom-3.18.2/src/mlatom.egg-info → mlatom-3.19.0}/PKG-INFO +4 -13
  2. {mlatom-3.18.2 → mlatom-3.19.0}/README.md +3 -3
  3. {mlatom-3.18.2 → mlatom-3.19.0}/setup.py +1 -1
  4. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/EEEDDDD.py +15 -4
  5. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/MLTPA.py +50 -2
  6. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/MLatom.py +4 -6
  7. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/MLtasks.py +63 -20
  8. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/__init__.py +3 -3
  9. mlatom-3.19.0/src/mlatom/addons/aiqm3/aiqm3.py +47 -0
  10. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/aiqm1.py +19 -14
  11. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/aiqm2.py +75 -26
  12. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/args_class.py +11 -0
  13. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/data.py +53 -7
  14. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/fortran/KREG.f90 +95 -3
  15. mlatom-3.19.0/src/mlatom/fortran/np1/KREG.so +0 -0
  16. mlatom-3.19.0/src/mlatom/fortran/np2/KREG.so +0 -0
  17. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/gen_ts_methods.py +9 -2
  18. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/header.py +25 -5
  19. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/interfaces/aimnet2_interface.py +24 -27
  20. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/interfaces/dftd4_interface.py +1 -1
  21. mlatom-3.19.0/src/mlatom/interfaces/gaussian_interface.py +1163 -0
  22. mlatom-3.19.0/src/mlatom/interfaces/geometric_interface.py +204 -0
  23. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/interfaces/mace_interface.py +2 -1
  24. mlatom-3.19.0/src/mlatom/interfaces/mace_methods_interface.py +86 -0
  25. mlatom-3.19.0/src/mlatom/interfaces/mndo_interface.py +481 -0
  26. mlatom-3.19.0/src/mlatom/interfaces/pysisyphus_interface.py +194 -0
  27. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/interfaces/torchani_interface.py +30 -4
  28. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/interfaces/xtb_interface.py +27 -37
  29. mlatom-3.19.0/src/mlatom/irc.py +825 -0
  30. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/kreg_api.py +15 -3
  31. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/md.py +2 -1
  32. mlatom-3.19.0/src/mlatom/mlatom_models/aiqm1_model/__init__.py +0 -0
  33. mlatom-3.19.0/src/mlatom/mlatom_models/aiqm2_model/__init__.py +0 -0
  34. mlatom-3.19.0/src/mlatom/mltpa/__init__.py +0 -0
  35. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/model_cls.py +107 -111
  36. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/models.py +5 -2
  37. mlatom-3.19.0/src/mlatom/omnip1.py +112 -0
  38. mlatom-3.19.0/src/mlatom/omnip1_nn.py +140 -0
  39. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/ref.json +5 -1
  40. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/shell_cmd.py +4 -4
  41. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/simulations.py +47 -133
  42. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/spectra.py +45 -0
  43. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/thermostat.py +25 -8
  44. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/utils.py +48 -0
  45. {mlatom-3.18.2 → mlatom-3.19.0/src/mlatom.egg-info}/PKG-INFO +4 -13
  46. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom.egg-info/SOURCES.txt +12 -1
  47. mlatom-3.18.2/src/mlatom/fortran/KREG.so +0 -0
  48. mlatom-3.18.2/src/mlatom/interfaces/gaussian_interface.py +0 -1035
  49. mlatom-3.18.2/src/mlatom/interfaces/mndo_interface.py +0 -423
  50. {mlatom-3.18.2 → mlatom-3.19.0}/LICENSE.txt +0 -0
  51. {mlatom-3.18.2 → mlatom-3.19.0}/setup.cfg +0 -0
  52. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/EEEDDDD_descriptor.py +0 -0
  53. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/EEEDDDD_nn.py +0 -0
  54. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/GICnet.py +0 -0
  55. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/ML_NEA.py +0 -0
  56. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/MLatomF +0 -0
  57. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/MLatomF_src/A_KRR.f90 +0 -0
  58. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/MLatomF_src/A_KRR_kernel.f90 +0 -0
  59. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/MLatomF_src/D_CoulombMatrix.f90 +0 -0
  60. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/MLatomF_src/D_ID.f90 +0 -0
  61. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/MLatomF_src/D_rel2eq.f90 +0 -0
  62. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/MLatomF_src/MLatomF.f90 +0 -0
  63. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/MLatomF_src/MLatomFInfo.f90 +0 -0
  64. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/MLatomF_src/MLmodel.f90 +0 -0
  65. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/MLatomF_src/Makefile +0 -0
  66. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/MLatomF_src/Makefile.intel +0 -0
  67. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/MLatomF_src/__init__.py +0 -0
  68. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/MLatomF_src/analyze.f90 +0 -0
  69. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/MLatomF_src/constants.f90 +0 -0
  70. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/MLatomF_src/cs.cpp +0 -0
  71. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/MLatomF_src/dataset.f90 +0 -0
  72. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/MLatomF_src/mathUtils.f90 +0 -0
  73. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/MLatomF_src/molDescr.f90 +0 -0
  74. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/MLatomF_src/optionsModule.f90 +0 -0
  75. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/MLatomF_src/precision.f90 +0 -0
  76. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/MLatomF_src/recover.sh +0 -0
  77. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/MLatomF_src/sampling.f90 +0 -0
  78. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/MLatomF_src/statistics.f90 +0 -0
  79. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/MLatomF_src/stopper.f90 +0 -0
  80. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/MLatomF_src/strings.f90 +0 -0
  81. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/MLatomF_src/timing.f90 +0 -0
  82. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/MLatomF_src/types.f90 +0 -0
  83. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/addons/__init__.py +0 -0
  84. {mlatom-3.18.2/src/mlatom/addons/omnip2x → mlatom-3.19.0/src/mlatom/addons/aiqm3}/__init__.py +0 -0
  85. {mlatom-3.18.2/src/mlatom/addons/uaiqm → mlatom-3.19.0/src/mlatom/addons/omnip2x}/__init__.py +0 -0
  86. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/addons/omnip2x/omnip2x.py +0 -0
  87. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/addons/omnip2x/vecmsani.py +0 -0
  88. {mlatom-3.18.2/src/mlatom/fortran → mlatom-3.19.0/src/mlatom/addons/uaiqm}/__init__.py +0 -0
  89. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/addons/uaiqm/uaiqm.py +0 -0
  90. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/al.py +0 -0
  91. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/al_utils.py +0 -0
  92. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/ccsdtstarcbs.py +0 -0
  93. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/composite_methods.py +0 -0
  94. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/constants.py +0 -0
  95. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/conversions.py +0 -0
  96. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/cs.so +0 -0
  97. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/decorators.py +0 -0
  98. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/dens.py +0 -0
  99. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/doc.py +0 -0
  100. {mlatom-3.18.2/src/mlatom/interfaces → mlatom-3.19.0/src/mlatom/fortran}/__init__.py +0 -0
  101. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/fortran/compile.py +0 -0
  102. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/fortran/mathUtils.f90 +0 -0
  103. {mlatom-3.18.2/src/mlatom/julia → mlatom-3.19.0/src/mlatom/fortran/np1}/__init__.py +0 -0
  104. {mlatom-3.18.2/src/mlatom/mlatom_models → mlatom-3.19.0/src/mlatom/fortran/np2}/__init__.py +0 -0
  105. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/fortran/stopper.f90 +0 -0
  106. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/functionsGICnet.py +0 -0
  107. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/gap_md.py +0 -0
  108. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/initial_conditions.py +0 -0
  109. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/interface_MLatomF.py +0 -0
  110. {mlatom-3.18.2/src/mlatom/mlatom_models/aiqm1_model → mlatom-3.19.0/src/mlatom/interfaces}/__init__.py +0 -0
  111. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/interfaces/ase_interface.py +0 -0
  112. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/interfaces/columbus_interface.py +0 -0
  113. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/interfaces/dftbplus_interface.py +0 -0
  114. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/interfaces/dftd3_interface.py +0 -0
  115. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/interfaces/dpmd_interface.py +0 -0
  116. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/interfaces/gap_interface.py +0 -0
  117. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/interfaces/gaussian_external.py +0 -0
  118. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/interfaces/orca_interface.py +0 -0
  119. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/interfaces/physnet_interface.py +0 -0
  120. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/interfaces/pyscf_interface.py +0 -0
  121. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/interfaces/sgdml_interface.py +0 -0
  122. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/interfaces/sparrow_interface.py +0 -0
  123. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/interfaces/torchani_heavy_parts.py +0 -0
  124. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/interfaces/turbomole_interface.py +0 -0
  125. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/interfaces/xtb +0 -0
  126. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/julia/KREG.jl +0 -0
  127. {mlatom-3.18.2/src/mlatom/mlatom_models/aiqm2_model → mlatom-3.19.0/src/mlatom/julia}/__init__.py +0 -0
  128. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/julia/kernel_function.jl +0 -0
  129. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/julia/kreg_julia.py +0 -0
  130. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/julia/krr.jl +0 -0
  131. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/julia/mathUtils.jl +0 -0
  132. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/julia/stopper.jl +0 -0
  133. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/krr_julia.py +0 -0
  134. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/log.py +0 -0
  135. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/md2vibr.py +0 -0
  136. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/md2vibr_cmd.py +0 -0
  137. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/md_cmd.py +0 -0
  138. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/md_parallel.py +0 -0
  139. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/mlatom_gui.py +0 -0
  140. {mlatom-3.18.2/src/mlatom/mltpa → mlatom-3.19.0/src/mlatom/mlatom_models}/__init__.py +0 -0
  141. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/mlatom_models/aiqm1_model/cv0.pt +0 -0
  142. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/mlatom_models/aiqm1_model/cv1.pt +0 -0
  143. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/mlatom_models/aiqm1_model/cv2.pt +0 -0
  144. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/mlatom_models/aiqm1_model/cv3.pt +0 -0
  145. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/mlatom_models/aiqm1_model/cv4.pt +0 -0
  146. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/mlatom_models/aiqm1_model/cv5.pt +0 -0
  147. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/mlatom_models/aiqm1_model/cv6.pt +0 -0
  148. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/mlatom_models/aiqm1_model/cv7.pt +0 -0
  149. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/mlatom_models/aiqm2_model/cv0.pt +0 -0
  150. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/mlatom_models/aiqm2_model/cv1.pt +0 -0
  151. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/mlatom_models/aiqm2_model/cv2.pt +0 -0
  152. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/mlatom_models/aiqm2_model/cv3.pt +0 -0
  153. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/mlatom_models/aiqm2_model/cv4.pt +0 -0
  154. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/mlatom_models/aiqm2_model/cv5.pt +0 -0
  155. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/mlatom_models/aiqm2_model/cv6.pt +0 -0
  156. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/mlatom_models/aiqm2_model/cv7.pt +0 -0
  157. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/mltpa/mff.txt +0 -0
  158. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/mltpa/mltpa2022_2.pkl +0 -0
  159. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/mltpa/mltpa2022_2_new_.pkl +0 -0
  160. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/namd.py +0 -0
  161. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/plot.py +0 -0
  162. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/sliceData.py +0 -0
  163. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/stats.py +0 -0
  164. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/stopper.py +0 -0
  165. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom/xyz.py +0 -0
  166. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom.egg-info/dependency_links.txt +0 -0
  167. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom.egg-info/entry_points.txt +0 -0
  168. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom.egg-info/requires.txt +0 -0
  169. {mlatom-3.18.2 → mlatom-3.19.0}/src/mlatom.egg-info/top_level.txt +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: mlatom
3
- Version: 3.18.2
3
+ Version: 3.19.0
4
4
  Summary: A Package for AI-enhanced computational chemistry
5
5
  Home-page: http://mlatom.com
6
6
  Author: Pavlo O. Dral
@@ -14,20 +14,11 @@ Classifier: Environment :: Console
14
14
  Requires-Python: >=3.8
15
15
  Description-Content-Type: text/markdown
16
16
  License-File: LICENSE.txt
17
- Requires-Dist: numpy
18
- Requires-Dist: scipy
19
- Requires-Dist: h5py
20
- Requires-Dist: pyh5md
21
- Requires-Dist: torch
22
- Requires-Dist: torchani
23
- Requires-Dist: matplotlib
24
- Requires-Dist: statsmodels
25
- Requires-Dist: tqdm
26
17
 
27
18
  # About Program
28
19
  MLatom: a Package for Atomistic Simulations with Machine Learning
29
20
 
30
- Version 3.18.2
21
+ Version 3.19.0
31
22
 
32
23
  **Official website**: http://mlatom.com/
33
24
  **Documentation**: http://mlatom.com/docs/
@@ -56,7 +47,7 @@ When this Software or its derivatives are used in scientific publications, it sh
56
47
  * Pavlo O. Dral, Fuchun Ge, Yi-Fan Hou, Peikun Zheng, Yuxinxin Chen, Mario Barbatti, Olexandr Isayev, Cheng Wang, Bao-Xin Xue, Max Pinheiro Jr, Yuming Su, Yiheng Dai, Yangtao Chen, Lina Zhang, Shuang Zhang, Arif Ullah, Quanhao Zhang, Yanchi Ou. [MLatom 3: A Platform for Machine Learning-enhanced Computational Chemistry Simulations and Workflows](https://doi.org/10.1021/acs.jctc.3c01203). *J. Chem. Theory Comput.* **2024**, *20*, 1193--1213.
57
48
  * Pavlo O. Dral, Fuchun Ge, Bao-Xin Xue, Yi-Fan Hou, Max Pinheiro Jr, Jianxing Huang, Mario Barbatti. [MLatom 2: An Integrative Platform for Atomistic Machine Learning](http://doi.org/10.1007/s41061-021-00339-5). *Top. Curr. Chem.* **2021**, *379*, 27.
58
49
  * Pavlo O. Dral. [MLatom: A Program Package for Quantum Chemical Research Assisted by Machine Learning](http://dx.doi.org/10.1002/jcc.26004). *J. Comput. Chem.* **2019**, *40*, 2339--2347.
59
- * Pavlo O. Dral, Fuchun Ge, Yi-Fan Hou, Yuxinxin Chen, Peikun Zheng, Bao-Xin Xue, Mikolaj Martyka, Lina Zhang, Jakub Martinka, Quanhao Zhang, Xin-Yu Tong, Arif Ullah, Sebastian V. Pios, Vignesh B. Kumar, Yanchi Ou, Max Pinheiro Jr, Yuming Su, Yiheng Dai, Yangtao Chen, Shuang Zhang, Matheus O. Bispo, MLatom: A Package for Atomistic Simulations with Machine Learning, version 3.18.2, Xiamen University, Xiamen, China, 2013-2025. [MLatom.com](http://mlatom.com).
50
+ * Pavlo O. Dral, Fuchun Ge, Yi-Fan Hou, Yuxinxin Chen, Peikun Zheng, Bao-Xin Xue, Mikolaj Martyka, Lina Zhang, Jakub Martinka, Quanhao Zhang, Xin-Yu Tong, Arif Ullah, Sebastian V. Pios, Vignesh B. Kumar, Yanchi Ou, Max Pinheiro Jr, Yuming Su, Yiheng Dai, Yangtao Chen, Shuang Zhang, Jinming Hu, Matheus O. Bispo, MLatom: A Package for Atomistic Simulations with Machine Learning, version 3.19.0, Xiamen University, Xiamen, China, 2013-2025. [MLatom.com](http://mlatom.com).
60
51
 
61
52
  The citations for MLatom's interfaces and features shall be eventually
62
53
  included too. See program output, header.py, ref.json, and [MLatom.com](http://mlatom.com).
@@ -104,7 +95,7 @@ Citations mentioned above should be included. For convenience, below we provide
104
95
  }
105
96
 
106
97
  @misc{MLatomProg,
107
- author = {Dral, Pavlo O. and Ge, Fuchun and Hou, Yi-Fan and Chen, Yuxinxin and Zheng, Peikun and Xue, Bao-Xin and Martyka, Mikolaj and Zhang, Lina and Martinka, Jakub and Zhang, Quanhao and Tong, Xin-Yu and Ullah, Arif and Pios, Sebastian V. and Kumar, Vignesh B. and Ou, Yanchi and Jr, Max Pinheiro and Su, Yuming and Dai, Yiheng and Chen, Yangtao and Zhang, Shuang and Bispo, Matheus O.},
98
+ author = {Dral, Pavlo O. and Ge, Fuchun and Hou, Yi-Fan and Chen, Yuxinxin and Zheng, Peikun and Xue, Bao-Xin and Martyka, Mikolaj and Zhang, Lina and Martinka, Jakub and Zhang, Quanhao and Tong, Xin-Yu and Ullah, Arif and Pios, Sebastian V. and Kumar, Vignesh B. and Ou, Yanchi and Jr, Max Pinheiro and Su, Yuming and Dai, Yiheng and Chen, Yangtao and Zhang, Shuang and Hu, Jinming and Bispo, Matheus O.},
108
99
  title = {MLatom: A Package for Atomistic Simulations with Machine Learning},
109
100
  year = {2013--2025},
110
101
  type = {Computer Program}
@@ -1,7 +1,7 @@
1
1
  # About Program
2
2
  MLatom: a Package for Atomistic Simulations with Machine Learning
3
3
 
4
- Version 3.18.2
4
+ Version 3.19.0
5
5
 
6
6
  **Official website**: http://mlatom.com/
7
7
  **Documentation**: http://mlatom.com/docs/
@@ -30,7 +30,7 @@ When this Software or its derivatives are used in scientific publications, it sh
30
30
  * Pavlo O. Dral, Fuchun Ge, Yi-Fan Hou, Peikun Zheng, Yuxinxin Chen, Mario Barbatti, Olexandr Isayev, Cheng Wang, Bao-Xin Xue, Max Pinheiro Jr, Yuming Su, Yiheng Dai, Yangtao Chen, Lina Zhang, Shuang Zhang, Arif Ullah, Quanhao Zhang, Yanchi Ou. [MLatom 3: A Platform for Machine Learning-enhanced Computational Chemistry Simulations and Workflows](https://doi.org/10.1021/acs.jctc.3c01203). *J. Chem. Theory Comput.* **2024**, *20*, 1193--1213.
31
31
  * Pavlo O. Dral, Fuchun Ge, Bao-Xin Xue, Yi-Fan Hou, Max Pinheiro Jr, Jianxing Huang, Mario Barbatti. [MLatom 2: An Integrative Platform for Atomistic Machine Learning](http://doi.org/10.1007/s41061-021-00339-5). *Top. Curr. Chem.* **2021**, *379*, 27.
32
32
  * Pavlo O. Dral. [MLatom: A Program Package for Quantum Chemical Research Assisted by Machine Learning](http://dx.doi.org/10.1002/jcc.26004). *J. Comput. Chem.* **2019**, *40*, 2339--2347.
33
- * Pavlo O. Dral, Fuchun Ge, Yi-Fan Hou, Yuxinxin Chen, Peikun Zheng, Bao-Xin Xue, Mikolaj Martyka, Lina Zhang, Jakub Martinka, Quanhao Zhang, Xin-Yu Tong, Arif Ullah, Sebastian V. Pios, Vignesh B. Kumar, Yanchi Ou, Max Pinheiro Jr, Yuming Su, Yiheng Dai, Yangtao Chen, Shuang Zhang, Matheus O. Bispo, MLatom: A Package for Atomistic Simulations with Machine Learning, version 3.18.2, Xiamen University, Xiamen, China, 2013-2025. [MLatom.com](http://mlatom.com).
33
+ * Pavlo O. Dral, Fuchun Ge, Yi-Fan Hou, Yuxinxin Chen, Peikun Zheng, Bao-Xin Xue, Mikolaj Martyka, Lina Zhang, Jakub Martinka, Quanhao Zhang, Xin-Yu Tong, Arif Ullah, Sebastian V. Pios, Vignesh B. Kumar, Yanchi Ou, Max Pinheiro Jr, Yuming Su, Yiheng Dai, Yangtao Chen, Shuang Zhang, Jinming Hu, Matheus O. Bispo, MLatom: A Package for Atomistic Simulations with Machine Learning, version 3.19.0, Xiamen University, Xiamen, China, 2013-2025. [MLatom.com](http://mlatom.com).
34
34
 
35
35
  The citations for MLatom's interfaces and features shall be eventually
36
36
  included too. See program output, header.py, ref.json, and [MLatom.com](http://mlatom.com).
@@ -78,7 +78,7 @@ Citations mentioned above should be included. For convenience, below we provide
78
78
  }
79
79
 
80
80
  @misc{MLatomProg,
81
- author = {Dral, Pavlo O. and Ge, Fuchun and Hou, Yi-Fan and Chen, Yuxinxin and Zheng, Peikun and Xue, Bao-Xin and Martyka, Mikolaj and Zhang, Lina and Martinka, Jakub and Zhang, Quanhao and Tong, Xin-Yu and Ullah, Arif and Pios, Sebastian V. and Kumar, Vignesh B. and Ou, Yanchi and Jr, Max Pinheiro and Su, Yuming and Dai, Yiheng and Chen, Yangtao and Zhang, Shuang and Bispo, Matheus O.},
81
+ author = {Dral, Pavlo O. and Ge, Fuchun and Hou, Yi-Fan and Chen, Yuxinxin and Zheng, Peikun and Xue, Bao-Xin and Martyka, Mikolaj and Zhang, Lina and Martinka, Jakub and Zhang, Quanhao and Tong, Xin-Yu and Ullah, Arif and Pios, Sebastian V. and Kumar, Vignesh B. and Ou, Yanchi and Jr, Max Pinheiro and Su, Yuming and Dai, Yiheng and Chen, Yangtao and Zhang, Shuang and Hu, Jinming and Bispo, Matheus O.},
82
82
  title = {MLatom: A Package for Atomistic Simulations with Machine Learning},
83
83
  year = {2013--2025},
84
84
  type = {Computer Program}
@@ -43,7 +43,7 @@ with open(os.path.join(here, 'README.md')) as f:
43
43
 
44
44
  setup(
45
45
  name = pkg_name,
46
- version = "3.18.2",
46
+ version = "3.19.0",
47
47
  author = "Pavlo O. Dral",
48
48
  author_email = "admin@mlatom.com",
49
49
  license = 'MIT (modified)',
@@ -18,6 +18,8 @@ from .EEEDDDD_nn import batch_jacobian, MLP, ModelEnsemble, StackModelEnsemble,
18
18
  from .EEEDDDD_descriptor import self_edge_vector_matrix, self_distance_matrix
19
19
  from typing import Any, List, Dict, Union, Iterable, Optional
20
20
 
21
+ torch.set_default_dtype(torch.float32)
22
+
21
23
  # torch.autograd.set_detect_anomaly(True)
22
24
 
23
25
  @compile_mode("script")
@@ -278,6 +280,7 @@ class EEEDDDD(model_cls.ml_model, model_cls.torch_model,model_cls.downloadable_m
278
280
  self.species = model_dict['args'].pop('species')
279
281
  model = self._new_model(model_dict['args'])
280
282
  model.load_state_dict(model_dict['state'])
283
+ model = model.to(torch.float32)
281
284
  model.eval()
282
285
  if self.verbose:
283
286
  print(f"model loaded from {model_file}")
@@ -294,10 +297,18 @@ class EEEDDDD(model_cls.ml_model, model_cls.torch_model,model_cls.downloadable_m
294
297
  kwargs['reset_base'] = reset_base
295
298
  self.model = ensemble(models=models, **kwargs)
296
299
 
297
- def load_special(self,model_file):
298
- model_name, model_path, download = self.check_model_path(model_file)
299
- if download: self.download(model_name,model_path)
300
- model_paths = [os.path.join(model_path,f'MDtrajNet-1.{ii}.pt') for ii in range(4)]
300
+ def load_special(self, model_file):
301
+
302
+ download_links = [
303
+ 'https://zenodo.org/records/15877717/files/mdtrajnet1_model.zip?download=1',
304
+ 'https://aitomistic.xyz/model/mdtrajnet1_model.zip']
305
+ model_dir = 'mdtrajnet1_model'
306
+ model_files = [f'MDtrajNet-1.{ii}.pt' for ii in range(4)]
307
+
308
+ mlatom_model_dir, to_download = self.check_model_path(model_dir, model_files)
309
+ if to_download: self.download(download_links, mlatom_model_dir)
310
+
311
+ model_paths = [os.path.join(mlatom_model_dir,f'MDtrajNet-1.{ii}.pt') for ii in range(4)]
301
312
  self.load(model_paths)
302
313
 
303
314
  def specie_to_index(self, species: np.ndarray) -> torch.Tensor:
@@ -1,11 +1,13 @@
1
1
  #!/usr/bin/env python
2
2
  # coding: utf-8
3
3
 
4
-
5
4
  '''
6
5
  !---------------------------------------------------------------------------!
7
6
  ! mltpa: Machine learning prediction of the Two-photon absorption !
8
- ! Implementations by: Yuming Su, Yiheng Dai, Yangtao Chen, Fuchun Ge !
7
+ ! Implementations by: Yuming Su, Yiheng Dai, Yangtao Chen, Fuchun Ge !
8
+ ! !
9
+ ! Modified on 2025.07.30 by Yuming Su, to make it work, !
10
+ ! if one does NOT have conjugation structure !
9
11
  !---------------------------------------------------------------------------!
10
12
  '''
11
13
 
@@ -345,6 +347,52 @@ class MLTPA(object):
345
347
  mol = Chem.MolFromSmiles(smiles)
346
348
  d_m = Chem.rdmolops.GetDistanceMatrix(mol)
347
349
  ring_list, f_a = self.find_conj(smiles)
350
+
351
+ # 处理没有共轭结构的情况
352
+ if len(ring_list) == 0:
353
+ # 没有共轭结构时,最大共轭距离为0
354
+ feature_vector[0] = 0
355
+
356
+ # 计算所有原子的PEOE电荷、logP和MR
357
+ AllChem.ComputeGasteigerCharges(mol, nIter=25)
358
+ peoe_charge = [mol.GetAtomWithIdx(i).GetDoubleProp('_GasteigerCharge') for i in range(mol.GetNumAtoms())]
359
+ contribs = rdMolDescriptors._CalcCrippenContribs(mol)
360
+ logp = [contribs[i][0] for i in range(len(contribs))]
361
+ mr = [contribs[i][1] for i in range(len(contribs))]
362
+
363
+ # 使用整个分子的原子进行片段匹配
364
+ all_atoms = list(range(mol.GetNumAtoms()))
365
+ atom_props = [peoe_charge, logp, mr]
366
+
367
+ for prop_idx in range(len(atom_props)):
368
+ atom_props_list = atom_props[prop_idx]
369
+ frag_x = []
370
+
371
+ # 在整个分子中寻找匹配的片段
372
+ for i in range(len(mff_title)):
373
+ patt = mff_title[i]
374
+ f = Chem.MolFromSmarts(patt)
375
+ atomids = mol.GetSubstructMatches(f)
376
+ if len(atomids) > 0:
377
+ for atomid_group in atomids:
378
+ x_temp = 0
379
+ for k in atomid_group:
380
+ x_temp += atom_props_list[k]
381
+ frag_x.append(x_temp)
382
+
383
+ if len(frag_x) == 0:
384
+ frag_x = [0]
385
+
386
+ if prop_idx == 0 or prop_idx == 2: # PEOE电荷和MR取最大值
387
+ feature_vector[prop_idx + 1] = max(frag_x)
388
+ else: # logP取最小值
389
+ feature_vector[prop_idx + 1] = min(frag_x)
390
+
391
+ feature_vector[4] = et30
392
+ feature_vector[5] = wavelength
393
+ return feature_vector
394
+
395
+ # 原有的有共轭结构的处理逻辑
348
396
  lstmax = sorted(ring_list, key=len)[-1]
349
397
 
350
398
  # calculate max conju-distance
@@ -4,11 +4,9 @@
4
4
  !---------------------------------------------------------------------------!
5
5
  ! !
6
6
  ! MLatom: a Package for Atomistic Simulations with Machine Learning !
7
- ! MLatom 3.18.2 !
8
- ! @ !
9
- ! Xiamen Atomistic Computing Suite (XACS) !
7
+ ! MLatom 3.19.0 !
10
8
  ! !
11
- ! http://mlatom.com/ @ https://XACScloud.com !
9
+ ! http://mlatom.com/ !
12
10
  ! !
13
11
  ! MIT License (modified to request proper citations) !
14
12
  ! Copyright (c) 2013- Pavlo O. Dral !
@@ -36,9 +34,9 @@
36
34
  ! Bao-Xin Xue, Mikolaj Martyka, Lina Zhang, Jakub Martinka, Quanhao Zhang, !
37
35
  ! Xin-Yu Tong, Arif Ullah, Sebastian V. Pios, Vignesh B. Kumar, Yanchi Ou, !
38
36
  ! Max Pinheiro Jr, Yuming Su, Yiheng Dai, Yangtao Chen, Shuang Zhang, !
39
- ! Matheus O. Bispo !
37
+ ! Jinming Hu, Matheus O. Bispo !
40
38
  ! MLatom: A Package for Atomistic Simulations with Machine Learning, !
41
- ! version 3.18.2, Xiamen University, Xiamen, China, 2013-2025. !
39
+ ! version 3.19.0, Xiamen University, Xiamen, China, 2013-2025. !
42
40
  ! !
43
41
  ! The citations for MLatom's interfaces and features shall be eventually !
44
42
  ! included too. See header.py, ref.json and http://mlatom.com. !
@@ -46,12 +46,12 @@ def useMLmodel(args):
46
46
  if args.uaiqm:
47
47
  get_uaiqm_args(args)
48
48
  model = loading_model(args)
49
- molecular_database = loading_data(args.XYZfile, args.Yfile, args.YgradXYZfile, charges=args.charges, multiplicities=args.multiplicities)
49
+ molecular_database = loading_data(args.XYZfile, args.jsonfile, args.Yfile, args.YgradXYZfile, charges=args.charges, multiplicities=args.multiplicities)
50
50
  t_predict = predicting(model=model, molecular_database=molecular_database, value=bool(args.YestFile), gradient=bool(args.YgradXYZestFile), hessian=bool(args.hessianEstFile), ismethod=args.method)
51
51
  saving_predictions(molecular_database, YestFile=args.YestFile, YgradXYZestFile=args.YgradXYZestFile, hessianEstFile=args.hessianEstFile, method=args.method)
52
52
  if args.method:
53
53
  print('')
54
- if args.AIQM1 or args.AIQM1DFT or args.AIQM1DFTstar or args.AIQM2 or args.AIQM2DFT or args.ani1ccx or args.ani1x or args.ani2x or args.ani1xd4 or args.ani2xd4 or args.ani1ccxgelu or args.ani1xgelu or args.ani1ccxgelud4 or args.ani1xgelud4:
54
+ if args.AIQM1 or args.AIQM1DFT or args.AIQM1DFTstar or args.AIQM2 or args.AIQM2DFT or args.AIQM3 or args.AIQM3DFT or args.ani1ccx or args.ani1x or args.ani2x or args.ani1xd4 or args.ani2xd4 or args.ani1ccxgelu or args.ani1xgelu or args.ani1ccxgelud4 or args.ani1xgelud4:
55
55
  nmol = 0
56
56
  for mol in molecular_database:
57
57
  nmol += 1
@@ -60,6 +60,8 @@ def useMLmodel(args):
60
60
  printing_aiqm1_results(aiqm1=args.AIQM1, molecule=mol)
61
61
  if args.AIQM2 or args.AIQM2DFT:
62
62
  printing_aiqm2_results(molecule=mol)
63
+ if args.AIQM3 or args.AIQM3DFT:
64
+ printing_aiqm3_results(molecule=mol)
63
65
  elif args.ani1ccx or args.ani1x or args.ani2x or args.ani1xd4 or args.ani2xd4 or args.ani1ccxgelu or args.ani1xgelu or args.ani1ccxgelud4 or args.ani1xgelud4:
64
66
  printing_animethod_results(methodname=model.method, molecule=mol)
65
67
  elif 'uaiqm' in args.method:
@@ -79,7 +81,7 @@ def useMLmodel(args):
79
81
  def createMLmodel(args):
80
82
  if args.deltaLearn:
81
83
  pre_delta_learning(args)
82
- molecular_database = loading_data(args.XYZfile, args.Yfile, args.YgradXYZfile, charges=args.charges, multiplicities=args.multiplicities)
84
+ molecular_database = loading_data(args.XYZfile, args.jsonfile, args.Yfile, args.YgradXYZfile, charges=args.charges, multiplicities=args.multiplicities)
83
85
  i_train, i_subtrain, i_validate, i_test, i_cvtest, i_cvopt = sampling(args=args)
84
86
  model = loading_model(args)
85
87
  result = training(
@@ -95,7 +97,7 @@ def createMLmodel(args):
95
97
  def estAccMLmodel(args):
96
98
  if args.deltaLearn:
97
99
  pre_delta_learning(args)
98
- molecular_database = loading_data(args.XYZfile, args.Yfile, args.YgradXYZfile)
100
+ molecular_database = loading_data(args.XYZfile,args.jsonfile, args.Yfile, args.YgradXYZfile)
99
101
  i_train, i_subtrain, i_validate, i_test, i_cvtest, i_cvopt = sampling(args=args)
100
102
  model = loading_model(args)
101
103
  if args.CVtest:
@@ -212,7 +214,7 @@ def selfCorrect(args):
212
214
  fylayer.writelines('%25.13f\n' % (ylayerm1[ii] + yestlayer[ii]))
213
215
 
214
216
  def learningCurve(args):
215
- molecular_database = loading_data(args.XYZfile, args.Yfile, args.YgradXYZfile, charges=args.charges, multiplicities=args.multiplicities)
217
+ molecular_database = loading_data(args.XYZfile, args.jsonfile, args.Yfile, args.YgradXYZfile, charges=args.charges, multiplicities=args.multiplicities)
216
218
  if args.XfileIn:
217
219
  args.XfileIn = os.path.abspath(args.Xfilein)
218
220
  else:
@@ -385,7 +387,7 @@ def geomopt(args, return_moldb=False):
385
387
  from . import simulations
386
388
  if args.uaiqm:
387
389
  get_uaiqm_args(args)
388
- molDB = loading_data(XYZfile=args.XYZfile, charges=args.charges, multiplicities=args.multiplicities)
390
+ molDB = loading_data(XYZfile=args.XYZfile, jsonfile=args.jsonfile, charges=args.charges, multiplicities=args.multiplicities)
389
391
  model = loading_model(args)
390
392
  fname = args.optXYZ
391
393
  # if os.path.exists(fname): stopper.stopMLatom(f'File {fname} already exists; please delete or rename it')
@@ -431,6 +433,10 @@ def geomopt(args, return_moldb=False):
431
433
  print('\n\n Final properties of molecule %d\n' % (imol+1))
432
434
  printing_aiqm2_results(molecule=geomopt.optimized_molecule)
433
435
  print('\n')
436
+ if args.AIQM3 or args.AIQM3DFT:
437
+ print('\n\n Final properties of molecule %d\n' % (imol+1))
438
+ printing_aiqm3_results(molecule=geomopt.optimized_molecule)
439
+ print('\n')
434
440
  elif args.method and 'uaiqm' in args.method:
435
441
  print('\n\n Final properties of molecule %d\n' % (imol+1))
436
442
  uversion = None if not args.uversion else args.uversion
@@ -456,7 +462,7 @@ def ts(args, return_moldb=False):
456
462
  def freq(args, molDB=None):
457
463
  from . import simulations
458
464
  if molDB is None:
459
- molDB = loading_data(args.XYZfile, charges=args.charges, multiplicities=args.multiplicities)
465
+ molDB = loading_data(args.XYZfile, jsonfile=args.jsonfile, charges=args.charges, multiplicities=args.multiplicities)
460
466
  if args.uaiqm:
461
467
  get_uaiqm_args(args)
462
468
  model = loading_model(args)
@@ -557,6 +563,9 @@ def freq(args, molDB=None):
557
563
  if args.AIQM2 or args.AIQM2DFT:
558
564
  printing_aiqm2_results(molecule=mol)
559
565
  print('')
566
+ if args.AIQM3 or args.AIQM3DFT:
567
+ printing_aiqm3_results(molecule=mol)
568
+ print('')
560
569
  elif args.method and 'uaiqm' in args.method:
561
570
  uversion = None if not args.uversion else args.uversion
562
571
  printing_uaiqm_results(molecule=mol, method=args.method, uversion=args.uversion)
@@ -579,13 +588,13 @@ def freq(args, molDB=None):
579
588
  # To-do: make it work for ANI-1ccx
580
589
  if args.AIQM1:
581
590
  if mol.aiqm1_nn.energy_standard_deviation > 0.41*constants.kcalpermol2Hartree:
582
- print(' * Warning * Heat of formation have high uncertainty!')
591
+ print(' * Warning * Heat of formation has high uncertainty!')
583
592
  if args.AIQM2:
584
593
  if mol.aiqm2_nn.energy_standard_deviation > 0.36*constants.kcalpermol2Hartree:
585
- print(' * Warning * Heat of formation have high uncertainty!')
594
+ print(' * Warning * Heat of formation has high uncertainty!')
586
595
  if args.ani1ccx:
587
596
  if mol.ani1ccx.energy_standard_deviation > 1.68*constants.kcalpermol2Hartree:
588
- print(' * Warning * Heat of formation have high uncertainty!')
597
+ print(' * Warning * Heat of formation has high uncertainty!')
589
598
  print('')
590
599
 
591
600
  def ir(args):
@@ -596,13 +605,20 @@ def raman(args):
596
605
  freq(args)
597
606
 
598
607
  def irc(args):
599
- from . import simulations
600
- molDB = loading_data(args.XYZfile, charges=args.charges, multiplicities=args.multiplicities)
608
+ from .irc import irc
609
+ molDB = loading_data(XYZfile=args.XYZfile, jsonfile=args.jsonfile, charges=args.charges, multiplicities=args.multiplicities)
601
610
  model = loading_model(args)
602
611
  for imol, mol in enumerate(molDB):
603
612
  mol.number = imol+1
604
- geomopt = simulations.irc(model=model,
605
- ts_molecule=mol)
613
+ if len(molDB) == 1: wd = 'irc'
614
+ else: wd = f'irc{imol}'
615
+ forward=False; backward=False
616
+ if args.forward: forward=True
617
+ if args.backward: backward=True
618
+ results = irc(
619
+ model=model, molecule=mol, program=args.ircprog, working_directory=wd,
620
+ forward=forward, backward=backward)
621
+ print(results); sys.stdout.flush()
606
622
 
607
623
  def MD(args):
608
624
  from . import md_cmd
@@ -641,7 +657,7 @@ def MLTPA(args):
641
657
 
642
658
  def al(args):
643
659
  from .al import active_learning
644
- molDB = loading_data(args.XYZfile, charges=args.charges, multiplicities=args.multiplicities)
660
+ molDB = loading_data(args.XYZfile, jsonfile=args.jsonfile, charges=args.charges, multiplicities=args.multiplicities)
645
661
  args.nthreads = 1
646
662
  model = loading_model(args)
647
663
  active_learning(
@@ -650,11 +666,22 @@ def al(args):
650
666
  )
651
667
 
652
668
  # Reusable functions below. Name with -ing form
653
- def loading_data(XYZfile, Yfile=None, YgradXYZfile=None, charges=None, multiplicities=None):
654
- assert XYZfile, 'please provide data file(s) needed.'
655
- if not os.path.exists(XYZfile):
669
+ def loading_data(XYZfile=None, jsonfile=None, Yfile=None, YgradXYZfile=None, charges=None, multiplicities=None):
670
+
671
+ assert XYZfile or jsonfile, 'please provide data file(s) needed.'
672
+ if XYZfile and jsonfile:
673
+ print("Both xyz file and .json file are specified. Only json file will be loaded!")
674
+ XYZfile = None
675
+
676
+ if XYZfile and not os.path.exists(XYZfile):
656
677
  stopper.stopMLatom(f'xyz file {XYZfile} is not found!')
657
- molecular_database = data.molecular_database.from_xyz_file(XYZfile)
678
+ if jsonfile and not os.path.exists(jsonfile):
679
+ stopper.stopMLatom(f'json file {jsonfile} is not found!')
680
+
681
+ if XYZfile:
682
+ molecular_database = data.molecular_database.from_xyz_file(XYZfile)
683
+ if jsonfile:
684
+ molecular_database = data.molecular_database.load(jsonfile, format='json')
658
685
  if Yfile:
659
686
  molecular_database.add_scalar_properties_from_file(Yfile)
660
687
  if YgradXYZfile:
@@ -688,6 +715,8 @@ def loading_method(args):
688
715
  kwargs['warning'] = args.uwarning
689
716
  method = models.methods(**kwargs)
690
717
  method.set_num_threads(args.nthreads)
718
+ if args.calcdir:
719
+ method.working_directory = args.calcdir # some methods don't have working_directory arguments
691
720
  return method
692
721
 
693
722
  def loading_model(args):
@@ -1080,7 +1109,7 @@ def post_delta_learning(args):
1080
1109
  fyestt.writelines('%s\n' % strtmp)
1081
1110
 
1082
1111
  def get_uaiqm_args(args):
1083
- molecular_database = loading_data(args.XYZfile, args.Yfile, args.YgradXYZfile, charges=args.charges, multiplicities=args.multiplicities)
1112
+ molecular_database = loading_data(args.XYZfile, args.jsonfile, args.Yfile, args.YgradXYZfile, charges=args.charges, multiplicities=args.multiplicities)
1084
1113
  model = models.uaiqm(method='uaiqm_optimal')
1085
1114
  if not args.ncpus:
1086
1115
  args.ncpus = 8
@@ -1123,6 +1152,20 @@ def printing_aiqm2_results(molecule=None):
1123
1152
  print(fmt % ('D4 contribution', molecule.d4wb97x.energy))
1124
1153
  print(fmt % ('Total energy', molecule.energy))
1125
1154
 
1155
+ def printing_aiqm3_results(molecule=None):
1156
+ fmt = ' %-41s: %15.8f Hartree'
1157
+ # find aiqm1 keyword
1158
+ for kk,_ in molecule.__dict__.items():
1159
+ if 'aiqm3' in kk and kk[-2:]=='nn':
1160
+ aiqm3method = kk.replace('_nn','')
1161
+ break
1162
+ print(fmt % ('Standard deviation of NN contribution', molecule.__dict__[aiqm3method+'_nn'].energy_standard_deviation), end='')
1163
+ print(' %15.5f kcal/mol' % (molecule.__dict__[aiqm3method+'_nn'].energy_standard_deviation * constants.Hartree2kcalpermol))
1164
+ print(fmt % ('NN contribution', molecule.__dict__[aiqm3method+'_nn'].energy))
1165
+ print(fmt % ('GFN2-xTB* contribution', molecule.gfn2xtbstar.energy), file=sys.stdout)
1166
+ print(fmt % ('D3 contribution', molecule.d3b973c.energy))
1167
+ print(fmt % ('Total energy', molecule.energy))
1168
+
1126
1169
  def printing_uaiqm_results(molecule=None, method=None, uversion=None):
1127
1170
  print(f' Selected UAIQM method: {method}')
1128
1171
  if uversion:
@@ -4,12 +4,12 @@ from .MLatom import run
4
4
  from .simulations import optimize_geometry, irc, freq, thermochemistry, md, generate_initial_conditions, vibrational_spectrum, md_parallel
5
5
  from .data import atom, molecule, molecular_database
6
6
  from .models import kreg, ani, msani
7
- from .models import methods, aiqm1, aiqm2, dens, ani_methods, aimnet2_methods, gaussian_methods, pyscf_methods, orca_methods, turbomole_methods, mndo_methods, sparrow_methods, xtb_methods, dftbplus_methods, columbus_methods, dftd3_methods, dftd4_methods
7
+ from .models import methods, aiqm1, aiqm2, aiqm3, dens, ani_methods, aimnet2_methods, gaussian_methods, pyscf_methods, orca_methods, turbomole_methods, mndo_methods, sparrow_methods, xtb_methods, dftbplus_methods, columbus_methods, dftd3_methods, dftd4_methods
8
8
  from .models import MDtrajNet
9
9
  from . import al_utils
10
10
  from .al import al
11
11
  from .gap_md import gap_md, gap_model
12
12
  # add-ons
13
- from .models import uaiqm, omnip2x, vecmsani
13
+ from .models import uaiqm, omnip1, omnip2x, vecmsani
14
14
 
15
- __version__ = '3.18.2'
15
+ __version__ = '3.19.0'
@@ -0,0 +1,47 @@
1
+ import os
2
+ from ... import data, models, constants
3
+ from ...model_cls import method_model, model_tree_node, downloadable_model
4
+
5
+ class aiqm3(method_model, downloadable_model):
6
+
7
+ """
8
+ GFN2-xTB based artificial intelligence quantum-mechanical method 3 (AIQM3)
9
+
10
+ Arguments:
11
+
12
+ method (str, optional): Currently supports AIQM3, AIQM3@DFT, AIQM3@DFT*
13
+ working_directory (str, optional): The path to save temporary calculation file. By default, current directory will be choosed.
14
+ baseline_kwargs (dict, optional): Keywords passed to GFN2-xTB
15
+ dispersion_kwargs (dict, optional):
16
+
17
+ .. code-block::
18
+
19
+ # Initialize molecule
20
+ mol = ml.molecule.from_xyz_file(filename='ethanol.xyz')
21
+ # Run AIQM3 calculation
22
+ aiqm3 = ml.methods(method='aiqm3')
23
+ aiqm3.predict(molecule=mol, calculate_energy=True, calculate_energy_gradients=True, calculate_hessian=True)
24
+ # Get energy, gradient, and uncertainty of AIQM3
25
+ energy = mol.energy
26
+ gradient = mol.get_energy_gradients()
27
+ hess = mol.hessian
28
+ std = mol.aiqm3_model_nn.energy_standard_deviation
29
+
30
+ """
31
+
32
+ supported_methods = ['AIQM3', 'AIQM3@DFT']
33
+
34
+ def __init__(
35
+ self,
36
+ method: str = 'AIQM3',
37
+ working_directory: str = None,
38
+ baseline_kwargs: dict = None,
39
+ dispersion_kwargs: dict = None,
40
+ nthreads: int = 1
41
+ ):
42
+
43
+ if self.is_method_supported(method=method):
44
+ raise ValueError(f'The requested method "{method}" is supported as an add-on in Aitomic, please refer to http://MLatom.com/aitomic for the instructions on how to obtain it.')
45
+ else:
46
+ self.raise_unsupported_method_error(method)
47
+
@@ -200,25 +200,30 @@ class ani_nns_in_aiqm1(torchani_model, downloadable_model):
200
200
 
201
201
  def load_model(self):
202
202
  import torch
203
- mlatomdir=os.path.dirname(__file__)
204
- dirname = os.path.join(mlatomdir, 'aiqm1_model')
203
+ # mlatomdir = os.path.dirname(__file__)
204
+ # dirname = os.path.join(mlatomdir, 'aiqm1_model')
205
205
  method = 'aiqm1_' + self.level
206
206
  self.define_nn()
207
207
 
208
- # check model file
209
- # if 'dft' in method.lower():
210
- # if 'MODELSPATH' in os.environ:
211
- # modelspath = os.environ['MODELSPATH']
212
- # else:
213
- # raise ValueError(f'Please set environment variable MODELSPATH for using this method and put NN model files under $MODELSPATH/{method}_model/')
214
- # dirname = os.path.join(os.environ['MODELSPATH'], f'{method}_model')
215
- # if not os.path.exists(dirname):
216
- # raise ValueError(f'Please put model files under $MODELSPATH/{method}_model/')
217
- model_name, model_path, download = self.check_model_path(self.method)
218
- if download: self.download(model_name, model_path)
208
+ if method == 'aiqm1_cc':
209
+ download_links = [
210
+ 'https://zenodo.org/records/15383390/files/aiqm1_cc_model.zip?download=1',
211
+ 'https://aitomistic.xyz/model/uaiqm_odm2star_cc_20211202.zip']
212
+ model_dir = 'aiqm1_model'
213
+ model_files = [f'cv{ii}.pt' for ii in range(8)]
214
+
215
+ elif method == 'aiqm1_dft':
216
+ download_links = [
217
+ 'https://zenodo.org/records/15383390/files/aiqm1_dft_model.zip?download=1',
218
+ 'https://aitomistic.xyz/model/uaiqm_odm2star_dft_20211202.zip']
219
+ model_dir = 'aiqm1_dft_model'
220
+ model_files = [f'cv{ii}.pt' for ii in range(8)]
221
+
222
+ mlatom_model_dir, to_download = self.check_model_path(model_dir, model_files)
223
+ if to_download: self.download(download_links, mlatom_model_dir)
219
224
 
220
225
  # checkpoint = torch.load(os.path.join(dirname, f'{method}_cv{self.model_index}.pt'), map_location=self.device)
221
- checkpoint = torch.load(os.path.join(model_path, f'cv{self.model_index}.pt'), map_location=self.device, weights_only=False)
226
+ checkpoint = torch.load(os.path.join(mlatom_model_dir, f'cv{self.model_index}.pt'), map_location=self.device, weights_only=False)
222
227
  self.nn.load_state_dict(checkpoint['nn'])
223
228
  import torchani
224
229
  self.model = torchani.nn.Sequential(self.aev_computer, self.nn).to(self.device).double()