Convert GeoRaster to Pandas DataFrame, which can be easily exported to other types of files
    The DataFrame has the row, col, value, x, and y values for each cell
    Usage:
        df = gr.to_pandas(raster)

def to_pandas(raster, name='value'):
    """
    Convert GeoRaster to Pandas DataFrame, which can be easily exported to other types of files
    The DataFrame has the row, col, value, x, and y values for each cell
    Usage:
        df = gr.to_pandas(raster)
    """
    df = pd.DataFrame(raster.raster)
    df = df.stack()
    df = df.reset_index()
    df.columns = ['row', 'col', name]
    df['x'] = df.col.apply(lambda col: raster.geot[0]+(col)*raster.geot[1])
    df['y'] = df.row.apply(lambda row: raster.geot[3]+(row)*raster.geot[-1])
    return df