Commit 0f87be5e authored by Mario Chirinos Colunga's avatar Mario Chirinos Colunga 💬

SCL to JSON

parent 2df5e409
......@@ -15,9 +15,6 @@ def L2ASCLtoDict(filename, wkt):
intput = gdal.Open(filename)
rows, cols, geotransform = intput.RasterYSize, intput.RasterXSize, intput.GetGeoTransform()
data = intput.GetRasterBand(1).ReadAsArray(0,0,cols,rows)
print ("rows: " + str(rows) + " , cols: " + str(cols))
print(len(data))
print(len(data[0]))
count = Counter([])
for r in data:
count = count + Counter(r)
......@@ -30,7 +27,6 @@ def main(argv):
else:
jsonFile=open(argv[1]).read()
cfg = json.loads(jsonFile)
print(cfg)
dataDict = L2ASCLtoDict(cfg["filename"], cfg['wkt'])
print(dataDict)
#-------------------------------------------------------------------------------
......
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