Skip to content

Commit

Permalink
For tests, use Python 3.10 stk,stko.
Browse files Browse the repository at this point in the history
  • Loading branch information
andrewtarzia committed Sep 27, 2024
1 parent 3e72ec1 commit a32eedc
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 11 deletions.
6 changes: 3 additions & 3 deletions docs/requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,9 @@ numpy
ipywidgets
matplotlib
ase==3.22.1
rdkit==2023.9.5
stk==2024.9.23.1
stko==v2024.8.29.1
rdkit==2023.9.4
stk==2022.6.17.0
stko==0.0.40

# required for the examples of chemiscope.explore
mace-torch
Expand Down
14 changes: 8 additions & 6 deletions python/examples/8-showing_custom_bonds.py
Original file line number Diff line number Diff line change
Expand Up @@ -134,10 +134,12 @@
# https://stko-docs.readthedocs.io/en/latest/

energy = stko.UFFEnergy()
analyser = stko.molecule_analysis.GeometryAnalyser()
shape_calc = stko.ShapeCalculator()
properties = {
"e": [energy.get_energy(molecule) for molecule in structures],
"rg": [analyser.get_radius_gyration(molecule) for molecule in structures],
"uffenergy": [energy.get_energy(molecule) for molecule in structures],
"aspheriticty": [
shape_calc.get_results(molecule).get_asphericity() for molecule in structures
],
}


Expand Down Expand Up @@ -175,7 +177,7 @@
frames=structures,
properties=properties,
meta=dict(name="Missing bonds by automation."),
settings=chemiscope.quick_settings(x="rg", y="e", color=""),
settings=chemiscope.quick_settings(x="aspheriticty", y="uffenergy", color=""),
)


Expand All @@ -198,8 +200,8 @@
properties=properties,
meta=dict(name="Added all stk bonds."),
settings=chemiscope.quick_settings(
x="rg",
y="e",
x="aspheriticty",
y="uffenergy",
color="",
structure_settings={
"shape": shape_string,
Expand Down
4 changes: 2 additions & 2 deletions python/examples/data/stk_3.mol
Original file line number Diff line number Diff line change
Expand Up @@ -173,8 +173,8 @@ M V30 165 H 5.7344 4.0818 -6.8141 0
M V30 166 H 7.2407 5.2573 -4.4052 0
M V30 167 H 5.6374 5.9354 -4.8815 0
M V30 168 H 6.0976 3.7143 -3.1964 0
M V30 169 Br 1.1870 0.0000 0.0000 0
M V30 170 Br -1.1870 0.0000 0.0000 0
M V30 169 Br 2.1870 0.0000 0.0000 0
M V30 170 Br -0.1870 0.0000 0.0000 0
M V30 END ATOM
M V30 BEGIN BOND
M V30 1 1 1 2
Expand Down

0 comments on commit a32eedc

Please sign in to comment.