Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add small molecule repex consistency tests #1065

Merged
merged 96 commits into from
Apr 28, 2023
Merged
Show file tree
Hide file tree
Changes from 74 commits
Commits
Show all changes
96 commits
Select commit Hold shift + click to select a range
f48a588
add neutral test
zhang-ivy Jun 24, 2022
4f82361
add small molecule tests
zhang-ivy Jun 24, 2022
6c035db
remove charge test
zhang-ivy Jun 30, 2022
74bcf38
add charge test
zhang-ivy Jul 2, 2022
6e8893b
add guest mol2s
zhang-ivy Jul 2, 2022
6a0ff93
Merge branch 'main' into add-small-molecule-test
zhang-ivy Jul 6, 2022
406fe70
fix charge changing test
zhang-ivy Jul 6, 2022
19a3796
Merge branch 'add-small-molecule-test' of ssh://github.com/choderalab…
zhang-ivy Jul 6, 2022
5590a3c
add cache
zhang-ivy Jul 6, 2022
f39c3af
make sure lrc is set correctly
zhang-ivy Jul 6, 2022
82f2960
Small code cleanup. Fix docstring. Remove unused imports.
ijpulidos Aug 15, 2022
9356b63
Using LangevinDynamicsMove instead of LangevinSplittingDynamicsMove. …
ijpulidos Aug 15, 2022
4c5ab63
Merge branch 'main' into add-small-molecule-test
ijpulidos Aug 15, 2022
105e71b
Only using LangevinDynamicsMove in tests. Others stay the same as bef…
ijpulidos Aug 16, 2022
4406b4a
Merge branch 'add-small-molecule-test' of github.com:choderalab/perse…
ijpulidos Aug 16, 2022
1e90291
Making sure the CPU platform is used in geometry engine.
ijpulidos Aug 19, 2022
2e8248c
Adjusting repex tests parameters for better performance.
ijpulidos Aug 19, 2022
181a639
Revert "Making sure the CPU platform is used in geometry engine."
ijpulidos Aug 22, 2022
12a9abd
Keep the convergence criteria to be 6*dDDG
ijpulidos Aug 24, 2022
8c6936b
Merge branch 'main' into add-small-molecule-test
ijpulidos Aug 24, 2022
0cf7dfe
Merge branch 'add-small-molecule-test' of github.com:choderalab/perse…
ijpulidos Aug 29, 2022
cd51c64
Merge branch 'main' into add-small-molecule-test
ijpulidos Sep 12, 2022
fad3d80
Increasing n steps for move apply. Decreasing number of iterations
ijpulidos Nov 22, 2022
e1bcb91
Merge branch 'main' into add-small-molecule-test
ijpulidos Jan 17, 2023
4827342
Trying running self-hosted GPU tests on PR.
ijpulidos Jan 17, 2023
71231e8
Merge branch 'main' into add-small-molecule-test
ijpulidos Jan 17, 2023
64ddf34
switch to using openmm rc
mikemhenry Jan 25, 2023
bf3c710
Merge branch 'feat/add_new_openmm_rc' into add-small-molecule-test
mikemhenry Jan 26, 2023
1c7b276
Merge branch 'main' into add-small-molecule-test
mikemhenry Jan 26, 2023
3531390
Testing phenol-paracetamol transformation. 250 steps, 1000 iterations…
ijpulidos Feb 7, 2023
8da5a9f
Quick testing new instance type for gpu tests.
ijpulidos Feb 10, 2023
dc7861a
Trying own fork with fix with unique instance name
ijpulidos Feb 13, 2023
3bb64f6
Going back to original runner repo.
ijpulidos Feb 13, 2023
1f979cd
add us-east-1a subnet
mikemhenry Feb 14, 2023
3a3f280
fix vim typo
mikemhenry Feb 14, 2023
ae6f222
try p2.xlarge first
mikemhenry Feb 14, 2023
cc967cc
Added us-east-1b subnet
mikemhenry Feb 14, 2023
4ed236a
Added us-east-1c subnet
mikemhenry Feb 14, 2023
c2cb3b6
Added us-east-1e subnet
mikemhenry Feb 14, 2023
57cbff9
Added us-east-1f subnet
mikemhenry Feb 14, 2023
aaea343
go to next step even if we can't provision an instance
mikemhenry Feb 14, 2023
7c6edf2
switch to g4dn.xlarge
mikemhenry Feb 14, 2023
a896560
switch to using once subnet for now while testing new ami
mikemhenry Feb 14, 2023
8f866c0
fix comment error
mikemhenry Feb 14, 2023
319a3e4
make sure we stop instances if they fail
mikemhenry Feb 14, 2023
8c6155c
bump ci
mikemhenry Feb 15, 2023
fbc40b4
bump ci
mikemhenry Feb 15, 2023
8c86bfb
bump ci
mikemhenry Feb 15, 2023
425c85f
switch to using new ami
mikemhenry Feb 15, 2023
7c4da57
try new subnet and sg
mikemhenry Feb 15, 2023
0cd0e85
bump ci
mikemhenry Feb 15, 2023
9bd284a
bump ci
mikemhenry Feb 15, 2023
59ac33f
switch to using micromamba
mikemhenry Feb 15, 2023
6d1f385
remove unused channels and clean up CI workflow a bit
mikemhenry Feb 15, 2023
e65ed05
debug provision-with-micromamba
mikemhenry Feb 15, 2023
c07cf0b
see if python 3.10 fixes it
mikemhenry Feb 15, 2023
79bfc18
try latest version
mikemhenry Feb 15, 2023
1dfc392
try older version
mikemhenry Feb 15, 2023
d70755c
Set default shell
mikemhenry Feb 15, 2023
44c7a5e
switch to newest version
mikemhenry Feb 15, 2023
74b5cb7
switch to a different action
mikemhenry Feb 15, 2023
2253fc9
See if this fixes the unbound home var
mikemhenry Feb 15, 2023
2bd94e9
see if this fixes the issue with home not being set
mikemhenry Feb 15, 2023
1e569ab
Testing GPU platforms specifically, debugging purposes
ijpulidos Feb 16, 2023
30e4598
timeout of 20 hrs instead of the 6 hrs default
ijpulidos Feb 16, 2023
97b1958
back to testing everything
ijpulidos Feb 16, 2023
902161d
Putting timeout of 20 hrs in correct place/job.
ijpulidos Feb 17, 2023
f5bf4be
Using specific tagged url for tyk2 tests
ijpulidos Feb 17, 2023
cbac788
Merge branch 'main' into add-small-molecule-test
ijpulidos Feb 17, 2023
e924ccb
fix cudatoolkit version
mikemhenry Feb 17, 2023
3c8e9e7
remove extra code we don't need anymore
mikemhenry Feb 18, 2023
349696f
skip test for now, need better system to test with
mikemhenry Feb 18, 2023
aa7ca14
let codecov fail, also update the action
mikemhenry Feb 20, 2023
a7ffaef
only run on commit, on demand, on weekly
mikemhenry Feb 20, 2023
0413021
Using bootstrapping from MBAR to compute errors
ijpulidos Feb 24, 2023
9753a5d
Merge branch 'main' into add-small-molecule-test
mikemhenry Mar 1, 2023
2be975f
Merge branch 'main' into add-small-molecule-test
mikemhenry Mar 16, 2023
9ca6560
Those damn signs! Making it less prone to sign errors.
ijpulidos Apr 12, 2023
8977167
Better naming for quantities
ijpulidos Apr 17, 2023
59dbcea
Making sure we test using decorrelated samples
ijpulidos Apr 17, 2023
3421d3a
Merge branch 'main' into add-small-molecule-test
ijpulidos Apr 17, 2023
d953e62
Swapping tests, now correct order.
ijpulidos Apr 18, 2023
280ebbb
use micromamba
mikemhenry Apr 19, 2023
af484f6
micromamba thowing a fit about oPtIonS iT dOeSn'T uNDerStAnd
mikemhenry Apr 19, 2023
b66dd53
Merge branch 'main' into add-small-molecule-test
mikemhenry Apr 20, 2023
c9bdae9
Changing back the transformation order to the correct one.
ijpulidos Apr 20, 2023
629b20e
Correct comparison charge mutation. Naming cleanup
ijpulidos Apr 20, 2023
1f7e414
Better naming. Minor indenting cleanup.
ijpulidos Apr 20, 2023
7e5be5b
Removing misplaced quotes, my bad!
ijpulidos Apr 21, 2023
15f24c0
Update .github/workflows/self-hosted-gpu-test.yml
mikemhenry Apr 21, 2023
2467f82
Merge branch 'add-small-molecule-test' of github.com:choderalab/perse…
ijpulidos Apr 26, 2023
2fd2a2a
Removing deprecated comment
ijpulidos Apr 26, 2023
693f41c
Lowering the number of steps per iteration to decrease run times.
ijpulidos Apr 26, 2023
ad8d805
Merge branch 'main' into add-small-molecule-test
ijpulidos Apr 26, 2023
aa6b2c6
removing commented/unused line
ijpulidos Apr 27, 2023
7b16afc
Update .github/workflows/self-hosted-gpu-test.yml
mikemhenry Apr 28, 2023
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 5 additions & 5 deletions .github/workflows/CI.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ jobs:
fail-fast: false
matrix:
python-version: [3.8, 3.9, "3.10"]
openmm: ["nightly", "7.7", "beta"]
openmm: ["rc", "7.7", "beta"]
exclude:
- python-version: "3.10"
openmm: "7.6"
Expand All @@ -48,7 +48,7 @@ jobs:
with:
python-version: ${{ matrix.python-version }}
environment-file: devtools/conda-envs/test_env.yaml
channels: jaimergp/label/unsupported-cudatoolkit-shim,conda-forge,defaults,omnia-dev,openeye
channels: jaimergp/label/unsupported-cudatoolkit-shim,conda-forge,openeye
activate-environment: test
auto-update-conda: true
auto-activate-base: false
Expand All @@ -60,9 +60,9 @@ jobs:
shell: bash -l {0}
run: |
case ${{ matrix.openmm }} in
nightly)
echo "Using nightly dev build of OpenMM."
conda install -y -c omnia-dev openmm --override-channels --force-reinstall
rc)
echo "Using rc build of OpenMM."
conda install -y -c conda-forge/label/openmm_rc openmm==8.0.0rc2 --override-channels --force-reinstall
echo "Using beta build of openeye toolkit"
conda install -y -c openeye/label/beta openeye-toolkits --override-channels --force-reinstall;;
beta)
Expand Down
48 changes: 25 additions & 23 deletions .github/workflows/self-hosted-gpu-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,11 @@ name: self-hosted-gpu-test
on:
push:
branches:
- master
- main
workflow_dispatch:
schedule:
# nightly tests
- cron: "0 0 * * *"
# weekly tests
- cron: "0 0 * * SUN"
mikemhenry marked this conversation as resolved.
Show resolved Hide resolved
jobs:
start-runner:
name: Start self-hosted EC2 runner
Expand All @@ -22,54 +21,61 @@ jobs:
aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID }}
aws-secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
aws-region: ${{ secrets.AWS_REGION }}
- name: Start EC2 runner
- name: Try to start EC2 runner
id: start-ec2-runner
uses: machulav/ec2-github-runner@main
with:
mode: start
github-token: ${{ secrets.GH_PERSONAL_ACCESS_TOKEN }}
ec2-image-id: ami-034abd52dd90b8023
ec2-instance-type: p2.xlarge
subnet-id: subnet-0e82552b8c708a999
security-group-id: sg-0589e74ec03965add
ec2-image-id: ami-04d16a12bbc76ff0b
ec2-instance-type: g4dn.xlarge
subnet-id: subnet-0dee8543e12afe0cd # us-east-1a
security-group-id: sg-0f9809618550edb98
# iam-role-name: self-hosted-runner # optional, requires additional permissions
aws-resource-tags: > # optional, requires additional permissions
[
{"Key": "Name", "Value": "ec2-github-runner"},
{"Key": "GitHubRepository", "Value": "${{ github.repository }}"}
]

do-the-job:
name: Do the job on the runner
needs: start-runner # required to start the main job when the runner is ready
runs-on: ${{ needs.start-runner.outputs.label }} # run the job on the newly created runner
timeout-minutes: 1200 # 20 hrs
env:
TEST_MODE: GPU
OPENMM: ${{ matrix.cfg.openmm }}
mikemhenry marked this conversation as resolved.
Show resolved Hide resolved
OE_LICENSE: ${{ github.workspace }}/oe_license.txt
HOME: /home/ec2-user

defaults:
run:
shell: bash -l {0}
steps:
- name: setup env
run: |
echo $HOME
export HOME=/home/ec2-user
echo $HOME

- uses: actions/checkout@v2
- uses: conda-incubator/setup-miniconda@v2
with:
python-version: 3.9
channels: conda-forge,omnia-dev,openeye
python-version: "3.10"
environment-file: devtools/conda-envs/test_env.yaml
show-channel-urls: true
auto-activate-base: false
channels: conda-forge,openeye
activate-environment: test
miniforge-version: latest
auto-update-conda: true
auto-activate-base: false
show-channel-urls: true
channel-priority: true
miniforge-variant: Mambaforge

- name: Refine test env
shell: bash -l {0}
run: |
conda install -y cudatoolkit==11.0.3 openmm>=7.7
mamba install -y cudatoolkit==11.7 openmm>=8.0

- name: Additional info about the build
shell: bash -l {0}
run: |
uname -a
df -h
Expand All @@ -80,26 +86,22 @@ jobs:
python -m openmm.testInstallation

- name: Install package
shell: bash -l {0}
run: |
python -m pip install --no-deps -v .

- name: Environment Information
shell: bash -l {0}
run: |
conda info -a
conda list

- name: Decrypt OpenEye license
shell: bash -l {0}
env:
OE_LICENSE_TEXT: ${{ secrets.OE_LICENSE }}
run: |
echo "${OE_LICENSE_TEXT}" > ${OE_LICENSE}
python -c "import openeye; assert openeye.oechem.OEChemIsLicensed(), 'OpenEye license checks failed!'"

- name: Test the package
shell: bash -l {0}
run: |
export TRAVIS=true
conda list --explicit
Expand All @@ -108,10 +110,10 @@ jobs:
- name: Codecov
if: ${{ github.repository == 'choderalab/perses'
&& github.event != 'schedule' }}
uses: codecov/codecov-action@v1
uses: codecov/codecov-action@v3
with:
file: ./coverage.xml
fail_ci_if_error: true
fail_ci_if_error: false

stop-runner:
name: Stop self-hosted EC2 runner
Expand Down
3 changes: 0 additions & 3 deletions devtools/conda-envs/test_env.yaml
Original file line number Diff line number Diff line change
@@ -1,9 +1,6 @@
name: test
channels:
- jaimergp/label/unsupported-cudatoolkit-shim
- conda-forge
- defaults
- omnia-dev
- openeye
dependencies:
- arsenic
Expand Down
2 changes: 1 addition & 1 deletion perses/app/relative_setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -365,7 +365,7 @@ def __init__(self,
spectator_mol = generate_unique_atom_names(spectator_mol)
self._spectator_molecules.append(spectator_mol)
# add this to a small molecule register
molecules.append(Molecule.from_openeye(spectator_mol,allow_undefined_stereo=True))
self._molecules.append(Molecule.from_openeye(spectator_mol,allow_undefined_stereo=True))
self._spectator_positions.append(extractPositionsFromOEMol(spectator_mol))
spectator_topology = forcefield_generators.generateTopologyFromOEMol(spectator_mol)
self._spectator_md_topologies.append(md.Topology.from_openmm(spectator_topology))
Expand Down
4 changes: 2 additions & 2 deletions perses/tests/test_relative.py
Original file line number Diff line number Diff line change
Expand Up @@ -1135,14 +1135,14 @@ def concatenate_files(input_files, output_file):
base_repo_url = "https://github.com/openforcefield/protein-ligand-benchmark"
ligand_files = []
for ligand in ['lig_ejm_42', 'lig_ejm_54']:
ligand_url = f"{base_repo_url}/raw/main/data/2020-02-07_tyk2/02_ligands/{ligand}/crd/{ligand}.sdf"
ligand_url = f"{base_repo_url}/raw/0.2.1/data/2020-02-07_tyk2/02_ligands/{ligand}/crd/{ligand}.sdf"
ligand_file = retrieve_file_url(ligand_url)
ligand_files.append(ligand_file)
concatenate_files(ligand_files, os.path.join(temp_dir, 'ligands.sdf'))
ligands_filename = os.path.join(temp_dir, 'ligands.sdf')

# Retrieve host PDB
pdb_url = f"{base_repo_url}/raw/main/data/2020-02-07_tyk2/01_protein/crd/protein.pdb"
pdb_url = f"{base_repo_url}/raw/0.2.1/data/2020-02-07_tyk2/01_protein/crd/protein.pdb"
host_pdb = retrieve_file_url(pdb_url)

# Generate topology proposal, old/new positions
Expand Down
Loading