stjames 0.0.51__tar.gz → 0.0.52__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.

Potentially problematic release.


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

Files changed (70) hide show
  1. {stjames-0.0.51/stjames.egg-info → stjames-0.0.52}/PKG-INFO +1 -1
  2. {stjames-0.0.51 → stjames-0.0.52}/pyproject.toml +1 -1
  3. {stjames-0.0.51 → stjames-0.0.52}/stjames/workflows/docking.py +16 -21
  4. {stjames-0.0.51 → stjames-0.0.52/stjames.egg-info}/PKG-INFO +1 -1
  5. {stjames-0.0.51 → stjames-0.0.52}/LICENSE +0 -0
  6. {stjames-0.0.51 → stjames-0.0.52}/README.md +0 -0
  7. {stjames-0.0.51 → stjames-0.0.52}/setup.cfg +0 -0
  8. {stjames-0.0.51 → stjames-0.0.52}/stjames/__init__.py +0 -0
  9. {stjames-0.0.51 → stjames-0.0.52}/stjames/_deprecated_solvent_settings.py +0 -0
  10. {stjames-0.0.51 → stjames-0.0.52}/stjames/atom.py +0 -0
  11. {stjames-0.0.51 → stjames-0.0.52}/stjames/base.py +0 -0
  12. {stjames-0.0.51 → stjames-0.0.52}/stjames/basis_set.py +0 -0
  13. {stjames-0.0.51 → stjames-0.0.52}/stjames/calculation.py +0 -0
  14. {stjames-0.0.51 → stjames-0.0.52}/stjames/compute_settings.py +0 -0
  15. {stjames-0.0.51 → stjames-0.0.52}/stjames/constraint.py +0 -0
  16. {stjames-0.0.51 → stjames-0.0.52}/stjames/correction.py +0 -0
  17. {stjames-0.0.51 → stjames-0.0.52}/stjames/data/__init__.py +0 -0
  18. {stjames-0.0.51 → stjames-0.0.52}/stjames/data/bragg_radii.json +0 -0
  19. {stjames-0.0.51 → stjames-0.0.52}/stjames/data/elements.py +0 -0
  20. {stjames-0.0.51 → stjames-0.0.52}/stjames/data/isotopes.json +0 -0
  21. {stjames-0.0.51 → stjames-0.0.52}/stjames/data/nist_isotopes.json +0 -0
  22. {stjames-0.0.51 → stjames-0.0.52}/stjames/data/read_nist_isotopes.py +0 -0
  23. {stjames-0.0.51 → stjames-0.0.52}/stjames/data/symbol_element.json +0 -0
  24. {stjames-0.0.51 → stjames-0.0.52}/stjames/diis_settings.py +0 -0
  25. {stjames-0.0.51 → stjames-0.0.52}/stjames/grid_settings.py +0 -0
  26. {stjames-0.0.51 → stjames-0.0.52}/stjames/int_settings.py +0 -0
  27. {stjames-0.0.51 → stjames-0.0.52}/stjames/message.py +0 -0
  28. {stjames-0.0.51 → stjames-0.0.52}/stjames/method.py +0 -0
  29. {stjames-0.0.51 → stjames-0.0.52}/stjames/mode.py +0 -0
  30. {stjames-0.0.51 → stjames-0.0.52}/stjames/molecule.py +0 -0
  31. {stjames-0.0.51 → stjames-0.0.52}/stjames/opt_settings.py +0 -0
  32. {stjames-0.0.51 → stjames-0.0.52}/stjames/pdb.py +0 -0
  33. {stjames-0.0.51 → stjames-0.0.52}/stjames/periodic_cell.py +0 -0
  34. {stjames-0.0.51 → stjames-0.0.52}/stjames/py.typed +0 -0
  35. {stjames-0.0.51 → stjames-0.0.52}/stjames/scf_settings.py +0 -0
  36. {stjames-0.0.51 → stjames-0.0.52}/stjames/settings.py +0 -0
  37. {stjames-0.0.51 → stjames-0.0.52}/stjames/solvent.py +0 -0
  38. {stjames-0.0.51 → stjames-0.0.52}/stjames/status.py +0 -0
  39. {stjames-0.0.51 → stjames-0.0.52}/stjames/task.py +0 -0
  40. {stjames-0.0.51 → stjames-0.0.52}/stjames/thermochem_settings.py +0 -0
  41. {stjames-0.0.51 → stjames-0.0.52}/stjames/types.py +0 -0
  42. {stjames-0.0.51 → stjames-0.0.52}/stjames/workflows/__init__.py +0 -0
  43. {stjames-0.0.51 → stjames-0.0.52}/stjames/workflows/admet.py +0 -0
  44. {stjames-0.0.51 → stjames-0.0.52}/stjames/workflows/basic_calculation.py +0 -0
  45. {stjames-0.0.51 → stjames-0.0.52}/stjames/workflows/bde.py +0 -0
  46. {stjames-0.0.51 → stjames-0.0.52}/stjames/workflows/conformer.py +0 -0
  47. {stjames-0.0.51 → stjames-0.0.52}/stjames/workflows/conformer_search.py +0 -0
  48. {stjames-0.0.51 → stjames-0.0.52}/stjames/workflows/descriptors.py +0 -0
  49. {stjames-0.0.51 → stjames-0.0.52}/stjames/workflows/electronic_properties.py +0 -0
  50. {stjames-0.0.51 → stjames-0.0.52}/stjames/workflows/fukui.py +0 -0
  51. {stjames-0.0.51 → stjames-0.0.52}/stjames/workflows/hydrogen_bond_basicity.py +0 -0
  52. {stjames-0.0.51 → stjames-0.0.52}/stjames/workflows/irc.py +0 -0
  53. {stjames-0.0.51 → stjames-0.0.52}/stjames/workflows/molecular_dynamics.py +0 -0
  54. {stjames-0.0.51 → stjames-0.0.52}/stjames/workflows/multistage_opt.py +0 -0
  55. {stjames-0.0.51 → stjames-0.0.52}/stjames/workflows/pka.py +0 -0
  56. {stjames-0.0.51 → stjames-0.0.52}/stjames/workflows/redox_potential.py +0 -0
  57. {stjames-0.0.51 → stjames-0.0.52}/stjames/workflows/scan.py +0 -0
  58. {stjames-0.0.51 → stjames-0.0.52}/stjames/workflows/spin_states.py +0 -0
  59. {stjames-0.0.51 → stjames-0.0.52}/stjames/workflows/tautomer.py +0 -0
  60. {stjames-0.0.51 → stjames-0.0.52}/stjames/workflows/workflow.py +0 -0
  61. {stjames-0.0.51 → stjames-0.0.52}/stjames.egg-info/SOURCES.txt +0 -0
  62. {stjames-0.0.51 → stjames-0.0.52}/stjames.egg-info/dependency_links.txt +0 -0
  63. {stjames-0.0.51 → stjames-0.0.52}/stjames.egg-info/requires.txt +0 -0
  64. {stjames-0.0.51 → stjames-0.0.52}/stjames.egg-info/top_level.txt +0 -0
  65. {stjames-0.0.51 → stjames-0.0.52}/tests/test_constraints.py +0 -0
  66. {stjames-0.0.51 → stjames-0.0.52}/tests/test_from_extxyz.py +0 -0
  67. {stjames-0.0.51 → stjames-0.0.52}/tests/test_molecule.py +0 -0
  68. {stjames-0.0.51 → stjames-0.0.52}/tests/test_pdb.py +0 -0
  69. {stjames-0.0.51 → stjames-0.0.52}/tests/test_rounding.py +0 -0
  70. {stjames-0.0.51 → stjames-0.0.52}/tests/test_settings.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.2
2
2
  Name: stjames
3
- Version: 0.0.51
3
+ Version: 0.0.52
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
@@ -1,6 +1,6 @@
1
1
  [project]
2
2
  name = "stjames"
3
- version = "0.0.51"
3
+ version = "0.0.52"
4
4
  description = "standardized JSON atom/molecule encoding scheme"
5
5
  readme = "README.md"
6
6
  requires-python = ">=3.11"
@@ -1,25 +1,25 @@
1
1
  """Docking workflow."""
2
2
 
3
- from typing import Self
3
+ from typing import Annotated
4
4
 
5
- from pydantic import BaseModel, ConfigDict, field_validator, model_validator
5
+ from pydantic import AfterValidator, ConfigDict, field_validator
6
6
 
7
- from ..molecule import Molecule
7
+ from ..base import Base, round_float
8
8
  from ..pdb import PDB
9
- from ..types import Vector3D
9
+ from ..types import UUID, Vector3D
10
10
  from .workflow import Workflow
11
11
 
12
12
 
13
- class Score(BaseModel):
13
+ class Score(Base):
14
14
  """
15
15
  Pose with its score.
16
16
 
17
17
  :param pose: conformation of the ligand when docked
18
- :param score: score of the pose
18
+ :param score: score of the pose, in kcal/mol
19
19
  """
20
20
 
21
- pose: Molecule
22
- score: float
21
+ pose: UUID | None # for calculation
22
+ score: Annotated[float, AfterValidator(round_float(3))]
23
23
 
24
24
 
25
25
  class DockingWorkflow(Workflow):
@@ -27,12 +27,15 @@ class DockingWorkflow(Workflow):
27
27
  Docking workflow.
28
28
 
29
29
  Inherited:
30
- :param initial_molecule: Molecule of interest (currently unused)
30
+ :param initial_molecule: Molecule of interest
31
31
  :param mode: Mode for workflow (currently unused)
32
32
 
33
33
  New:
34
34
  :param molecules: Molecules to dock (optional)
35
35
  :param smiles: SMILES strings of the ligands (optional)
36
+ :param do_csearch: whether to csearch starting structures
37
+ :param do_optimization: whether to optimize starting structures
38
+ :param conformers: UUIDs of optimized conformers
36
39
  :param target: PDB of the protein
37
40
  :param pocket: center (x, y, z) and size (x, y, z) of the pocket
38
41
 
@@ -42,12 +45,14 @@ class DockingWorkflow(Workflow):
42
45
 
43
46
  model_config = ConfigDict(arbitrary_types_allowed=True)
44
47
 
45
- molecules: list[Molecule] = []
46
- smiles: list[str] = []
48
+ do_csearch: bool = True
49
+ do_optimization: bool = True
50
+ conformers: list[UUID] = []
47
51
 
48
52
  target: PDB
49
53
  pocket: tuple[Vector3D, Vector3D]
50
54
 
55
+ do_pose_hydrogen_refinement: bool = True
51
56
  scores: list[Score] = []
52
57
 
53
58
  def __str__(self) -> str:
@@ -61,16 +66,6 @@ class DockingWorkflow(Workflow):
61
66
 
62
67
  return f"<{type(self).__name__} {target} {ligand}>"
63
68
 
64
- @model_validator(mode="after")
65
- def check_molecules(self) -> Self:
66
- """Check if molecules are provided."""
67
- if self.molecules and self.smiles:
68
- raise ValueError("Must provide only one of molecules or smiles, not both")
69
- elif not self.molecules and not self.smiles:
70
- raise ValueError("Must provide either molecules or smiles")
71
-
72
- return self
73
-
74
69
  @field_validator("pocket", mode="after")
75
70
  def validate_pocket(cls, pocket: tuple[Vector3D, Vector3D]) -> tuple[Vector3D, Vector3D]:
76
71
  center, size = pocket
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.2
2
2
  Name: stjames
3
- Version: 0.0.51
3
+ Version: 0.0.52
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
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes