You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Looks like an awesome package that is going to be super helpful! I'm just getting started here. Thanks for building this!
Behavior
When I accidentally passed a <class 'numpy.ndarray'> instead of a <class 'rasterio.io.DatasetReader'> as the dataset argument to stmetrics.spatial.snitc() I get the following error:
Traceback (most recent call last):
File "/Users/lucasj/Code/lib/stseg/test.py", line 14, in <module>
segments = stmetrics.spatial.snitc(
File "/Users/lucasj/Code/lib/stseg/venv/lib/python3.9/site-packages/stmetrics/spatial.py", line 100, in snitc
for band in range(img.shape[0]):
UnboundLocalError: local variable 'img' referenced before assignment
Looks like an awesome package that is going to be super helpful! I'm just getting started here. Thanks for building this!
Behavior
When I accidentally passed a
<class 'numpy.ndarray'>
instead of a<class 'rasterio.io.DatasetReader'>
as the dataset argument tostmetrics.spatial.snitc()
I get the following error:Expected behavior
The program should break on this
TypeError
:stmetrics/stmetrics/spatial.py
Line 96 in dd988d4
Suggestion
Consider using
Raise
to stop the execution like:The text was updated successfully, but these errors were encountered: