Commit f930d2bc authored by Daniel Scheffler's avatar Daniel Scheffler

Fixed linting.

parent 950d94f8
Pipeline #3849 passed with stages
in 1 minute and 23 seconds
......@@ -52,14 +52,17 @@ __author__ = 'Daniel Scheffler'
class GeoArray(object):
"""
This class creates a fast Python interface for geodata - either on disk or in memory. It can be instanced
with a file path or with a numpy array and the corresponding geoinformation. Instances can always be indexed
like normal numpy arrays, no matter if GeoArray has been instanced from file or from an in-memory array.
GeoArray provides a wide range of geo-related attributes belonging to the dataset as well as some functions for
quickly visualizing the data as a map, a simple image or an interactive image.
"""
def __init__(self, path_or_array, geotransform=None, projection=None, bandnames=None, nodata=None, progress=True,
q=False):
# type: (Union[str, np.ndarray], tuple, str, list, float, bool, bool) -> None
"""This class creates a fast Python interface for geodata - either on disk or in memory. It can be instanced with
a file path or with a numpy array and the corresponding geoinformation. Instances can always be indexed like
normal numpy arrays, no matter if GeoArray has been instanced from file or from an in-memory array. GeoArray
provides a wide range of geo-related attributes belonging to the dataset as well as some functions for quickly
visualizing the data as a map, a simple image or an interactive image.
"""Get an instance of GeoArray.
:param path_or_array: a numpy.ndarray or a valid file path
:param geotransform: GDAL geotransform of the given array or file on disk
......@@ -1511,7 +1514,7 @@ class GeoArray(object):
def get_subset(self, xslice=None, yslice=None, zslice=None, return_GeoArray=True,
reset_bandnames=False):
# type: (slice, slice, slice, bool, bool) -> GeoArray
"""Returns a new instance of GeoArray representing a subset of the initial one wit respect to given array position.
"""Return a new GeoArray instance representing a subset of the initial one wit respect to given array position.
:param xslice: a slice providing the X-position for the subset in the form slice(xstart, xend, xstep)
:param yslice: a slice providing the Y-position for the subset in the form slice(ystart, yend, ystep)
......
......@@ -196,7 +196,7 @@ class GDAL_Metadata(object):
def to_ENVI_metadict(self):
return OrderedDict(zip(self.all_meta.keys(),
[self._convert_param_to_ENVI_str(i) for i in self.all_meta.values()]))
[self._convert_param_to_ENVI_str(i) for i in self.all_meta.values()]))
def get_subset(self, bands2extract=None, keys2extract=None):
# type: (Union[slice, list, np.ndarray], Union[str, list]) -> 'GDAL_Metadata'
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment