Skip to content

Commit

Permalink
Merge pull request #494 from jbouffard/bug-fix/lookup-fix
Browse files Browse the repository at this point in the history
LayerType Creation Isuse Fix
  • Loading branch information
Jacob Bouffard committed Sep 13, 2017
2 parents 00f5331 + 39bf351 commit a0043fa
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions geopyspark/geotrellis/layer.py
Original file line number Diff line number Diff line change
Expand Up @@ -315,7 +315,7 @@ class RasterLayer(CachableLayer, TileLayer):
def __init__(self, layer_type, srdd):
CachableLayer.__init__(self)
self.pysc = get_spark_context()
self.layer_type = layer_type
self.layer_type = LayerType(layer_type)
self.srdd = srdd

@classmethod
Expand Down Expand Up @@ -735,7 +735,7 @@ class TiledRasterLayer(CachableLayer, TileLayer):
def __init__(self, layer_type, srdd):
CachableLayer.__init__(self)
self.pysc = get_spark_context()
self.layer_type = layer_type
self.layer_type = LayerType(layer_type)
self.srdd = srdd

self.is_floating_point_layer = self.srdd.isFloatingPointLayer()
Expand Down Expand Up @@ -1268,7 +1268,7 @@ def save_stitched(self, path, crop_bounds=None, crop_dimensions=None):
self.srdd.saveStitched(path)

def star_series(self, geometries, fn):
if not self.layer_type == LayerType.SPACETIME:
if self.layer_type != LayerType.SPACETIME:
raise ValueError("Only Spatio-Temporal layers can use this function.")

if not isinstance(geometries, list):
Expand Down

0 comments on commit a0043fa

Please sign in to comment.