Skip to content

Commit

Permalink
Merge branch 'main' into rmsd_inertia
Browse files Browse the repository at this point in the history
  • Loading branch information
aarongarrison authored Jul 22, 2024
2 parents 78c82ea + 88d4050 commit 7215509
Show file tree
Hide file tree
Showing 9 changed files with 45 additions and 39 deletions.
14 changes: 6 additions & 8 deletions .github/workflows/pytest.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,9 @@ name: Pytest
on:
push:
branches:
- "master"
- "main"
pull_request:
branches:
- "master"
- "main"

jobs:
Expand All @@ -17,12 +15,12 @@ jobs:
strategy:
matrix:
os: ["ubuntu-latest"]
python-version: ["3.7", "3.8"]
python-version: ["3.8", "3.10"]
defaults:
run:
shell: bash -l {0}
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4

- name: Additional info about the build
run: |
Expand All @@ -34,7 +32,7 @@ jobs:
uses: josStorer/[email protected]
id: current-time
- name: Cache conda env
uses: actions/cache@v3
uses: actions/cache@v4
id: cache
env:
# Increase this value to reset cache if mols.yml has not changed
Expand All @@ -49,7 +47,7 @@ jobs:

# More info on the whole conda setup: https://github.com/conda-incubator/setup-miniconda
- name: Setup Conda
uses: conda-incubator/setup-miniconda@v2
uses: conda-incubator/setup-miniconda@v3
id: conda-setup
with:
# mamba-version: "*" # uncomment to activate mamba
Expand Down Expand Up @@ -77,7 +75,7 @@ jobs:
pytest --doctest-modules --ignore=molSimplify/Informatics/MOF --ignore=molSimplify/Informatics/protein --ignore=molSimplify/Scripts/in_b3lyp_usetc.py --ignore=molSimplify/Informatics/jupyter_vis.py --ignore=molSimplify/Informatics/macrocycle_synthesis.py --ignore=molSimplify/Informatics/organic_fingerprints.py molSimplify
- name: Upload coverage report to codecov
uses: codecov/codecov-action@v3
uses: codecov/codecov-action@v4
with:
token: ${{ secrets.CODECOV_TOKEN }}
directory: ./coverage/reports/
Expand Down Expand Up @@ -111,7 +109,7 @@ jobs:
- uses: actions/checkout@v4

- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v4
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}

Expand Down
16 changes: 8 additions & 8 deletions .github/workflows/python-linter.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -11,11 +11,11 @@ jobs:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v3
- name: Set up Python 3.7
uses: actions/setup-python@v2
- uses: actions/checkout@v4
- name: Set up Python 3.8
uses: actions/setup-python@v5
with:
python-version: 3.7
python-version: 3.8
- name: Install dependencies
run: |
python -m pip install --upgrade pip
Expand Down Expand Up @@ -51,11 +51,11 @@ jobs:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v3
- name: Set up Python 3.7
uses: actions/setup-python@v2
- uses: actions/checkout@v4
- name: Set up Python 3.8
uses: actions/setup-python@v5
with:
python-version: 3.7
python-version: 3.8
- name: Install dependencies
run: |
python -m pip install --upgrade pip
Expand Down
2 changes: 1 addition & 1 deletion .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ repos:
- id: end-of-file-fixer
- id: trailing-whitespace
- repo: https://github.com/pycqa/flake8
rev: '7.0.0'
rev: '7.1.0'
hooks:
- id: flake8
args: ['--select=E9,F63,F7,F82', '--exclude=fragment_classes.py,frag_functionalizer.py,bridge_functionalizer.py']
2 changes: 1 addition & 1 deletion molSimplify/Ligands/ligands.dict
Original file line number Diff line number Diff line change
Expand Up @@ -183,7 +183,7 @@ ox:oxalate.mol,oxate,1 4,build bidentate,A,-2
oxo:oxygen.mol,oxo,0,build small,N,-2
pcy3:PCy3.mol,pcy3,0,build bulky big,BA,0
pentacyanopentadienide:pentacyanocyclopentadienide.mol,pcyanopent,1,build bulky,A,-1
pf3:phosphorustrifluoride.mol,pf3,1,build small,BA,0
pf3:pf3.mol2,pf3,1,build small,BA,0
ph2-:ph2-.mol,ph2-,0,build functionalize small,N,-1
ph3:ph3.mol,ph3,0,build functionalize small,N,0
phen:phen.mol,phen,9 12,build bidentate,BA,0
Expand Down
19 changes: 19 additions & 0 deletions molSimplify/Ligands/pf3.mol2
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
@<TRIPOS>MOLECULE
pf3.mol2
4 3 1
SMALL
PartialCharges
****
Generated from molSimplify

@<TRIPOS>ATOM
1 F1 1.215917934819222 0.0666657847598425 -0.005857293024108329 F 1 RES1 0.0
2 P1 2.7546239026034516 -0.2682925621616243 -0.034209056581309884 P.3 1 RES1 0.0
3 F2 3.1090617015157433 0.8313972878801463 -1.1045721415058223 F 1 RES1 0.0
4 F3 3.1090574085440688 0.635819556544132 1.2057809186362327 F 1 RES1 0.0
@<TRIPOS>BOND
1 1 2 1
1 2 3 1
1 2 4 1
@<TRIPOS>SUBSTRUCTURE
1 RES1 4
12 changes: 0 additions & 12 deletions molSimplify/Ligands/phosphorustrifluoride.mol

This file was deleted.

3 changes: 1 addition & 2 deletions molSimplify/Scripts/rmsd.py
Original file line number Diff line number Diff line change
Expand Up @@ -486,7 +486,7 @@ def align_rmsd_project(mol_p, mol_q, rotation: str = "kabsch",
- projecting the coordinates onto the principal axes
Note that the projection may lead to reflections, which will break chirality.
- reordering x, y, z such that Ixx < Iyy < Izz
(will allow for 180degree rotations about x, y, z, as well as
(will allow for 180 degree rotations about x, y, z, as well as
reflections about the xy, xz, yz, and all three of those planes)
Parameters
Expand Down Expand Up @@ -629,7 +629,6 @@ def align_rmsd_rotate(mol_p, mol_q, rotation: str = "kabsch",

return rmsd


def test_case():
p_atoms = np.array(["N", "H", "H", "H"])
q_atoms = np.array(["H", "N", "H", "H"])
Expand Down
4 changes: 2 additions & 2 deletions molSimplify/python_nn/clf_analysis_tool.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# import matplotlib.pyplot as plt
from typing import Callable
import numpy as np
from sklearn.metrics.pairwise import pairwise_distances
from packaging import version
Expand Down Expand Up @@ -105,7 +105,7 @@ def get_layer_outputs(model, layer_index, input,
[model.layers[layer_index].output])
nn_outputs = get_outputs([input, training_flag])[0]
else:
partial_model = Model(model.inputs, model.layers[layer_index].output)
partial_model = Model(model.inputs, model.layers[layer_index].output) # type: Callable
nn_outputs = partial_model([input], training=training_flag).numpy() # runs the model in training mode
return nn_outputs

Expand Down
12 changes: 7 additions & 5 deletions pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[project]
name = "molSimplify"
version = "v1.7.4"
version = "v1.7.5"
license = {file = "LICENSE"}
readme = "README.md"
dependencies = [
Expand Down Expand Up @@ -41,10 +41,12 @@ build-backend = "setuptools.build_meta"
where = ["."]

[tool.setuptools.package-data]
"molSimplify.Data" = ["*.dat"]
"molSimplify.Bind" = ["*.dat"]
"molSimplify.Ligands" = ["*.dict", "*.mol", "*.xyz", "*.smi"]
"molSimplify.Bind" = ["*.dat", "*.dict"]
"molSimplify.Cores" = ["*.dict"]
"molSimplify.Data" = ["*.dat", "*.dict"]
"molSimplify.Ligands" = ["*.dict", "*.mol", "*.smi", "*.xyz"]
"molSimplify.Substrates" = ["*.dict", "*.mol", "*.xyz"]
"molSimplify.icons" = ["*.png"]
"molSimplify.python_nn" = ["*.csv"]
"molSimplify.python_krr" = ["*.csv"]
"molSimplify.python_nn" = ["*.csv"]
"molSimplify.tf_nn" = ["*/*"]

0 comments on commit 7215509

Please sign in to comment.