diff --git a/Notebooks/Module_0_WaPOR_data_bulk_download.ipynb b/Notebooks/Module_0_WaPOR_data_bulk_download.ipynb index c0bf5d3..d0d33ea 100644 --- a/Notebooks/Module_0_WaPOR_data_bulk_download.ipynb +++ b/Notebooks/Module_0_WaPOR_data_bulk_download.ipynb @@ -40,338 +40,31 @@ "name": "stdout", "output_type": "stream", "text": [ - "Loading WaPOR catalog...\n" + "Loading WaPOR catalog...\n", + "Loading WaPOR catalog...Done\n" ] }, { - "data": { - "text/html": [ - "
\n", - "\n", - "\n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - " \n", - "
codecaptiondescriptionadditionalInfotagsworkspaceCodedataTypeindexoperationhiddenlinksmeasuredimension
0L1_GBWP_AGross Biomass Water ProductivityThe annual Gross Biomass Water Productivity ex...{'format': 'Raster Dataset', 'unit': 'kg/m³ is...[{'name': 'L1', 'index': 1, 'context': 'LEVELS...WAPOR_2RASTER101{'pixelTimeSeries': True, 'areaStatsTimeSeries...False[{'rel': 'self', 'href': 'https://io.apps.fao....{'code': 'WPR', 'caption': 'Water Productivity...[{'code': 'YEAR', 'caption': 'Year', 'descript...
1L1_NBWP_ANet Biomass Water ProductivityThe annual Net Biomass Water Productivity expr...{'format': 'Raster Dataset', 'unit': 'kg/m³ is...[{'name': 'L1', 'index': 2, 'context': 'LEVELS...WAPOR_2RASTER102{'pixelTimeSeries': True, 'areaStatsTimeSeries...False[{'rel': 'self', 'href': 'https://io.apps.fao....{'code': 'WPR', 'caption': 'Water Productivity...[{'code': 'YEAR', 'caption': 'Year', 'descript...
2L1_AETI_AActual EvapoTranspiration and Interception (An...The actual EvapoTranspiration and Interception...{'format': 'Raster Dataset', 'unit': 'mm', 'da...[{'name': 'L1', 'index': 3, 'context': 'LEVELS...WAPOR_2RASTER103{'pixelTimeSeries': True, 'areaStatsTimeSeries...False[{'rel': 'self', 'href': 'https://io.apps.fao....{'code': 'WATER_MM', 'caption': 'Amount of Wat...[{'code': 'YEAR', 'caption': 'Year', 'descript...
3L1_AETI_MActual EvapoTranspiration and Interception (Mo...The actual EvapoTranspiration and Interception...{'format': 'Raster Dataset', 'unit': 'mm', 'da...[{'name': 'L1', 'index': 4, 'context': 'LEVELS...WAPOR_2RASTER104{'pixelTimeSeries': True, 'areaStatsTimeSeries...False[{'rel': 'self', 'href': 'https://io.apps.fao....{'code': 'WATER_MM', 'caption': 'Amount of Wat...[{'code': 'MONTH', 'caption': 'Month', 'worksp...
4L1_AETI_DActual EvapoTranspiration and Interception (De...The actual EvapoTranspiration and Interception...{'format': 'Raster Dataset', 'unit': 'mm', 'da...[{'name': 'L1', 'index': 5, 'context': 'LEVELS...WAPOR_2RASTER105{'pixelTimeSeries': True, 'areaStatsTimeSeries...False[{'rel': 'self', 'href': 'https://io.apps.fao....{'code': 'WATER_MM', 'caption': 'Amount of Wat...[{'code': 'DEKAD', 'caption': 'Dekad (10-Days ...
..........................................
193L2_BAS_PHE_SPhenology (Seasonal, clipped by basin)This is a system dataset, used to let the down...NaNNaNWAPOR_2RASTER4151{'pixelTimeSeries': False, 'areaStatsTimeSerie...True[{'rel': 'self', 'href': 'https://io.apps.fao....{'code': 'PHE', 'caption': 'Phenology', 'descr...[{'code': 'YEAR', 'caption': 'Year', 'descript...
194L2_BAS_QUAL_NDVI_DQuality of Normalized Difference Vegetation In...This is a system dataset, used to let the down...NaNNaNWAPOR_2RASTER4161{'pixelTimeSeries': False, 'areaStatsTimeSerie...True[{'rel': 'self', 'href': 'https://io.apps.fao....{'code': 'N_DAYS', 'caption': 'Number of Days'...[{'code': 'DEKAD', 'caption': 'Dekad (10-Days ...
195L2_CTY_QUAL_NDVI_DQuality of Normalized Difference Vegetation In...This is a system dataset, used to let the down...NaNNaNWAPOR_2RASTER4162{'pixelTimeSeries': False, 'areaStatsTimeSerie...True[{'rel': 'self', 'href': 'https://io.apps.fao....{'code': 'N_DAYS', 'caption': 'Number of Days'...[{'code': 'DEKAD', 'caption': 'Dekad (10-Days ...
196L2_BAS_QUAL_LST_DQuality Land Surface Temperature (Dekadal, cli...This is a system dataset, used to let the down...NaNNaNWAPOR_2RASTER4171{'pixelTimeSeries': False, 'areaStatsTimeSerie...True[{'rel': 'self', 'href': 'https://io.apps.fao....{'code': 'N_DAYS', 'caption': 'Number of Days'...[{'code': 'DEKAD', 'caption': 'Dekad (10-Days ...
197L2_CTY_QUAL_LST_DQuality Land Surface Temperature (Dekadal, cli...This is a system dataset, used to let the down...NaNNaNWAPOR_2RASTER4172{'pixelTimeSeries': False, 'areaStatsTimeSerie...True[{'rel': 'self', 'href': 'https://io.apps.fao....{'code': 'N_DAYS', 'caption': 'Number of Days'...[{'code': 'DEKAD', 'caption': 'Dekad (10-Days ...
\n", - "

198 rows × 13 columns

\n", - "
" - ], - "text/plain": [ - " code caption \\\n", - "0 L1_GBWP_A Gross Biomass Water Productivity \n", - "1 L1_NBWP_A Net Biomass Water Productivity \n", - "2 L1_AETI_A Actual EvapoTranspiration and Interception (An... \n", - "3 L1_AETI_M Actual EvapoTranspiration and Interception (Mo... \n", - "4 L1_AETI_D Actual EvapoTranspiration and Interception (De... \n", - ".. ... ... \n", - "193 L2_BAS_PHE_S Phenology (Seasonal, clipped by basin) \n", - "194 L2_BAS_QUAL_NDVI_D Quality of Normalized Difference Vegetation In... \n", - "195 L2_CTY_QUAL_NDVI_D Quality of Normalized Difference Vegetation In... \n", - "196 L2_BAS_QUAL_LST_D Quality Land Surface Temperature (Dekadal, cli... \n", - "197 L2_CTY_QUAL_LST_D Quality Land Surface Temperature (Dekadal, cli... \n", - "\n", - " description \\\n", - "0 The annual Gross Biomass Water Productivity ex... \n", - "1 The annual Net Biomass Water Productivity expr... \n", - "2 The actual EvapoTranspiration and Interception... \n", - "3 The actual EvapoTranspiration and Interception... \n", - "4 The actual EvapoTranspiration and Interception... \n", - ".. ... \n", - "193 This is a system dataset, used to let the down... \n", - "194 This is a system dataset, used to let the down... \n", - "195 This is a system dataset, used to let the down... \n", - "196 This is a system dataset, used to let the down... \n", - "197 This is a system dataset, used to let the down... \n", - "\n", - " additionalInfo \\\n", - "0 {'format': 'Raster Dataset', 'unit': 'kg/m³ is... \n", - "1 {'format': 'Raster Dataset', 'unit': 'kg/m³ is... \n", - "2 {'format': 'Raster Dataset', 'unit': 'mm', 'da... \n", - "3 {'format': 'Raster Dataset', 'unit': 'mm', 'da... \n", - "4 {'format': 'Raster Dataset', 'unit': 'mm', 'da... \n", - ".. ... \n", - "193 NaN \n", - "194 NaN \n", - "195 NaN \n", - "196 NaN \n", - "197 NaN \n", - "\n", - " tags workspaceCode dataType \\\n", - "0 [{'name': 'L1', 'index': 1, 'context': 'LEVELS... WAPOR_2 RASTER \n", - "1 [{'name': 'L1', 'index': 2, 'context': 'LEVELS... WAPOR_2 RASTER \n", - "2 [{'name': 'L1', 'index': 3, 'context': 'LEVELS... WAPOR_2 RASTER \n", - "3 [{'name': 'L1', 'index': 4, 'context': 'LEVELS... WAPOR_2 RASTER \n", - "4 [{'name': 'L1', 'index': 5, 'context': 'LEVELS... WAPOR_2 RASTER \n", - ".. ... ... ... \n", - "193 NaN WAPOR_2 RASTER \n", - "194 NaN WAPOR_2 RASTER \n", - "195 NaN WAPOR_2 RASTER \n", - "196 NaN WAPOR_2 RASTER \n", - "197 NaN WAPOR_2 RASTER \n", - "\n", - " index operation hidden \\\n", - "0 101 {'pixelTimeSeries': True, 'areaStatsTimeSeries... False \n", - "1 102 {'pixelTimeSeries': True, 'areaStatsTimeSeries... False \n", - "2 103 {'pixelTimeSeries': True, 'areaStatsTimeSeries... False \n", - "3 104 {'pixelTimeSeries': True, 'areaStatsTimeSeries... False \n", - "4 105 {'pixelTimeSeries': True, 'areaStatsTimeSeries... False \n", - ".. ... ... ... \n", - "193 4151 {'pixelTimeSeries': False, 'areaStatsTimeSerie... True \n", - "194 4161 {'pixelTimeSeries': False, 'areaStatsTimeSerie... True \n", - "195 4162 {'pixelTimeSeries': False, 'areaStatsTimeSerie... True \n", - "196 4171 {'pixelTimeSeries': False, 'areaStatsTimeSerie... True \n", - "197 4172 {'pixelTimeSeries': False, 'areaStatsTimeSerie... True \n", - "\n", - " links \\\n", - "0 [{'rel': 'self', 'href': 'https://io.apps.fao.... \n", - "1 [{'rel': 'self', 'href': 'https://io.apps.fao.... \n", - "2 [{'rel': 'self', 'href': 'https://io.apps.fao.... \n", - "3 [{'rel': 'self', 'href': 'https://io.apps.fao.... \n", - "4 [{'rel': 'self', 'href': 'https://io.apps.fao.... \n", - ".. ... \n", - "193 [{'rel': 'self', 'href': 'https://io.apps.fao.... \n", - "194 [{'rel': 'self', 'href': 'https://io.apps.fao.... \n", - "195 [{'rel': 'self', 'href': 'https://io.apps.fao.... \n", - "196 [{'rel': 'self', 'href': 'https://io.apps.fao.... \n", - "197 [{'rel': 'self', 'href': 'https://io.apps.fao.... \n", - "\n", - " measure \\\n", - "0 {'code': 'WPR', 'caption': 'Water Productivity... \n", - "1 {'code': 'WPR', 'caption': 'Water Productivity... \n", - "2 {'code': 'WATER_MM', 'caption': 'Amount of Wat... \n", - "3 {'code': 'WATER_MM', 'caption': 'Amount of Wat... \n", - "4 {'code': 'WATER_MM', 'caption': 'Amount of Wat... \n", - ".. ... \n", - "193 {'code': 'PHE', 'caption': 'Phenology', 'descr... \n", - "194 {'code': 'N_DAYS', 'caption': 'Number of Days'... \n", - "195 {'code': 'N_DAYS', 'caption': 'Number of Days'... \n", - "196 {'code': 'N_DAYS', 'caption': 'Number of Days'... \n", - "197 {'code': 'N_DAYS', 'caption': 'Number of Days'... \n", - "\n", - " dimension \n", - "0 [{'code': 'YEAR', 'caption': 'Year', 'descript... \n", - "1 [{'code': 'YEAR', 'caption': 'Year', 'descript... \n", - "2 [{'code': 'YEAR', 'caption': 'Year', 'descript... \n", - "3 [{'code': 'MONTH', 'caption': 'Month', 'worksp... \n", - "4 [{'code': 'DEKAD', 'caption': 'Dekad (10-Days ... \n", - ".. ... \n", - "193 [{'code': 'YEAR', 'caption': 'Year', 'descript... \n", - "194 [{'code': 'DEKAD', 'caption': 'Dekad (10-Days ... \n", - "195 [{'code': 'DEKAD', 'caption': 'Dekad (10-Days ... \n", - "196 [{'code': 'DEKAD', 'caption': 'Dekad (10-Days ... \n", - "197 [{'code': 'DEKAD', 'caption': 'Dekad (10-Days ... \n", - "\n", - "[198 rows x 13 columns]" - ] - }, - "execution_count": 1, - "metadata": {}, - "output_type": "execute_result" + "ename": "AttributeError", + "evalue": "'DataFrame' object has no attribute '_data'", + "output_type": "error", + "traceback": [ + "\u001b[1;31m---------------------------------------------------------------------------\u001b[0m", + "\u001b[1;31mAttributeError\u001b[0m Traceback (most recent call last)", + "\u001b[1;32m~\\AppData\\Local\\Continuum\\Anaconda3\\lib\\site-packages\\IPython\\core\\formatters.py\u001b[0m in \u001b[0;36m__call__\u001b[1;34m(self, obj)\u001b[0m\n\u001b[0;32m 700\u001b[0m \u001b[0mtype_pprinters\u001b[0m\u001b[1;33m=\u001b[0m\u001b[0mself\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0mtype_printers\u001b[0m\u001b[1;33m,\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0;32m 701\u001b[0m deferred_pprinters=self.deferred_printers)\n\u001b[1;32m--> 702\u001b[1;33m \u001b[0mprinter\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0mpretty\u001b[0m\u001b[1;33m(\u001b[0m\u001b[0mobj\u001b[0m\u001b[1;33m)\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0m\u001b[0;32m 703\u001b[0m \u001b[0mprinter\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0mflush\u001b[0m\u001b[1;33m(\u001b[0m\u001b[1;33m)\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0;32m 704\u001b[0m \u001b[1;32mreturn\u001b[0m \u001b[0mstream\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0mgetvalue\u001b[0m\u001b[1;33m(\u001b[0m\u001b[1;33m)\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n", + "\u001b[1;32m~\\AppData\\Local\\Continuum\\Anaconda3\\lib\\site-packages\\IPython\\lib\\pretty.py\u001b[0m in \u001b[0;36mpretty\u001b[1;34m(self, obj)\u001b[0m\n\u001b[0;32m 400\u001b[0m \u001b[1;32mif\u001b[0m \u001b[0mcls\u001b[0m \u001b[1;32mis\u001b[0m \u001b[1;32mnot\u001b[0m \u001b[0mobject\u001b[0m\u001b[0;31m \u001b[0m\u001b[0;31m\\\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0;32m 401\u001b[0m \u001b[1;32mand\u001b[0m \u001b[0mcallable\u001b[0m\u001b[1;33m(\u001b[0m\u001b[0mcls\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0m__dict__\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0mget\u001b[0m\u001b[1;33m(\u001b[0m\u001b[1;34m'__repr__'\u001b[0m\u001b[1;33m)\u001b[0m\u001b[1;33m)\u001b[0m\u001b[1;33m:\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[1;32m--> 402\u001b[1;33m \u001b[1;32mreturn\u001b[0m \u001b[0m_repr_pprint\u001b[0m\u001b[1;33m(\u001b[0m\u001b[0mobj\u001b[0m\u001b[1;33m,\u001b[0m \u001b[0mself\u001b[0m\u001b[1;33m,\u001b[0m \u001b[0mcycle\u001b[0m\u001b[1;33m)\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0m\u001b[0;32m 403\u001b[0m \u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0;32m 404\u001b[0m \u001b[1;32mreturn\u001b[0m \u001b[0m_default_pprint\u001b[0m\u001b[1;33m(\u001b[0m\u001b[0mobj\u001b[0m\u001b[1;33m,\u001b[0m \u001b[0mself\u001b[0m\u001b[1;33m,\u001b[0m \u001b[0mcycle\u001b[0m\u001b[1;33m)\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n", + "\u001b[1;32m~\\AppData\\Local\\Continuum\\Anaconda3\\lib\\site-packages\\IPython\\lib\\pretty.py\u001b[0m in \u001b[0;36m_repr_pprint\u001b[1;34m(obj, p, cycle)\u001b[0m\n\u001b[0;32m 695\u001b[0m \u001b[1;34m\"\"\"A pprint that just redirects to the normal repr function.\"\"\"\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0;32m 696\u001b[0m \u001b[1;31m# Find newlines and replace them with p.break_()\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[1;32m--> 697\u001b[1;33m \u001b[0moutput\u001b[0m \u001b[1;33m=\u001b[0m \u001b[0mrepr\u001b[0m\u001b[1;33m(\u001b[0m\u001b[0mobj\u001b[0m\u001b[1;33m)\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0m\u001b[0;32m 698\u001b[0m \u001b[1;32mfor\u001b[0m \u001b[0midx\u001b[0m\u001b[1;33m,\u001b[0m\u001b[0moutput_line\u001b[0m \u001b[1;32min\u001b[0m \u001b[0menumerate\u001b[0m\u001b[1;33m(\u001b[0m\u001b[0moutput\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0msplitlines\u001b[0m\u001b[1;33m(\u001b[0m\u001b[1;33m)\u001b[0m\u001b[1;33m)\u001b[0m\u001b[1;33m:\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0;32m 699\u001b[0m \u001b[1;32mif\u001b[0m \u001b[0midx\u001b[0m\u001b[1;33m:\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n", + "\u001b[1;32m~\\AppData\\Local\\Continuum\\Anaconda3\\lib\\site-packages\\pandas\\core\\base.py\u001b[0m in \u001b[0;36m__repr__\u001b[1;34m(self)\u001b[0m\n\u001b[0;32m 76\u001b[0m \u001b[0mYields\u001b[0m \u001b[0mBytestring\u001b[0m \u001b[1;32min\u001b[0m \u001b[0mPy2\u001b[0m\u001b[1;33m,\u001b[0m \u001b[0mUnicode\u001b[0m \u001b[0mString\u001b[0m \u001b[1;32min\u001b[0m \u001b[0mpy3\u001b[0m\u001b[1;33m.\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0;32m 77\u001b[0m \"\"\"\n\u001b[1;32m---> 78\u001b[1;33m \u001b[1;32mreturn\u001b[0m \u001b[0mstr\u001b[0m\u001b[1;33m(\u001b[0m\u001b[0mself\u001b[0m\u001b[1;33m)\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0m\u001b[0;32m 79\u001b[0m \u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0;32m 80\u001b[0m \u001b[1;33m\u001b[0m\u001b[0m\n", + "\u001b[1;32m~\\AppData\\Local\\Continuum\\Anaconda3\\lib\\site-packages\\pandas\\core\\base.py\u001b[0m in \u001b[0;36m__str__\u001b[1;34m(self)\u001b[0m\n\u001b[0;32m 55\u001b[0m \u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0;32m 56\u001b[0m \u001b[1;32mif\u001b[0m \u001b[0mcompat\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0mPY3\u001b[0m\u001b[1;33m:\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[1;32m---> 57\u001b[1;33m \u001b[1;32mreturn\u001b[0m \u001b[0mself\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0m__unicode__\u001b[0m\u001b[1;33m(\u001b[0m\u001b[1;33m)\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0m\u001b[0;32m 58\u001b[0m \u001b[1;32mreturn\u001b[0m \u001b[0mself\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0m__bytes__\u001b[0m\u001b[1;33m(\u001b[0m\u001b[1;33m)\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0;32m 59\u001b[0m \u001b[1;33m\u001b[0m\u001b[0m\n", + "\u001b[1;32m~\\AppData\\Local\\Continuum\\Anaconda3\\lib\\site-packages\\pandas\\core\\frame.py\u001b[0m in \u001b[0;36m__unicode__\u001b[1;34m(self)\u001b[0m\n\u001b[0;32m 632\u001b[0m \u001b[0mwidth\u001b[0m \u001b[1;33m=\u001b[0m \u001b[1;32mNone\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0;32m 633\u001b[0m self.to_string(buf=buf, max_rows=max_rows, max_cols=max_cols,\n\u001b[1;32m--> 634\u001b[1;33m line_width=width, show_dimensions=show_dimensions)\n\u001b[0m\u001b[0;32m 635\u001b[0m \u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0;32m 636\u001b[0m \u001b[1;32mreturn\u001b[0m \u001b[0mbuf\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0mgetvalue\u001b[0m\u001b[1;33m(\u001b[0m\u001b[1;33m)\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n", + "\u001b[1;32m~\\AppData\\Local\\Continuum\\Anaconda3\\lib\\site-packages\\pandas\\core\\frame.py\u001b[0m in \u001b[0;36mto_string\u001b[1;34m(self, buf, columns, col_space, header, index, na_rep, formatters, float_format, sparsify, index_names, justify, max_rows, max_cols, show_dimensions, decimal, line_width)\u001b[0m\n\u001b[0;32m 718\u001b[0m \u001b[0mshow_dimensions\u001b[0m\u001b[1;33m=\u001b[0m\u001b[0mshow_dimensions\u001b[0m\u001b[1;33m,\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0;32m 719\u001b[0m \u001b[0mdecimal\u001b[0m\u001b[1;33m=\u001b[0m\u001b[0mdecimal\u001b[0m\u001b[1;33m,\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[1;32m--> 720\u001b[1;33m line_width=line_width)\n\u001b[0m\u001b[0;32m 721\u001b[0m \u001b[0mformatter\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0mto_string\u001b[0m\u001b[1;33m(\u001b[0m\u001b[1;33m)\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0;32m 722\u001b[0m \u001b[1;33m\u001b[0m\u001b[0m\n", + "\u001b[1;32m~\\AppData\\Local\\Continuum\\Anaconda3\\lib\\site-packages\\pandas\\io\\formats\\format.py\u001b[0m in \u001b[0;36m__init__\u001b[1;34m(self, frame, buf, columns, col_space, header, index, na_rep, formatters, justify, float_format, sparsify, index_names, line_width, max_rows, max_cols, show_dimensions, decimal, table_id, render_links, **kwds)\u001b[0m\n\u001b[0;32m 408\u001b[0m \u001b[0mself\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0mmax_cols\u001b[0m \u001b[1;33m=\u001b[0m \u001b[0mmax_cols\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0;32m 409\u001b[0m self.max_rows_displayed = min(max_rows or len(self.frame),\n\u001b[1;32m--> 410\u001b[1;33m len(self.frame))\n\u001b[0m\u001b[0;32m 411\u001b[0m \u001b[0mself\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0mshow_dimensions\u001b[0m \u001b[1;33m=\u001b[0m \u001b[0mshow_dimensions\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0;32m 412\u001b[0m \u001b[0mself\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0mtable_id\u001b[0m \u001b[1;33m=\u001b[0m \u001b[0mtable_id\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n", + "\u001b[1;32m~\\AppData\\Local\\Continuum\\Anaconda3\\lib\\site-packages\\pandas\\core\\frame.py\u001b[0m in \u001b[0;36m__len__\u001b[1;34m(self)\u001b[0m\n\u001b[0;32m 939\u001b[0m \u001b[0mReturns\u001b[0m \u001b[0mlength\u001b[0m \u001b[0mof\u001b[0m \u001b[0minfo\u001b[0m \u001b[0maxis\u001b[0m\u001b[1;33m,\u001b[0m \u001b[0mbut\u001b[0m \u001b[0mhere\u001b[0m \u001b[0mwe\u001b[0m \u001b[0muse\u001b[0m \u001b[0mthe\u001b[0m \u001b[0mindex\u001b[0m\u001b[1;33m.\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0;32m 940\u001b[0m \"\"\"\n\u001b[1;32m--> 941\u001b[1;33m \u001b[1;32mreturn\u001b[0m \u001b[0mlen\u001b[0m\u001b[1;33m(\u001b[0m\u001b[0mself\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0mindex\u001b[0m\u001b[1;33m)\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0m\u001b[0;32m 942\u001b[0m \u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0;32m 943\u001b[0m \u001b[1;32mdef\u001b[0m \u001b[0mdot\u001b[0m\u001b[1;33m(\u001b[0m\u001b[0mself\u001b[0m\u001b[1;33m,\u001b[0m \u001b[0mother\u001b[0m\u001b[1;33m)\u001b[0m\u001b[1;33m:\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n", + "\u001b[1;32m~\\AppData\\Local\\Continuum\\Anaconda3\\lib\\site-packages\\pandas\\core\\generic.py\u001b[0m in \u001b[0;36m__getattr__\u001b[1;34m(self, name)\u001b[0m\n\u001b[0;32m 5061\u001b[0m if (name in self._internal_names_set or name in self._metadata or\n\u001b[0;32m 5062\u001b[0m name in self._accessors):\n\u001b[1;32m-> 5063\u001b[1;33m \u001b[1;32mreturn\u001b[0m \u001b[0mobject\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0m__getattribute__\u001b[0m\u001b[1;33m(\u001b[0m\u001b[0mself\u001b[0m\u001b[1;33m,\u001b[0m \u001b[0mname\u001b[0m\u001b[1;33m)\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0m\u001b[0;32m 5064\u001b[0m \u001b[1;32melse\u001b[0m\u001b[1;33m:\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0;32m 5065\u001b[0m \u001b[1;32mif\u001b[0m \u001b[0mself\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0m_info_axis\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0m_can_hold_identifiers_and_holds_name\u001b[0m\u001b[1;33m(\u001b[0m\u001b[0mname\u001b[0m\u001b[1;33m)\u001b[0m\u001b[1;33m:\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n", + "\u001b[1;32mpandas/_libs/properties.pyx\u001b[0m in \u001b[0;36mpandas._libs.properties.AxisProperty.__get__\u001b[1;34m()\u001b[0m\n", + "\u001b[1;32m~\\AppData\\Local\\Continuum\\Anaconda3\\lib\\site-packages\\pandas\\core\\generic.py\u001b[0m in \u001b[0;36m__getattr__\u001b[1;34m(self, name)\u001b[0m\n\u001b[0;32m 5061\u001b[0m if (name in self._internal_names_set or name in self._metadata or\n\u001b[0;32m 5062\u001b[0m name in self._accessors):\n\u001b[1;32m-> 5063\u001b[1;33m \u001b[1;32mreturn\u001b[0m \u001b[0mobject\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0m__getattribute__\u001b[0m\u001b[1;33m(\u001b[0m\u001b[0mself\u001b[0m\u001b[1;33m,\u001b[0m \u001b[0mname\u001b[0m\u001b[1;33m)\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0m\u001b[0;32m 5064\u001b[0m \u001b[1;32melse\u001b[0m\u001b[1;33m:\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0;32m 5065\u001b[0m \u001b[1;32mif\u001b[0m \u001b[0mself\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0m_info_axis\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0m_can_hold_identifiers_and_holds_name\u001b[0m\u001b[1;33m(\u001b[0m\u001b[0mname\u001b[0m\u001b[1;33m)\u001b[0m\u001b[1;33m:\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n", + "\u001b[1;31mAttributeError\u001b[0m: 'DataFrame' object has no attribute '_data'" + ] } ], "source": [ @@ -750,7 +443,7 @@ "name": "python", "nbconvert_exporter": "python", "pygments_lexer": "ipython3", - "version": "3.7.9" + "version": "3.7.3" } }, "nbformat": 4, diff --git a/README.md b/README.md index c3ea77a..b87346e 100644 --- a/README.md +++ b/README.md @@ -49,6 +49,7 @@ The scripts to download and process the WaPOR data for land and water productivi #### i) Install python and jupyter notebook using the Anaconda distribution: https://www.anaconda.com/products/individual Use the anaconda installer, which is tailored to different operating system: window (64-Bit and 32-Bit), MacOS (64-Bit) or Linux system. >Read more on Jupyter notebook: https://jupyter.org/, https://packaging.python.org/overview/ +**Steps to run Jupyter notebook** refer from https://github.com/wateraccounting/WAPOROCW/blob/master/README.md #### ii) Install packages: ##### Packages such as GDAL, pyshp can be installed using pip or conda. @@ -71,6 +72,7 @@ The protocol has six modules, which are described in detail in the following sec **Figure 1.** Flow chart for downloading WaPOR data and calculate performance indicators, land and water productivity and productivity gaps (Left) and a screenshot of the Jupyter notebook for the six modules (Right). ## 3.1 Download WaPOR data (Module 0) +**Notebook:** https://github.com/wateraccounting/WAPORWP/blob/master/Notebooks/Module_0_WaPOR_data_bulk_download.ipynb ##### Step 0a Import modules/libraries ##### Step 0b Read the geographical extent of the study area ##### Step 0c Bulk-download WaPOR data for the study area extent @@ -87,6 +89,7 @@ The script is pre-set at downloading decadal data from 1 January 2009 to 31 Dece ## 3.2 Pre-processing WaPOR data (Module 1) +**Notebook:** https://github.com/wateraccounting/WAPORWP/blob/master/Notebooks/Module_1_WaPOR_data_preparation.ipynb ##### Step 1a Import modules/libraries ##### Step 1b Resample raster data ##### Step 1c Filter non-cropped area using land cover map and project boundary @@ -96,6 +99,7 @@ In the example case, we identified the area for analysis using a shapefile (proj For the analyses it is important to select a homogeneous area with one single crop type and similar crop season. ## 3.3 Computing Seasonal Water Consumption & Net Primary Production (Module 2) +**Notebook:** http://localhost:8888/notebooks/Module_2_SeasonalWaterConsumption%26NetPrimaryProduction.ipynb ##### Step 2a Set up: Import modules/libraries ##### Step 2b Defining function and crop season ##### Step 2b Calculate seasonal T, ET, RET, ETp, NPP @@ -103,6 +107,7 @@ For agricultural purposes the seasonal values are important, these are calculate ![title](ReadmeIMG/Fig_M2.png) ## 3.4 Calculate performance indicators (Module 3) +**Notebook:** http://localhost:8888/notebooks/Module_3_CalculatePerformanceIndicators.ipynb This module is used to calculate a number of performance indicators, namely uniformity, beneficial fraction, adequacy and relative water deficit. ##### Step 3a Set up ##### Step 3b Calculate Uniformity and Equity @@ -120,6 +125,7 @@ Adequacy (A) is the measure of the degree of agreement between available water a Relative Water Deficit (RWD) provides an indication of the level of water shortage found in the irrigation system. It is calculated using the equation described in FAO 66 (Steduto et al., 2012) by applying for a mono-crop system, where the actual ET is compared to the maximum ET. ## 3.5 Land and water productivity (Module 4) +**Notebook:** http://localhost:8888/notebooks/Module_4_CalculateLand%26WaterProductivity.ipynb ##### Step 4a Set up ##### Step 4b Calculate land productivity: i) biomass and ii) crop yield **Land productivity** is is defined as the above-ground biomass production or yield in ton/ha/season, which are estimated from the seasonal net primary production using the following equations: @@ -131,6 +137,7 @@ The parameters used in these equations are crop-specific and vary under differen **Biomass and crop Water productivity** is estimated as the ratio of above-ground biomass or yield over actual evapotranspiration. ## 3.6 Productivity gaps and production projection (Module 5) +**Notebook:** http://localhost:8888/notebooks/Module_5_BrightSpots%26ProductivityGaps.ipynb ##### Step 5a Set up ##### Step 5b Calculate the target productivity The **target productivity** is a target for land and water productivity which is attainable under the local climatic conditions. This step of the script describes how the target is set and how bright spots are identified and how the productivity gap (related to the target) is estimated.