0.4.post1: test failures
See original GitHub issueHi,
I am just trying to update the Debian package to 0.4.post1, but get a number of test failures due to limited accuracy:
platform linux -- Python 3.7.3, pytest-3.10.1, py-1.8.0, pluggy-0.8.0 -- /usr/bin/python3
cachedir: .pytest_cache
Matplotlib: 3.0.2
Freetype: 2.9.1
Running tests with astroMl version 0.4.post1.
Running tests in astroML.
Date: 2019-07-31T15:28:23
Platform: Linux-4.19.0-5-amd64-x86_64-with-debian-bullseye-sid
Executable: /usr/bin/python3
Full Python Version:
3.7.3 (default, Apr 3 2019, 05:39:12)
[GCC 8.3.0]
encodings: sys: utf-8, locale: UTF-8, filesystem: utf-8
byteorder: little
float info: dig: 15, mant_dig: 15
Numpy: 1.16.2
Scipy: 1.1.0
Matplotlib: 3.0.2
Cython: 0.29.2
Astropy: 3.1.2
scikit-learn: 0.20.2
astroML_addons: not available
astropy_helpers: 3.1.1
Using Astropy options: remote_data: none.
rootdir: /home/oles/Projects/2011/debian/python/astropy/astroml, inifile: setup.cfg
plugins: remotedata-0.3.1, openfiles-0.3.2, mpl-0.10, doctestplus-0.2.0, arraydiff-0.3
[…]
=================================== FAILURES ===================================
___________ [doctest] astroML.datasets.LIGO_bigdog.fetch_LIGO_bigdog ___________
084 The data is 10 seconds of measurements from three sites, along with
085 the time of each measurement.
086
087 Examples
088 --------
089 >>> from astroML.datasets import fetch_LIGO_bigdog
090 >>> data = fetch_LIGO_bigdog() # doctest: +IGNORE_OUTPUT
091 >>> print(data.dtype.names)
092 ('t', 'Hanford', 'Livingston', 'Virgo')
093 >>> print(data['t'][:3])
Expected:
[ 0.00000000e+00 6.10400000e-05 1.22070000e-04]
Got:
[0.0000e+00 6.1040e-05 1.2207e-04]
/home/oles/Projects/2011/debian/python/astropy/astroml/astroML/datasets/LIGO_bigdog.py:93: DocTestFailure
_____ [doctest] astroML.datasets.sdss_S82standards.fetch_sdss_S82standards _____
099 Herr H-band error
100 K K-band magnitude
101 Kerr K-band error
102 theta difference between SDSS and 2MASS position (arcsec)
103
104 Examples
105 --------
106 >>> data = fetch_sdss_S82standards() # doctest: +IGNORE_OUTPUT
107 >>> u_g = data['mmed_u'] - data['mmed_g']
108 >>> print(u_g[:4])
Expected:
[-22.23500061 1.34900093 1.43799973 2.08200073]
Got:
[-22.235 1.3490009 1.4379997 2.0820007]
/home/oles/Projects/2011/debian/python/astropy/astroml/astroML/datasets/sdss_S82standards.py:108: DocTestFailure
_________ [doctest] astroML.datasets.sdss_specgals.fetch_sdss_specgals _________
073
074 Examples
075 --------
076 >>> from astroML.datasets import fetch_sdss_specgals
077 >>> data = fetch_sdss_specgals() # doctest: +IGNORE_OUTPUT
078 >>> data.shape # number of objects in dataset
079 (661598,)
080 >>> data.dtype.names[:5] # first five column names
081 ('ra', 'dec', 'mjd', 'plate', 'fiberID')
082 >>> print(data['ra'][:3]) # first three RA values
Expected:
[ 146.71419105 146.74414186 146.62857334]
Got:
[146.71419105 146.74414186 146.62857334]
/home/oles/Projects/2011/debian/python/astropy/astroml/astroML/datasets/sdss_specgals.py:82: DocTestFailure
_____________ [doctest] astroML.datasets.sdss_sspp.fetch_sdss_sspp _____________
095
096 Examples
097 --------
098 >>> from astroML.datasets import fetch_sdss_sspp
099 >>> data = fetch_sdss_sspp() # doctest: +IGNORE_OUTPUT
100 >>> data.shape # number of objects in dataset
101 (327260,)
102 >>> print(data.dtype.names[:5]) # names of the first five columns
103 ('ra', 'dec', 'Ar', 'upsf', 'uErr')
104 >>> print(data['ra'][:1]) # first RA value
Expected:
[49.6275024]
Got:
[49.627502]
/home/oles/Projects/2011/debian/python/astropy/astroml/astroML/datasets/sdss_sspp.py:104: DocTestFailure
_____ [doctest] astroML.density_estimation.empirical.EmpiricalDistribution _____
065 ----------
066 data : one-dimensional array
067 input data
068
069 Examples
070 --------
071 >>> import numpy as np
072 >>> np.random.seed(0)
073 >>> x = np.random.normal(size=10000) # normally-distributed variables
074 >>> x.mean(), x.std()
Expected:
(-0.018433720158265783, 0.98755656817612003)
Got:
(-0.018433720158265818, 0.9875565681761208)
/home/oles/Projects/2011/debian/python/astropy/astroml/astroML/density_estimation/empirical.py:74: DocTestFailure
___________________ [doctest] astroML.utils.utils.logsumexp ____________________
011
012 Returns log(sum(exp(arr))) while minimizing the possibility of
013 over/underflow.
014
015 Examples
016 --------
017
018 >>> import numpy as np
019 >>> a = np.arange(10)
020 >>> np.log(np.sum(np.exp(a)))
Expected:
9.4586297444267107
Got:
9.45862974442671
Issue Analytics
- State:
- Created 4 years ago
- Comments:5 (5 by maintainers)
Top Results From Across the Web
Python 3.8 test failures · Issue #730 · sherpa/sherpa - GitHub
1 ) candidate on Mac OS (Mojave) using python 3.8.3 with astropy 4.0.1.post1, matplotlib 3.2.2, ipython 7.16.1, numpy 1.18.5 The smoke tests ......
Read more >Example Ed Posts — CAPP 30121 - Computer Science with ...
Example Post #1: In this post, the student provided the full output of running the tests, and confirmed that their code had been...
Read more >FreshPorts -- The Place For Ports - Sanity Test Failures
These are the sanity test failures found by FreshPorts. Sanity tests have been in place for several years, but have only been saved...
Read more >astroml: (autopkgtest) needs update for new version of numpy ...
In tabular form: pass fail numpy from testing 1:1.18.3-1 astroml from testing 0.4.post1-5 all others from testing from testing I copied some ...
Read more >Test Post #1 | Controllerless Networks - Airheads Community
AP Register fail because of Image mismatch, 2, 6, 2022-06-17T07:04:00 by pburns ... Test what features are disabled in lower power modes ......
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
I can confirm that it works with doctestplus 0.3.0. I’ll update the dependencies accordingly, thanks.
@olebole - is there any chance to upgrade
pytest-doctestplus
? Locally, using 0.3.0 I see no failures, while with 0.2.0 I can reproduce the failures from above.