-
Notifications
You must be signed in to change notification settings - Fork 51
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
test fixes #564
base: main
Are you sure you want to change the base?
test fixes #564
Changes from all commits
7530cdf
cc6bff5
af352eb
c69e974
2acb1fd
33b2c40
66e3991
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -46,19 +46,6 @@ | |
[f"C:{i}" for i in range(10)], # This is the actual metadata | ||
(None, None, None), | ||
), | ||
pytest.param( | ||
# This is the same file as the first file, but it is not tiled | ||
# This should throw and error since it is not tiled | ||
"s_1_t_1_c_1_z_1.ome.tiff", | ||
None, | ||
None, | ||
None, | ||
None, | ||
None, | ||
None, | ||
None, | ||
marks=pytest.mark.xfail(raises=exceptions.UnsupportedFileFormatError), | ||
), | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. just wondering, why remove these two? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Reading these files with latest libraries does not raise Error |
||
pytest.param( | ||
"example.txt", | ||
None, | ||
|
@@ -70,17 +57,6 @@ | |
None, | ||
marks=pytest.mark.xfail(raises=exceptions.UnsupportedFileFormatError), | ||
), | ||
pytest.param( | ||
"s_1_t_1_c_2_z_1.lif", | ||
None, | ||
None, | ||
None, | ||
None, | ||
None, | ||
None, | ||
None, | ||
marks=pytest.mark.xfail(raises=exceptions.UnsupportedFileFormatError), | ||
), | ||
], | ||
) | ||
def test_ome_tiff_reader( | ||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -21,10 +21,7 @@ def check_values( | |
) -> None: | ||
for i, s in enumerate(reader.scenes): | ||
reader.set_scene(s) | ||
assert np.all( | ||
reference.isel(S=i).data == reader.xarray_dask_data.data | ||
).compute() | ||
assert np.all(reference.isel(S=i).data == reader.xarray_data.data) | ||
np.testing.assert_array_equal(reference.isel(S=i).data, reader.xarray_data.data) | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. why remove the dask test too? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. np.testing.assert_array_equal(reference.isel(S=i).data, reader.xarray_data.data) does what the previous lines were doing |
||
|
||
|
||
def make_fake_data_2d(path: Path, as_mm: bool = False) -> xr.DataArray: | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
is this fixing a real bug in the bfio reader?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not a bug-just changes behavior when passing a null scene id