diff --git a/data_prep_GE/Compute IAM.ipynb b/data_prep_GE/Compute IAM.ipynb new file mode 100644 index 0000000..b29355b --- /dev/null +++ b/data_prep_GE/Compute IAM.ipynb @@ -0,0 +1,781 @@ +{ + "cells": [ + { + "cell_type": "code", + "execution_count": 1, + "metadata": {}, + "outputs": [], + "source": [ + "import pvlib\n", + "import pandas as pd\n", + "import numpy as np\n", + "import geopandas as gpd\n", + "import xarray as xr\n", + "from itertools import product\n", + "import time" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Load data" + ] + }, + { + "cell_type": "code", + "execution_count": 2, + "metadata": {}, + "outputs": [], + "source": [ + "roofs = gpd.read_file('/Volumes/NO NAME/data_geneva/solar/ROOFS_GE/ROOFS_GE.shp')" + ] + }, + { + "cell_type": "code", + "execution_count": 3, + "metadata": {}, + "outputs": [], + "source": [ + "pv_pot = xr.open_dataset('/Volumes/NO NAME/data_geneva/solar/pv_potential_hourly_GE.nc')" + ] + }, + { + "cell_type": "code", + "execution_count": 4, + "metadata": {}, + "outputs": [], + "source": [ + "# Source: Google\n", + "GE_lat = 46.2044\n", + "GE_lon = 6.1432" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Preprocess data" + ] + }, + { + "cell_type": "code", + "execution_count": 5, + "metadata": {}, + "outputs": [], + "source": [ + "ts = pv_pot.timestamp.to_pandas()" + ] + }, + { + "cell_type": "code", + "execution_count": 6, + "metadata": {}, + "outputs": [], + "source": [ + "roofs = roofs[['DF_UID', 'panel_tilt', 'panel_dire', 'NEIGUNG', 'AUSRICHTUN']]" + ] + }, + { + "cell_type": "code", + "execution_count": 7, + "metadata": { + "scrolled": true + }, + "outputs": [ + { + "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", + "
DF_UIDpanel_tiltpanel_direNEIGUNGAUSRICHTUN
0481741010307.010127.0
1481742537213.03733.0
2481742631123.031-57.0
348174273733.037-147.0
4481742828303.028123.0
\n", + "
" + ], + "text/plain": [ + " DF_UID panel_tilt panel_dire NEIGUNG AUSRICHTUN\n", + "0 4817410 10 307.0 10 127.0\n", + "1 4817425 37 213.0 37 33.0\n", + "2 4817426 31 123.0 31 -57.0\n", + "3 4817427 37 33.0 37 -147.0\n", + "4 4817428 28 303.0 28 123.0" + ] + }, + "execution_count": 7, + "metadata": {}, + "output_type": "execute_result" + } + ], + "source": [ + "roofs.head()" + ] + }, + { + "cell_type": "code", + "execution_count": 8, + "metadata": {}, + "outputs": [], + "source": [ + "unique_combinations = roofs.groupby(['panel_tilt', 'panel_dire'])[[]].sum().reset_index()" + ] + }, + { + "cell_type": "code", + "execution_count": 9, + "metadata": {}, + "outputs": [ + { + "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", + "
panel_tiltpanel_dire
010.0
113.0
214.0
316.0
418.0
.........
2162169350.0
2162269352.0
2162369355.0
2162469357.0
2162569359.0
\n", + "

21626 rows × 2 columns

\n", + "
" + ], + "text/plain": [ + " panel_tilt panel_dire\n", + "0 1 0.0\n", + "1 1 3.0\n", + "2 1 4.0\n", + "3 1 6.0\n", + "4 1 8.0\n", + "... ... ...\n", + "21621 69 350.0\n", + "21622 69 352.0\n", + "21623 69 355.0\n", + "21624 69 357.0\n", + "21625 69 359.0\n", + "\n", + "[21626 rows x 2 columns]" + ] + }, + "execution_count": 9, + "metadata": {}, + "output_type": "execute_result" + } + ], + "source": [ + "unique_combinations" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Model solar position and merge with roof aspects and tilts" + ] + }, + { + "cell_type": "code", + "execution_count": 10, + "metadata": {}, + "outputs": [], + "source": [ + "# Solar zenith and azimuth\n", + "solpos = pvlib.solarposition.get_solarposition(ts, GE_lat, GE_lon)" + ] + }, + { + "cell_type": "code", + "execution_count": 11, + "metadata": {}, + "outputs": [], + "source": [ + "aoi_data = pd.DataFrame(list(product(ts, unique_combinations.index)), columns = ['timestamp', 'index'])\n", + "aoi_data = aoi_data.merge( solpos[['zenith', 'azimuth']], left_on = 'timestamp', right_index = True )\n", + "aoi_data = aoi_data.merge( unique_combinations, left_on = 'index', right_index = True \n", + " ).set_index( ['timestamp'] ).drop(columns = ['index'])" + ] + }, + { + "cell_type": "code", + "execution_count": 12, + "metadata": {}, + "outputs": [ + { + "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", + "
zenithazimuthpanel_tiltpanel_dire
timestamp
2001-01-15 08:00:0084.296361128.80501210.0
2001-01-15 09:00:0076.930412140.86665410.0
2001-01-15 10:00:0071.348691154.20932810.0
2001-01-15 11:00:0068.035952168.70864510.0
2001-01-15 12:00:0067.350485183.81823210.0
...............
2001-12-15 11:00:0069.833638172.51464669359.0
2001-12-15 12:00:0069.808703187.18769269359.0
2001-12-15 13:00:0072.384706201.48882569359.0
2001-12-15 14:00:0077.288041214.82463469359.0
2001-12-15 15:00:0084.084825226.96531069359.0
\n", + "

3157396 rows × 4 columns

\n", + "
" + ], + "text/plain": [ + " zenith azimuth panel_tilt panel_dire\n", + "timestamp \n", + "2001-01-15 08:00:00 84.296361 128.805012 1 0.0\n", + "2001-01-15 09:00:00 76.930412 140.866654 1 0.0\n", + "2001-01-15 10:00:00 71.348691 154.209328 1 0.0\n", + "2001-01-15 11:00:00 68.035952 168.708645 1 0.0\n", + "2001-01-15 12:00:00 67.350485 183.818232 1 0.0\n", + "... ... ... ... ...\n", + "2001-12-15 11:00:00 69.833638 172.514646 69 359.0\n", + "2001-12-15 12:00:00 69.808703 187.187692 69 359.0\n", + "2001-12-15 13:00:00 72.384706 201.488825 69 359.0\n", + "2001-12-15 14:00:00 77.288041 214.824634 69 359.0\n", + "2001-12-15 15:00:00 84.084825 226.965310 69 359.0\n", + "\n", + "[3157396 rows x 4 columns]" + ] + }, + "execution_count": 12, + "metadata": {}, + "output_type": "execute_result" + } + ], + "source": [ + "aoi_data" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Compute AOI and IAM" + ] + }, + { + "cell_type": "code", + "execution_count": 13, + "metadata": {}, + "outputs": [], + "source": [ + "# Angle of incidence\n", + "aoi_data['AOI'] = pvlib.irradiance.aoi(aoi_data['panel_tilt'], aoi_data['panel_dire'], \n", + " aoi_data['zenith'] , aoi_data['azimuth'])" + ] + }, + { + "cell_type": "code", + "execution_count": 14, + "metadata": {}, + "outputs": [], + "source": [ + "# Incidence angle modifier\n", + "aoi_data['IAM'] = pvlib.iam.physical(aoi_data['AOI'])" + ] + }, + { + "cell_type": "code", + "execution_count": 15, + "metadata": {}, + "outputs": [ + { + "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", + "
zenithazimuthpanel_tiltpanel_direAOIIAM
timestamp
2001-01-15 08:00:0084.296361128.80501210.084.9235430.405451
2001-01-15 09:00:0076.930412140.86665410.077.7068800.706981
2001-01-15 10:00:0071.348691154.20932810.072.2496270.826232
2001-01-15 11:00:0068.035952168.70864510.069.0167290.872241
2001-01-15 12:00:0067.350485183.81823210.068.3482810.880108
\n", + "
" + ], + "text/plain": [ + " zenith azimuth panel_tilt panel_dire AOI \\\n", + "timestamp \n", + "2001-01-15 08:00:00 84.296361 128.805012 1 0.0 84.923543 \n", + "2001-01-15 09:00:00 76.930412 140.866654 1 0.0 77.706880 \n", + "2001-01-15 10:00:00 71.348691 154.209328 1 0.0 72.249627 \n", + "2001-01-15 11:00:00 68.035952 168.708645 1 0.0 69.016729 \n", + "2001-01-15 12:00:00 67.350485 183.818232 1 0.0 68.348281 \n", + "\n", + " IAM \n", + "timestamp \n", + "2001-01-15 08:00:00 0.405451 \n", + "2001-01-15 09:00:00 0.706981 \n", + "2001-01-15 10:00:00 0.826232 \n", + "2001-01-15 11:00:00 0.872241 \n", + "2001-01-15 12:00:00 0.880108 " + ] + }, + "execution_count": 15, + "metadata": {}, + "output_type": "execute_result" + } + ], + "source": [ + "aoi_data.head()" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "## Map to roofs" + ] + }, + { + "cell_type": "code", + "execution_count": 20, + "metadata": {}, + "outputs": [], + "source": [ + "batch_size = 20000\n", + "N_batches = int(np.ceil(len(roofs) / batch_size))" + ] + }, + { + "cell_type": "code", + "execution_count": 22, + "metadata": {}, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "Executed iteration 1 of 11 in 14.91s\n", + "Executed iteration 2 of 11 in 15.42s\n", + "Executed iteration 3 of 11 in 15.27s\n", + "Executed iteration 4 of 11 in 14.71s\n", + "Executed iteration 5 of 11 in 16.06s\n", + "Executed iteration 6 of 11 in 15.86s\n", + "Executed iteration 7 of 11 in 15.82s\n", + "Executed iteration 8 of 11 in 14.99s\n", + "Executed iteration 9 of 11 in 14.50s\n", + "Executed iteration 10 of 11 in 15.47s\n", + "Executed iteration 11 of 11 in 4.83s\n" + ] + } + ], + "source": [ + "IAM = []\n", + "for i in range(N_batches):\n", + " tt = time.time()\n", + " roof_sel = roofs.iloc[i*batch_size:(i+1)*batch_size]\n", + " \n", + " roof_sel_iam = roof_sel.merge(aoi_data.reset_index(), on = ['panel_tilt', 'panel_dire'])\n", + " IAM_sel = roof_sel_iam.set_index(['DF_UID', 'timestamp'])[['AOI', 'IAM']].to_xarray()\n", + " IAM_sel['AOI'] = IAM_sel.AOI.astype('float32')\n", + " IAM_sel['IAM'] = IAM_sel.IAM.astype('float32')\n", + " \n", + " IAM.append(IAM_sel)\n", + " print('Executed iteration %d of %d in %.2fs' %(i+1, N_batches, time.time()-tt))\n", + "\n", + "IAM = xr.concat(IAM, dim = 'DF_UID')" + ] + }, + { + "cell_type": "code", + "execution_count": 24, + "metadata": {}, + "outputs": [ + { + "data": { + "text/plain": [ + "206462" + ] + }, + "execution_count": 24, + "metadata": {}, + "output_type": "execute_result" + } + ], + "source": [ + "len(roofs)" + ] + }, + { + "cell_type": "code", + "execution_count": 23, + "metadata": {}, + "outputs": [ + { + "data": { + "text/html": [ + "
<xarray.Dataset>\n",
+       "Dimensions:    (DF_UID: 206462, timestamp: 146)\n",
+       "Coordinates:\n",
+       "  * timestamp  (timestamp) datetime64[ns] 2001-01-15T08:00:00 ... 2001-12-15T15:00:00\n",
+       "  * DF_UID     (DF_UID) int64 4817410 4817425 4817426 ... 5124527 5124528\n",
+       "Data variables:\n",
+       "    AOI        (DF_UID, timestamp) float32 94.291435 86.647514 ... 72.153046\n",
+       "    IAM        (DF_UID, timestamp) float32 0.0 0.29255646 ... 0.8278234
" + ], + "text/plain": [ + "\n", + "Dimensions: (DF_UID: 206462, timestamp: 146)\n", + "Coordinates:\n", + " * timestamp (timestamp) datetime64[ns] 2001-01-15T08:00:00 ... 2001-12-15T15:00:00\n", + " * DF_UID (DF_UID) int64 4817410 4817425 4817426 ... 5124527 5124528\n", + "Data variables:\n", + " AOI (DF_UID, timestamp) float32 94.291435 86.647514 ... 72.153046\n", + " IAM (DF_UID, timestamp) float32 0.0 0.29255646 ... 0.8278234" + ] + }, + "execution_count": 23, + "metadata": {}, + "output_type": "execute_result" + } + ], + "source": [ + "IAM" + ] + }, + { + "cell_type": "code", + "execution_count": 25, + "metadata": {}, + "outputs": [], + "source": [ + "IAM.to_netcdf('/Volumes/NO NAME/data_geneva/solar/IAM_per_roof_GE.nc')" + ] + }, + { + "cell_type": "code", + "execution_count": null, + "metadata": {}, + "outputs": [], + "source": [] + } + ], + "metadata": { + "kernelspec": { + "display_name": "Python 3", + "language": "python", + "name": "python3" + }, + "language_info": { + "codemirror_mode": { + "name": "ipython", + "version": 3 + }, + "file_extension": ".py", + "mimetype": "text/x-python", + "name": "python", + "nbconvert_exporter": "python", + "pygments_lexer": "ipython3", + "version": "3.7.6" + } + }, + "nbformat": 4, + "nbformat_minor": 4 +} diff --git a/optimisation_GE/Model_system_dynamics.ipynb b/optimisation_GE/Model_system_dynamics.ipynb new file mode 100644 index 0000000..b8fcca2 --- /dev/null +++ b/optimisation_GE/Model_system_dynamics.ipynb @@ -0,0 +1,1430 @@ +{ + "cells": [ + { + "cell_type": "code", + "execution_count": 1, + "metadata": {}, + "outputs": [], + "source": [ + "import pandas as pd\n", + "import xarray as xr\n", + "import numpy as np\n", + "import geopandas as gpd\n", + "\n", + "import os\n", + "import time" + ] + }, + { + "cell_type": "code", + "execution_count": 2, + "metadata": {}, + "outputs": [], + "source": [ + "fp = '/Users/alinawalch/Documents/OneDrive - epfl.ch/Master Projects/Romain_Sibuet/inputs/'" + ] + }, + { + "cell_type": "code", + "execution_count": 3, + "metadata": {}, + "outputs": [ + { + "name": "stdout", + "output_type": "stream", + "text": [ + "hyd_mod_return_temperature.csv\n", + "ashp_hourly_operation.csv\n", + "ashp_hourly_dhw_cop.csv\n", + "gshp_hourly_dhw_cop.csv\n", + "eh_hourly_operation.csv\n", + "xhp_hourly_maximum_load.csv\n", + "ashp_hourly_sh_cop.csv\n", + "hyd_mod_supply_temperature.csv\n", + "community.csv\n", + "gshp_hourly_sh_cop.csv\n", + "pv_hourly_potential.csv\n", + "elec_hourly_demand.csv\n", + "gshp_hourly_operation.csv\n" + ] + } + ], + "source": [ + "data = {}\n", + "for file in os.listdir(fp):\n", + " name = os.path.splitext(file)[0]\n", + " \n", + " if name == 'heat_hourly_demand':\n", + " new_data = pd.read_csv(os.path.join(fp, file), index_col = 0, skiprows = 1)\n", + " data['dhw_demand_W'] = new_data.iloc[:,:int(new_data.shape[1]/2)]\n", + " data['sh_demand_W'] = new_data.iloc[:,int(new_data.shape[1]/2):]\n", + " continue\n", + " \n", + " data[name] = pd.read_csv(os.path.join(fp, file), index_col = 0)\n", + " \n", + " print(file)" + ] + }, + { + "cell_type": "code", + "execution_count": 4, + "metadata": { + "scrolled": false + }, + "outputs": [], + "source": [ + "data_xr = []\n", + "for name in data.keys():\n", + " if name == 'community':\n", + " data[ name ].index = data[ name ].index.astype('str')\n", + " data_xr.append( data[ name ].to_xarray() )\n", + " continue\n", + " \n", + " data[ name ].index.name = 'timestamp_ID'\n", + " for col in data[name].columns:\n", + " data[name] = data[name].rename({ col : col.split('.')[0] }, axis = 1)\n", + " \n", + " data_xr.append( data[ name ].reset_index()\n", + " .melt(var_name = 'EGID', value_name = name, id_vars = 'timestamp_ID')\n", + " .set_index(['EGID', 'timestamp_ID']).to_xarray() )\n", + "data_xr = xr.merge(data_xr)" + ] + }, + { + "cell_type": "code", + "execution_count": 5, + "metadata": { + "scrolled": false + }, + "outputs": [ + { + "data": { + "text/html": [ + "
\n", + "\n", + "\n", + "\n", + "\n", + "\n", + "\n", + "\n", + "\n", + "\n", + "\n", + "\n", + "\n", + "\n", + "\n", + "
<xarray.Dataset>\n",
+       "Dimensions:                     (EGID: 518, timestamp_ID: 288)\n",
+       "Coordinates:\n",
+       "  * EGID                        (EGID) object '1028823' '1028824' ... '9082379'\n",
+       "  * timestamp_ID                (timestamp_ID) int64 0 1 2 3 ... 284 285 286 287\n",
+       "Data variables:\n",
+       "    hyd_mod_return_temperature  (EGID, timestamp_ID) float64 27.51 ... 29.86\n",
+       "    ashp_hourly_operation       (EGID, timestamp_ID) float64 nan nan ... 362.3\n",
+       "    ashp_hourly_dhw_cop         (EGID, timestamp_ID) float64 nan nan ... 2.633\n",
+       "    gshp_hourly_dhw_cop         (EGID, timestamp_ID) float64 2.615 2.615 ... nan\n",
+       "    eh_hourly_operation         (EGID, timestamp_ID) float64 0.0 0.0 ... nan nan\n",
+       "    xhp_hourly_maximum_load     (EGID, timestamp_ID) float64 3.0 3.0 ... nan nan\n",
+       "    ashp_hourly_sh_cop          (EGID, timestamp_ID) float64 nan nan ... 3.273\n",
+       "    dhw_demand_W                (EGID, timestamp_ID) float64 8.644 ... 424.1\n",
+       "    sh_demand_W                 (EGID, timestamp_ID) float64 797.3 ... 2.185e+03\n",
+       "    hyd_mod_supply_temperature  (EGID, timestamp_ID) float64 24.85 ... 26.26\n",
+       "    sector                      (EGID) object 'RES' 'RES' 'RES' ... 'RES' 'SER'\n",
+       "    BLD_ID                      (EGID) float64 1.5e+08 1.5e+08 ... 1.5e+08\n",
+       "    footprint                   (EGID) float64 97.0 97.0 96.0 ... 64.0 167.0\n",
+       "    N_floors                    (EGID) float64 1.0 1.0 1.0 1.0 ... 3.0 2.0 1.0\n",
+       "    floor_area                  (EGID) float64 97.0 97.0 96.0 ... 128.0 167.0\n",
+       "    geometry                    (EGID) object 'POINT (2496755.5 1117207.75)' ...\n",
+       "    dhw_demand_kWh              (EGID) float64 2.016e+03 2.16e+03 ... 1.102e+04\n",
+       "    sh_demand_kWh               (EGID) float64 8.577e+03 9.189e+03 ... 1.104e+04\n",
+       "    Phi                         (EGID) float64 3.0 3.0 4.0 7.0 ... 2.0 2.0 4.0\n",
+       "    K_rad                       (EGID) float64 100.0 100.0 133.3 ... 66.67 133.3\n",
+       "    geo_potential_kWh           (EGID) float64 3.035e+04 1.482e+04 ... 1.554e+04\n",
+       "    elec_demand_kWh             (EGID) float64 3.699e+03 3.699e+03 ... 0.0\n",
+       "    pv_potential_kWh            (EGID) float64 1.239e+04 1.106e+04 ... 7.233e+03\n",
+       "    radiation_kWh_m2            (EGID) float64 2.238e+03 2.041e+03 ... 1.251e+03\n",
+       "    available_area              (EGID) float64 84.46 82.14 85.59 ... 6.343 42.85\n",
+       "    N_roofs                     (EGID) int64 2 2 2 2 2 2 2 2 ... 0 1 0 3 1 0 0 1\n",
+       "    roof_surface                (EGID) float64 144.4 146.2 140.0 ... 72.34 166.1\n",
+       "    tes_capacity_L              (EGID) float64 400.0 400.0 ... 800.0 2.4e+03\n",
+       "    gshp_hourly_sh_cop          (EGID, timestamp_ID) float64 4.472 4.428 ... nan\n",
+       "    pv_hourly_potential         (EGID, timestamp_ID) float64 0.0 0.0 ... 0.0 0.0\n",
+       "    elec_hourly_demand          (EGID, timestamp_ID) float64 298.2 ... 1.472e+03\n",
+       "    gshp_hourly_operation       (EGID, timestamp_ID) float64 181.6 189.9 ... nan
" + ], + "text/plain": [ + "\n", + "Dimensions: (EGID: 518, timestamp_ID: 288)\n", + "Coordinates:\n", + " * EGID (EGID) object '1028823' '1028824' ... '9082379'\n", + " * timestamp_ID (timestamp_ID) int64 0 1 2 3 ... 284 285 286 287\n", + "Data variables:\n", + " hyd_mod_return_temperature (EGID, timestamp_ID) float64 27.51 ... 29.86\n", + " ashp_hourly_operation (EGID, timestamp_ID) float64 nan nan ... 362.3\n", + " ashp_hourly_dhw_cop (EGID, timestamp_ID) float64 nan nan ... 2.633\n", + " gshp_hourly_dhw_cop (EGID, timestamp_ID) float64 2.615 2.615 ... nan\n", + " eh_hourly_operation (EGID, timestamp_ID) float64 0.0 0.0 ... nan nan\n", + " xhp_hourly_maximum_load (EGID, timestamp_ID) float64 3.0 3.0 ... nan nan\n", + " ashp_hourly_sh_cop (EGID, timestamp_ID) float64 nan nan ... 3.273\n", + " dhw_demand_W (EGID, timestamp_ID) float64 8.644 ... 424.1\n", + " sh_demand_W (EGID, timestamp_ID) float64 797.3 ... 2.185e+03\n", + " hyd_mod_supply_temperature (EGID, timestamp_ID) float64 24.85 ... 26.26\n", + " sector (EGID) object 'RES' 'RES' 'RES' ... 'RES' 'SER'\n", + " BLD_ID (EGID) float64 1.5e+08 1.5e+08 ... 1.5e+08\n", + " footprint (EGID) float64 97.0 97.0 96.0 ... 64.0 167.0\n", + " N_floors (EGID) float64 1.0 1.0 1.0 1.0 ... 3.0 2.0 1.0\n", + " floor_area (EGID) float64 97.0 97.0 96.0 ... 128.0 167.0\n", + " geometry (EGID) object 'POINT (2496755.5 1117207.75)' ...\n", + " dhw_demand_kWh (EGID) float64 2.016e+03 2.16e+03 ... 1.102e+04\n", + " sh_demand_kWh (EGID) float64 8.577e+03 9.189e+03 ... 1.104e+04\n", + " Phi (EGID) float64 3.0 3.0 4.0 7.0 ... 2.0 2.0 4.0\n", + " K_rad (EGID) float64 100.0 100.0 133.3 ... 66.67 133.3\n", + " geo_potential_kWh (EGID) float64 3.035e+04 1.482e+04 ... 1.554e+04\n", + " elec_demand_kWh (EGID) float64 3.699e+03 3.699e+03 ... 0.0\n", + " pv_potential_kWh (EGID) float64 1.239e+04 1.106e+04 ... 7.233e+03\n", + " radiation_kWh_m2 (EGID) float64 2.238e+03 2.041e+03 ... 1.251e+03\n", + " available_area (EGID) float64 84.46 82.14 85.59 ... 6.343 42.85\n", + " N_roofs (EGID) int64 2 2 2 2 2 2 2 2 ... 0 1 0 3 1 0 0 1\n", + " roof_surface (EGID) float64 144.4 146.2 140.0 ... 72.34 166.1\n", + " tes_capacity_L (EGID) float64 400.0 400.0 ... 800.0 2.4e+03\n", + " gshp_hourly_sh_cop (EGID, timestamp_ID) float64 4.472 4.428 ... nan\n", + " pv_hourly_potential (EGID, timestamp_ID) float64 0.0 0.0 ... 0.0 0.0\n", + " elec_hourly_demand (EGID, timestamp_ID) float64 298.2 ... 1.472e+03\n", + " gshp_hourly_operation (EGID, timestamp_ID) float64 181.6 189.9 ... nan" + ] + }, + "execution_count": 5, + "metadata": {}, + "output_type": "execute_result" + } + ], + "source": [ + "data_xr" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "# Select EGID" + ] + }, + { + "cell_type": "code", + "execution_count": null, + "metadata": {}, + "outputs": [], + "source": [] + }, + { + "cell_type": "code", + "execution_count": null, + "metadata": {}, + "outputs": [], + "source": [] + }, + { + "cell_type": "code", + "execution_count": null, + "metadata": {}, + "outputs": [], + "source": [] + } + ], + "metadata": { + "kernelspec": { + "display_name": "Python 3", + "language": "python", + "name": "python3" + }, + "language_info": { + "codemirror_mode": { + "name": "ipython", + "version": 3 + }, + "file_extension": ".py", + "mimetype": "text/x-python", + "name": "python", + "nbconvert_exporter": "python", + "pygments_lexer": "ipython3", + "version": "3.7.6" + } + }, + "nbformat": 4, + "nbformat_minor": 4 +}