stjames 0.0.90__py3-none-any.whl → 0.0.92__py3-none-any.whl

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.

Potentially problematic release.


This version of stjames might be problematic. Click here for more details.

stjames/engine.py ADDED
@@ -0,0 +1,16 @@
1
+ from .base import LowercaseStrEnum
2
+
3
+
4
+ class Mode(LowercaseStrEnum):
5
+ AIMNET2 = "aimnet2"
6
+ MACE = "mace"
7
+ OCP24 = "ocp24"
8
+ OMOL25 = "omol25"
9
+ ORB = "orb"
10
+ TBLITE = "tblite"
11
+ XTB = "xtb"
12
+ TERRACHEM = "terrachem"
13
+ PYSCF = "pyscf"
14
+ PSI4 = "psi4"
15
+ OPENFF = "openff"
16
+ EGRET = "egret"
stjames/method.py CHANGED
@@ -37,7 +37,7 @@ class Method(LowercaseStrEnum):
37
37
  OCP24_L = "ocp24_l"
38
38
  OMOL25_CONSERVING_S = "omol25_conserving_s"
39
39
  UMA_M_OMOL = "uma_m_omol"
40
- ORB_V2 = "orb_v2"
40
+ UMA_S_OMOL = "uma_s_omol"
41
41
  ORB_V3_CONSERVATIVE_INF_OMAT = "orb_v3_conservative_inf_omat"
42
42
 
43
43
  GFN_FF = "gfn_ff"
@@ -51,12 +51,53 @@ class Method(LowercaseStrEnum):
51
51
 
52
52
  OFF_SAGE_2_2_1 = "off_sage_2_2_1"
53
53
 
54
- RM1 = "rm1"
55
-
56
54
  EGRET_1 = "egret_1"
57
55
  EGRET_1E = "egret_1e"
58
56
  EGRET_1T = "egret_1t"
59
57
 
58
+ def default_engine(self, *, is_periodic: bool = False) -> str:
59
+ """
60
+ Return the canonical engine name for this quantum-chemistry method.
61
+
62
+ :param bool is_periodic:
63
+ If ``True`` **and** the method is in the XTB family, return
64
+ ``"tblite"`` (periodic-capable backend) instead of ``"xtb"``.
65
+ :returns: Lower-case engine identifier (e.g. ``"psi4"``, ``"mace"``).
66
+
67
+ **Examples**
68
+
69
+ .. code-block:: python
70
+
71
+ Method.MACE_MP_0B2_L.default_engine()
72
+ # 'mace'
73
+
74
+ Method.GFN2_XTB.default_engine()
75
+ # 'xtb'
76
+
77
+ Method.GFN2_XTB.default_engine(is_periodic=True)
78
+ # 'tblite'
79
+ """
80
+ match self:
81
+ case Method.AIMNET2_WB97MD3:
82
+ return "aimnet2"
83
+ case Method.MACE_MP_0B2_L:
84
+ return "mace"
85
+ case Method.OCP24_S | Method.OCP24_L:
86
+ return "ocp24"
87
+ case Method.OMOL25_CONSERVING_S | Method.UMA_M_OMOL | Method.UMA_S_OMOL:
88
+ return "omol25"
89
+ case Method.ORB_V3_CONSERVATIVE_INF_OMAT:
90
+ return "orb"
91
+ case _ if self in XTB_METHODS:
92
+ return "tblite" if is_periodic else "xtb"
93
+ case Method.OFF_SAGE_2_2_1:
94
+ return "openff"
95
+ case Method.EGRET_1 | Method.EGRET_1E | Method.EGRET_1T:
96
+ return "egret"
97
+ case _:
98
+ # All remaining methods (HF, DFT, composite, etc.) fall back to Psi4
99
+ return "psi4"
100
+
60
101
 
61
102
  PrepackagedNNPMethod = Literal[
62
103
  Method.AIMNET2_WB97MD3,
@@ -64,7 +105,7 @@ PrepackagedNNPMethod = Literal[
64
105
  Method.OCP24_L,
65
106
  Method.OMOL25_CONSERVING_S,
66
107
  Method.UMA_M_OMOL,
67
- Method.RM1,
108
+ Method.UMA_S_OMOL,
68
109
  Method.ORB_V3_CONSERVATIVE_INF_OMAT,
69
110
  Method.EGRET_1,
70
111
  Method.EGRET_1E,
@@ -77,15 +118,15 @@ PREPACKAGED_NNP_METHODS = [
77
118
  Method.OCP24_L,
78
119
  Method.OMOL25_CONSERVING_S,
79
120
  Method.UMA_M_OMOL,
80
- Method.RM1,
121
+ Method.UMA_S_OMOL,
81
122
  Method.ORB_V3_CONSERVATIVE_INF_OMAT,
82
123
  Method.EGRET_1,
83
124
  Method.EGRET_1E,
84
125
  Method.EGRET_1T,
85
126
  ]
86
127
 
87
- CorrectableNNPMethod = Literal[Method.MACE_MP_0B2_L, Method.ORB_V2]
88
- CORRECTABLE_NNP_METHODS = [Method.MACE_MP_0B2_L, Method.ORB_V2]
128
+ CorrectableNNPMethod = Literal[Method.MACE_MP_0B2_L]
129
+ CORRECTABLE_NNP_METHODS = [Method.MACE_MP_0B2_L]
89
130
 
90
131
  NNPMethod = PrepackagedNNPMethod | CorrectableNNPMethod
91
132
  NNP_METHODS = [*PREPACKAGED_NNP_METHODS, *CORRECTABLE_NNP_METHODS]
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: stjames
3
- Version: 0.0.90
3
+ Version: 0.0.92
4
4
  Summary: standardized JSON atom/molecule encoding scheme
5
5
  Author-email: Corin Wagen <corin@rowansci.com>
6
6
  Project-URL: Homepage, https://github.com/rowansci/stjames
@@ -8,10 +8,11 @@ stjames/compute_settings.py,sha256=wuYE6W4WqP3oFHwAeEp7XQ0oMz_MNLucWgrsuJ4kEFQ,2
8
8
  stjames/constraint.py,sha256=B6oV0rYjmAWr8gpi5f03gRy_uuqjUURVDVwoez5Cfbg,2442
9
9
  stjames/correction.py,sha256=ZVErCcj4TPyZeKrdvXVjHa0tFynsCaoy96QZUVxWFM8,413
10
10
  stjames/diis_settings.py,sha256=4m1EQQWBlpHhMnWopix8qOqJv7QCluvdnV9jSKJDFtE,552
11
+ stjames/engine.py,sha256=wVItZQSIeR3ap6EZG3kOw0xCZztZm-6KKFrX84ZyFsE,313
11
12
  stjames/grid_settings.py,sha256=WrSNGc-8_f87YBZYt9Hh7RbhM4MweADoVzwBMcSqcsE,640
12
13
  stjames/int_settings.py,sha256=5HXp8opt5ZyY1UpmfaK7NVloWVLM5jkG0elEEqpVLUo,896
13
14
  stjames/message.py,sha256=Rq6QqmHZKecWxYH8fVyXmuoCCPZv8YinvgykSeorXSU,216
14
- stjames/method.py,sha256=aPFUhfUtJ_befRHO1Aa_c4ofEQAPZlQUvHWLaCv32Z4,2945
15
+ stjames/method.py,sha256=8Cj0JYGMEaS_Cetfz8Wcu6-BZAv1SejRSagMgkKaXs0,4469
15
16
  stjames/mode.py,sha256=xw46Cc7f3eTS8i35qECi-8DocAlANhayK3w4akD4HBU,496
16
17
  stjames/molecule.py,sha256=l4S6prH1xflnZtbwidSF2THsiHaSJtRiy1rmUbH366Q,20631
17
18
  stjames/opt_settings.py,sha256=LEwGXUEKq5TfU5rr60Z4QQBhCqiw1Ch5w0M_lXawWo8,642
@@ -62,8 +63,8 @@ stjames/workflows/solubility.py,sha256=kGfVyPPGDLRpf2j6dSY7woCkfsoXSbUzdSImA4mcM
62
63
  stjames/workflows/spin_states.py,sha256=0degmE-frovgoXweshZyjfjqL7nkbaFoO9YoJhvQnaI,4748
63
64
  stjames/workflows/tautomer.py,sha256=7eYKziGPg8Km6lfowTzSkgJfJ4SHUPrAmnTf8Bi-SB0,1164
64
65
  stjames/workflows/workflow.py,sha256=OE05pt2ZOd8TzTOlBngXCVg9wv_553ZR60VNRPlq0f8,1953
65
- stjames-0.0.90.dist-info/licenses/LICENSE,sha256=i7ehYBS-6gGmbTcgU4mgk28pyOx2kScJ0kcx8n7bWLM,1084
66
- stjames-0.0.90.dist-info/METADATA,sha256=IbwiPJaGd1rkTp0eSNDf5yTAHqnJ21wTIgI18ObeaHA,1724
67
- stjames-0.0.90.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
68
- stjames-0.0.90.dist-info/top_level.txt,sha256=FYCwxl6quhYOAgG-mnPQcCK8vsVM7B8rIUrO-WrQ_PI,8
69
- stjames-0.0.90.dist-info/RECORD,,
66
+ stjames-0.0.92.dist-info/licenses/LICENSE,sha256=i7ehYBS-6gGmbTcgU4mgk28pyOx2kScJ0kcx8n7bWLM,1084
67
+ stjames-0.0.92.dist-info/METADATA,sha256=QQ4yZAEcRFwv4KCTOBZxuCrOzmNb_kBv2G3Jd4-2hR4,1724
68
+ stjames-0.0.92.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
69
+ stjames-0.0.92.dist-info/top_level.txt,sha256=FYCwxl6quhYOAgG-mnPQcCK8vsVM7B8rIUrO-WrQ_PI,8
70
+ stjames-0.0.92.dist-info/RECORD,,