Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.debian.bugs.dist > #1050315
| From | Adrian Bunk <bunk@debian.org> |
|---|---|
| Newsgroups | linux.debian.bugs.dist |
| Subject | Bug#983758: python-xarray: autopkgtest regression on several architectures |
| Date | 2021-03-01 13:10 +0100 |
| Message-ID | <BNPx7-6EV-1@gated-at.bofh.it> (permalink) |
| Organization | linux.* mail to news gateway |
Source: python-xarray
Version: 0.17.0-1
Severity: serious
https://ci.debian.net/data/autopkgtest/testing/arm64/p/python-xarray/10765498/log.gz
https://ci.debian.net/data/autopkgtest/testing/arm64/p/python-xarray/10765498/log.gz
...
=================================== FAILURES ===================================
_______________________ TestDataArray.test_pad_constant ________________________
self = <xarray.tests.test_dataarray.TestDataArray object at 0xeeed3e98>
def test_pad_constant(self):
ar = DataArray(np.arange(3 * 4 * 5).reshape(3, 4, 5))
actual = ar.pad(dim_0=(1, 3))
expected = DataArray(
np.pad(
np.arange(3 * 4 * 5).reshape(3, 4, 5).astype(np.float32),
mode="constant",
pad_width=((1, 3), (0, 0), (0, 0)),
constant_values=np.nan,
)
)
assert actual.shape == (7, 4, 5)
assert_identical(actual, expected)
ar = xr.DataArray([9], dims="x")
actual = ar.pad(x=1)
expected = xr.DataArray([np.NaN, 9, np.NaN], dims="x")
assert_identical(actual, expected)
actual = ar.pad(x=1, constant_values=1.23456)
expected = xr.DataArray([1, 9, 1], dims="x")
assert_identical(actual, expected)
if LooseVersion(np.__version__) >= "1.20":
with pytest.raises(ValueError, match="cannot convert float NaN to integer"):
ar.pad(x=1, constant_values=np.NaN)
else:
actual = ar.pad(x=1, constant_values=np.NaN)
expected = xr.DataArray(
[-9223372036854775808, 9, -9223372036854775808], dims="x"
)
> assert_identical(actual, expected)
E AssertionError: Left and right DataArray objects are not identical
E
E Differing values:
E L
E array([0, 9, 0])
E R
E array([-9223372036854775808, 9, -9223372036854775808],
E dtype=int64)
/usr/lib/python3/dist-packages/xarray/tests/test_dataarray.py:4523: AssertionError
=============================== warnings summary ===============================
...
https://ci.debian.net/data/autopkgtest/testing/i386/p/python-xarray/10765494/log.gz
...
=================================== FAILURES ===================================
_______________________ TestDataArray.test_pad_constant ________________________
self = <xarray.tests.test_dataarray.TestDataArray object at 0xedd27b20>
def test_pad_constant(self):
ar = DataArray(np.arange(3 * 4 * 5).reshape(3, 4, 5))
actual = ar.pad(dim_0=(1, 3))
expected = DataArray(
np.pad(
np.arange(3 * 4 * 5).reshape(3, 4, 5).astype(np.float32),
mode="constant",
pad_width=((1, 3), (0, 0), (0, 0)),
constant_values=np.nan,
)
)
assert actual.shape == (7, 4, 5)
assert_identical(actual, expected)
ar = xr.DataArray([9], dims="x")
actual = ar.pad(x=1)
expected = xr.DataArray([np.NaN, 9, np.NaN], dims="x")
assert_identical(actual, expected)
actual = ar.pad(x=1, constant_values=1.23456)
expected = xr.DataArray([1, 9, 1], dims="x")
assert_identical(actual, expected)
if LooseVersion(np.__version__) >= "1.20":
with pytest.raises(ValueError, match="cannot convert float NaN to integer"):
ar.pad(x=1, constant_values=np.NaN)
else:
actual = ar.pad(x=1, constant_values=np.NaN)
expected = xr.DataArray(
[-9223372036854775808, 9, -9223372036854775808], dims="x"
)
> assert_identical(actual, expected)
E AssertionError: Left and right DataArray objects are not identical
E
E Differing values:
E L
E array([-2147483648, 9, -2147483648])
E R
E array([-9223372036854775808, 9, -9223372036854775808],
E dtype=int64)
/usr/lib/python3/dist-packages/xarray/tests/test_dataarray.py:4523: AssertionError
=============================== warnings summary ===============================
...
Back to linux.debian.bugs.dist | Previous | Next | Find similar | Unroll thread
Bug#983758: python-xarray: autopkgtest regression on several architectures Adrian Bunk <bunk@debian.org> - 2021-03-01 13:10 +0100
csiph-web