Skip to content

Commit

Permalink
Fix missing sample data file
Browse files Browse the repository at this point in the history
The sample data file was not included in the package distribution and trying to open it caused a FileNotFoundError.
  • Loading branch information
faymanns committed Nov 2, 2023
1 parent 57fd72b commit bc80cac
Show file tree
Hide file tree
Showing 4 changed files with 2 additions and 3 deletions.
1 change: 1 addition & 0 deletions setup.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -61,3 +61,4 @@ testing =

[options.package_data]
* = *.yaml
napari_melt_pool_tracker.data = *.tif
4 changes: 1 addition & 3 deletions src/napari_melt_pool_tracker/_sample_data.py
Original file line number Diff line number Diff line change
Expand Up @@ -22,9 +22,7 @@ def make_sample_data():
# Check the documentation for more information about the
# add_image_kwargs
# https://napari.org/stable/api/napari.Viewer.html#napari.Viewer.add_image
DATA_DIR = pkg_resources.resource_filename(
"napari_melt_pool_tracker", "../../data/"
)
DATA_DIR = pkg_resources.resource_filename(__name__, "data/")
DATA_DIR = pathlib.Path(DATA_DIR)
data = tifffile.imread(DATA_DIR / "wall1_H5.tif")
return [(data, {"name": "wall1_H5"})]
Empty file.
File renamed without changes.

0 comments on commit bc80cac

Please sign in to comment.