0

I am trying to use rasterio package in python to read in a raster file.

The raster file is from USDA - CDL layer: https://www.nass.usda.gov/Research_and_Science/Cropland/Release/index.php

I got a memory error when I tried read in the band:

---------------------------------------------------------------------------
MemoryError                               Traceback (most recent call last)
<ipython-input-13-4c562498861d> in <module>
----> 1 cdl_df = cdl.read(1)

rasterio/_io.pyx in rasterio._io.DatasetReaderBase.read()

MemoryError: 

Not sure what to do.

Thx in advance!

Keru Chen
  • 387
  • 1
  • 3
  • 11
  • 1
    Do you have enough RAM? If you think you do, the issue might be that your python installation is 32-bit and can only access 4GB of RAM. Perhaps try installing a 64-bit version of Python? – Charles Parr Jun 10 '19 at 18:16
  • I got the same error - reading a 20MB file – ygesher Jul 21 '19 at 13:00

0 Answers0