diff --git a/pvanalytics/features/shading.py b/pvanalytics/features/shading.py index 08ea73ed..d76977ea 100644 --- a/pvanalytics/features/shading.py +++ b/pvanalytics/features/shading.py @@ -113,7 +113,7 @@ def _prepare_images(ghi, clearsky, daytime, interval): ghi_image = pd.DataFrame(cloudless_image).interpolate( axis=0, limit_direction='both' - ).to_numpy() + ).to_numpy().copy() # set night to nan ghi_image[~_to_image(daytime.to_numpy(), image_width)] = np.nan return ( @@ -365,7 +365,7 @@ def fixed(ghi, daytime, clearsky, interval=None, min_gradient=2): threshold = gradient > min_gradient # binary image of wire candidates # From here we CAN use skimage because we are working with binary images. - three_minute_mask = morphology.rectangle(1, 3) + three_minute_mask = morphology.footprint_rectangle((1, 3)) wires = morphology.remove_small_objects( morphology.binary_closing(threshold, three_minute_mask), min_size=200,