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
Two bugs spotted with the latest updates of geoultils
1. TypeError: DEM.from_array() got an unexpected keyword argument 'area_or_point'
Where
geoultis.raster line 1363
Reason
raster.from_array has appended metadata area_or_point, however, as the subclass, DEM has an override method from_array. When the self is a DEM instance, self.from_array do not accept argument area_or_point unless the override method accepts it as well.
Corrections
If a subclass overrides a method from its parent class, the overriding method should have the same signature (i.e., the same number and names of parameters) as the method in the parent class. The same error has happened before #416 .
For the same reason, self.tags should be update as well.
File changes
DEM.from_array
2. ImportError: unable import get_mask from geoutils.raster
Two bugs spotted with the latest updates of geoultils
1. TypeError: DEM.from_array() got an unexpected keyword argument 'area_or_point'
Where
geoultis.raster line 1363
Reason
raster.from_array has appended metadata
area_or_point
, however, as the subclass, DEM has an override method from_array. When the self is a DEM instance, self.from_array do not accept argumentarea_or_point
unless the override method accepts it as well.Corrections
If a subclass overrides a method from its parent class, the overriding method should have the same signature (i.e., the same number and names of parameters) as the method in the parent class. The same error has happened before #416 .
For the same reason, self.tags should be update as well.
File changes
DEM.from_array
2. ImportError: unable import get_mask from geoutils.raster
Where
Volumne.py line 12
Reason
'get_mask' has been a new method under the Raster class.
Corrections
Change get_mask into get_mask_from_array
File changes
volumn.py
The text was updated successfully, but these errors were encountered: