Skip to content

Commit

Permalink
Merge pull request #165 from leeping/evaluator_test
Browse files Browse the repository at this point in the history
Use gradient evaluation for Evaluator test
  • Loading branch information
leeping authored Nov 24, 2019
2 parents b3b4dd1 + ca8c992 commit b60ed6e
Show file tree
Hide file tree
Showing 6 changed files with 172 additions and 293 deletions.
7 changes: 5 additions & 2 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,8 @@ install:

# If were using python 3.6 or higher and we're decrypting an OE key, install OFF toolkit and
# OETK (there aren't OFFTK packages for python<3.6)
- if [ ${PYTHON_VER} != "2.7" ] && [ ${PYTHON_VER} != "3.5" ] && [ "$TRAVIS_SECURE_ENV_VARS" == true ] ; then conda install --yes -c omnia -c openeye openforcefield openeye-toolkits propertyestimator; fi
- if [ ${PYTHON_VER} != "2.7" ] && [ ${PYTHON_VER} != "3.5" ] && [ "$TRAVIS_SECURE_ENV_VARS" == true ] ; then conda install --yes -c omnia -c openeye openforcefield openeye-toolkits; fi
- if [ ${PYTHON_VER} != "2.7" ] && [ ${PYTHON_VER} != "3.5" ] && [ ${PYTHON_VER} != "3.6" ] && [ "$TRAVIS_OS_NAME" == "linux" ] && [ "$TRAVIS_SECURE_ENV_VARS" == true ] ; then conda install --yes -c omnia -c openeye propertyestimator; fi

# Install Work Queue
- wget https://raw.githubusercontent.com/leeping/forcebalance/master/tools/install-cctools.sh
Expand Down Expand Up @@ -164,7 +165,9 @@ script:
- tar xvjf targets.tar.bz2
- ForceBalance very_simple.in
- cd -
- pytest --cov=forcebalance --cov-config=setup.cfg
- pytest --cov=forcebalance --cov-config=setup.cfg --durations=0
# Allow tests to run for up to 30 minutes
# - travis_wait 30 pytest --cov=forcebalance --cov-config=setup.cfg --durations=0
# - python test
# - py.test -v --cov=eex/ --durations=5

Expand Down
2 changes: 1 addition & 1 deletion src/optimizer.py
Original file line number Diff line number Diff line change
Expand Up @@ -640,7 +640,7 @@ def print_progress(itn, nx, nd, ng, clr, x, std, qual):
if ngd < self.convergence_gradient:
logger.info("Convergence criterion reached for gradient norm (%.2e)\n" % self.convergence_gradient)
ncrit += 1
if ndx < self.convergence_step and ITERATION > self.iterinit:
if ndx < self.convergence_step and ndx >= 0.0 and ITERATION > self.iterinit:
logger.info("Convergence criterion reached in step size (%.2e)\n" % self.convergence_step)
ncrit += 1
if stdfront < self.convergence_objective and len(X_hist) >= self.hist:
Expand Down
Loading

0 comments on commit b60ed6e

Please sign in to comment.