From 37eff0048e282a996b1c67da614dcd85078de045 Mon Sep 17 00:00:00 2001 From: Moritz Huebner <moritz.huebner@ligo.org> Date: Thu, 19 Dec 2019 22:51:13 -0600 Subject: [PATCH] Resolve "Tests on master failing due to new solar mass in LAL" --- .gitlab-ci.yml | 14 +++++++------- bilby/core/utils.py | 4 ++-- test/gw_likelihood_test.py | 4 ++-- 3 files changed, 11 insertions(+), 11 deletions(-) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index c51eb07ec..7fa48c82c 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -71,13 +71,13 @@ python-3.7: - docs/_build/html/ # test example on python 3.6 -python-3.6: - stage: test - image: bilbydev/v2-dockerfile-test-suite-python36 - script: - - python -m pip install . - - - pytest +#python-3.6: +# stage: test +# image: bilbydev/v2-dockerfile-test-suite-python36 +# script: +# - python -m pip install . +# +# - pytest # Tests run at a fixed schedule rather than on push scheduled-python-3.7: diff --git a/bilby/core/utils.py b/bilby/core/utils.py index c5f9a9709..fd42cdd59 100644 --- a/bilby/core/utils.py +++ b/bilby/core/utils.py @@ -20,10 +20,10 @@ import pandas as pd logger = logging.getLogger('bilby') -# Constants: values taken from LAL cd65f38ce43cef3a1dec217c060de25caf99bf14 +# Constants: values taken from LAL 505df9dd2e69b4812f1e8eee3a6d468ba7f80674 speed_of_light = 299792458.0 # m/s parsec = 3.085677581491367e+16 # m -solar_mass = 1.9885469549614615e+30 # Kg +solar_mass = 1.9884099021470415e+30 # Kg radius_of_earth = 6378136.6 # m _TOL = 14 diff --git a/test/gw_likelihood_test.py b/test/gw_likelihood_test.py index a63706b0f..e912005d1 100644 --- a/test/gw_likelihood_test.py +++ b/test/gw_likelihood_test.py @@ -45,7 +45,7 @@ class TestBasicGWTransient(unittest.TestCase): """Test log likelihood matches precomputed value""" self.likelihood.log_likelihood() self.assertAlmostEqual(self.likelihood.log_likelihood(), - -4055.25243177871, 3) + -4055.265194950631, 3) def test_log_likelihood_ratio(self): """Test log likelihood ratio returns the correct value""" @@ -114,7 +114,7 @@ class TestGWTransient(unittest.TestCase): """Test log likelihood matches precomputed value""" self.likelihood.log_likelihood() self.assertAlmostEqual(self.likelihood.log_likelihood(), - -4055.25243177871, 3) + -4055.265194950631, 3) def test_log_likelihood_ratio(self): """Test log likelihood ratio returns the correct value""" -- GitLab