diff --git a/Building_selection.ipynb b/Building_selection.ipynb index dafbd80..b61bf48 100644 --- a/Building_selection.ipynb +++ b/Building_selection.ipynb @@ -2169,7 +2169,7 @@ }, { "cell_type": "code", - "execution_count": 46, + "execution_count": 69, "metadata": {}, "outputs": [ { @@ -2198,8 +2198,8 @@ "source": [ "# remove the rows that are available in lod2 offices from office_buildings_cleaned, office_buildings_cleaned ID_UEV has 0 before the ID_UEV in lod2_offices\n", "lod1_offices = office_buildings_cleaned[~office_buildings_cleaned['ID_UEV'].isin(lod2_offices['ID_UEV'])]\n", - "lod1_offices\n", - "\n", + " \n", + "lod1_offices['lod']='lod1'\n", "# Create a nested dictionary to store the filtered buildings\n", "lod1_buildings_dict = {\n", " 'detached': filter_buildings_by_year_and_category(lod1_offices, 'detached', year_groups, area_categories),\n", @@ -2212,7 +2212,7 @@ }, { "cell_type": "code", - "execution_count": 47, + "execution_count": 58, "metadata": {}, "outputs": [ { @@ -2251,7 +2251,7 @@ }, { "cell_type": "code", - "execution_count": 48, + "execution_count": 70, "metadata": {}, "outputs": [ { @@ -2300,9 +2300,33 @@ " \n", "
\n", "7 rows × 32 columns
\n", + "12 rows × 32 columns
\n", "" ], "text/plain": [ - " OBJECTID ID_UEV CIVIQUE_DE CIVIQUE_FI \\\n", - "6 152835 5027487 2200 2222 \n", - "11 162723 1093039 3725 3747 \n", - "16 134507 1031375 5505 5505 \n", - "25 131897 1039182 1000 1022 \n", - "51 176229 1045045 1000 1000 \n", - "54 173143 1036696 360 360 \n", - "71 175001 1000003 425 425 \n", + " OBJECTID ID_UEV CIVIQUE_DE CIVIQUE_FI \\\n", + "17013 36076 05030608 4477 5605 \n", + "472072 152835 05027487 2200 2222 \n", + "471096 144149 02064363 2030 2050 \n", + "472085 162723 01093039 3725 3747 \n", + "471086 134507 01031375 5505 5505 \n", + "409455 83039 03043402 7250 7250 \n", + "112625 156412 05241231 1431 1431 \n", + "471961 118574 03078491 7035 7077 \n", + "33407 131897 01039182 1000 1022 \n", + "472941 176229 01045045 1000 1000 \n", + "485854 173143 01036696 360 360 \n", + "485175 175001 01000003 425 425 \n", "\n", - " NOM_RUE MUNICIPALI CODE_UTILI \\\n", - "6 rue Sainte-Catherine Est (MTE+MTL) 50 6000 \n", - "11 rue Saint-Denis (MTL) 50 6000 \n", - "16 boulevard Saint-Laurent (MTL) 50 6000 \n", - "25 rue Sainte-Catherine Ouest (MTL+WMT) 50 6000 \n", - "51 rue Saint-Antoine Ouest (MTL) 50 6000 \n", - "54 rue Saint-Jacques (MTL) 50 6000 \n", - "71 avenue Viger Ouest (MTL) 50 6000 \n", + " NOM_RUE MUNICIPALI CODE_UTILI \\\n", + "17013 boulevard Pie-IX (MTL+MTN+SLN) 50 6000 \n", + "472072 rue Sainte-Catherine Est (MTE+MTL) 50 6000 \n", + "471096 boulevard Pie-IX (MTL+MTN+SLN) 50 6000 \n", + "472085 rue Saint-Denis (MTL) 50 6000 \n", + "471086 boulevard Saint-Laurent (MTL) 50 6000 \n", + "409455 rue Marconi (MTL) 50 6000 \n", + "112625 rue Fullum (MTL) 50 6000 \n", + "471961 avenue du Parc (MTL) 50 6000 \n", + "33407 rue Sainte-Catherine Ouest (MTL+WMT) 50 6000 \n", + "472941 rue Saint-Antoine Ouest (MTL) 50 6000 \n", + "485854 rue Saint-Jacques (MTL) 50 6000 \n", + "485175 avenue Viger Ouest (MTL) 50 6000 \n", "\n", - " LIBELLE_UT CATEGORIE_ Hieght_LiD ... \\\n", - "6 Immeuble à bureaux Régulier 33 ... \n", - "11 Immeuble à bureaux Régulier 45 ... \n", - "16 Immeuble à bureaux Régulier 21 ... \n", - "25 Immeuble à bureaux Régulier 54 ... \n", - "51 Immeuble à bureaux Régulier 35 ... \n", - "54 Immeuble à bureaux Régulier 119 ... \n", - "71 Immeuble à bureaux Régulier 48 ... \n", + " LIBELLE_UT CATEGORIE_ Hieght_LiD ... \\\n", + "17013 Immeuble à bureaux Régulier 20 ... \n", + "472072 Immeuble à bureaux Régulier 33 ... \n", + "471096 Immeuble à bureaux Régulier 29 ... \n", + "472085 Immeuble à bureaux Régulier 45 ... \n", + "471086 Immeuble à bureaux Régulier 21 ... \n", + "409455 Immeuble à bureaux Régulier 17 ... \n", + "112625 Immeuble à bureaux Condominium 36 ... \n", + "471961 Immeuble à bureaux Régulier 31 ... \n", + "33407 Immeuble à bureaux Régulier 54 ... \n", + "472941 Immeuble à bureaux Régulier 35 ... \n", + "485854 Immeuble à bureaux Régulier 119 ... \n", + "485175 Immeuble à bureaux Régulier 48 ... \n", "\n", - " geometry ANNEE_CONS \\\n", - "6 POLYGON ((-73.54820576510775 45.52676864822449... 1930 \n", - "11 POLYGON ((-73.57148967173404 45.51994244675434... 1885 \n", - "16 POLYGON ((-73.5982145816157 45.52638694651501,... 1903 \n", - "25 POLYGON ((-73.5721427650387 45.49979176551065,... 1937 \n", - "51 POLYGON ((-73.56513396322417 45.49720581059058... 1925 \n", - "54 POLYGON ((-73.55898286507197 45.50195165560664... 1928 \n", - "71 POLYGON ((-73.5629245675038 45.50346814387118,... 1861 \n", + " geometry ANNEE_CONS \\\n", + "17013 POLYGON ((-73.56772 45.55916, -73.56775 45.559... 1930 \n", + "472072 POLYGON ((-73.54821 45.52677, -73.54826 45.526... 1930 \n", + "471096 POLYGON ((-73.54215 45.54976, -73.54201 45.549... 1918 \n", + "472085 POLYGON ((-73.57149 45.51994, -73.57147 45.519... 1885 \n", + "471086 POLYGON ((-73.59821 45.52639, -73.59820 45.526... 1903 \n", + "409455 POLYGON ((-73.62166 45.53210, -73.62203 45.532... 1941 \n", + "112625 POLYGON ((-73.54871 45.52839, -73.54885 45.528... 1920 \n", + "471961 POLYGON ((-73.61942 45.53031, -73.62015 45.530... 1940 \n", + "33407 POLYGON ((-73.57214 45.49979, -73.57161 45.500... 1937 \n", + "472941 POLYGON ((-73.56513 45.49721, -73.56484 45.497... 1925 \n", + "485854 POLYGON ((-73.55898 45.50195, -73.55870 45.502... 1928 \n", + "485175 POLYGON ((-73.56292 45.50347, -73.56307 45.503... 1861 \n", "\n", - " New_AspectRatio New_SurfacetoVolumeRatio \\\n", - "6 1.436573 0.030303 \n", - "11 1.673016 0.022222 \n", - "16 2.148360 0.047619 \n", - "25 1.332875 0.018519 \n", - "51 1.577369 0.028571 \n", - "54 1.401016 0.008403 \n", - "71 1.901155 0.020833 \n", + " New_AspectRatio New_SurfacetoVolumeRatio \\\n", + "17013 1.954238 0.050000 \n", + "472072 1.436573 0.030303 \n", + "471096 1.750785 0.034483 \n", + "472085 1.673016 0.022222 \n", + "471086 2.148360 0.047619 \n", + "409455 1.611822 0.058824 \n", + "112625 1.142879 0.027778 \n", + "471961 1.442995 0.032258 \n", + "33407 1.332875 0.018519 \n", + "472941 1.577369 0.028571 \n", + "485854 1.401016 0.008403 \n", + "485175 1.901155 0.020833 \n", "\n", - " transformed_geometry calculated_area \\\n", - "6 POLYGON ((613370.0745799394 5042495.465036549,... 8527.804906 \n", - "11 POLYGON ((611565.3436088917 5041704.476042462,... 7065.295017 \n", - "16 POLYGON ((609465.6585284412 5042383.651440187,... 4884.011552 \n", - "25 POLYGON ((611554.1447597386 5039464.894097178,... 3767.206358 \n", - "51 POLYGON ((612106.8518472302 5039187.3624462355... 2476.308750 \n", - "54 POLYGON ((612577.978822547 5039723.213385784, ... 2434.504492 \n", - "71 POLYGON ((612267.0236778263 5039886.172234783,... 1961.248656 \n", + " transformed_geometry calculated_area \\\n", + "17013 POLYGON ((611782.360 5046066.630, 611779.902 5... 48.162656 \n", + "472072 POLYGON ((613370.075 5042495.465, 613365.907 5... 8527.804906 \n", + "471096 POLYGON ((613796.289 5045058.422, 613807.075 5... 7301.335267 \n", + "472085 POLYGON ((611565.344 5041704.476, 611566.649 5... 7065.295017 \n", + "471086 POLYGON ((609465.659 5042383.651, 609466.736 5... 4884.011552 \n", + "409455 POLYGON ((607624.013 5042987.071, 607594.312 5... 4358.896214 \n", + "112625 POLYGON ((613327.397 5042674.552, 613316.075 5... 3953.598369 \n", + "471961 POLYGON ((607802.244 5042791.156, 607744.954 5... 3937.447553 \n", + "33407 POLYGON ((611554.145 5039464.894, 611594.441 5... 3767.206358 \n", + "472941 POLYGON ((612106.852 5039187.362, 612129.347 5... 2476.308750 \n", + "485854 POLYGON ((612577.979 5039723.213, 612599.333 5... 2434.504492 \n", + "485175 POLYGON ((612267.024 5039886.172, 612256.095 5... 1961.248656 \n", "\n", - " YearGroup Building_Size Building_Floors lod \n", - "6 1800-1945 Mega office 4-9 floors lod_2 \n", - "11 1800-1945 Mega office 10+ floors lod_2 \n", - "16 1800-1945 Mega office 4-9 floors lod_2 \n", - "25 1800-1945 Mega office 10+ floors lod_2 \n", - "51 1800-1945 Mega office 4-9 floors lod_2 \n", - "54 1800-1945 Mega office 10+ floors lod_2 \n", - "71 1800-1945 Mega office 10+ floors lod_2 \n", + " YearGroup Building_Size Building_Floors lod \n", + "17013 1800-1945 Mega office 4-9 floors lod1 \n", + "472072 1800-1945 Mega office 4-9 floors lod1 \n", + "471096 1800-1945 Mega office 4-9 floors lod1 \n", + "472085 1800-1945 Mega office 10+ floors lod1 \n", + "471086 1800-1945 Mega office 4-9 floors lod1 \n", + "409455 1800-1945 Mega office 4-9 floors lod1 \n", + "112625 1800-1945 Mega office 4-9 floors lod1 \n", + "471961 1800-1945 Mega office 4-9 floors lod1 \n", + "33407 1800-1945 Mega office 10+ floors lod1 \n", + "472941 1800-1945 Mega office 4-9 floors lod1 \n", + "485854 1800-1945 Mega office 10+ floors lod1 \n", + "485175 1800-1945 Mega office 10+ floors lod1 \n", "\n", - "[7 rows x 32 columns]" + "[12 rows x 32 columns]" ] }, - "execution_count": 48, + "execution_count": 70, "metadata": {}, "output_type": "execute_result" } ], "source": [ - "lod2_buildings_dict['detached']['1800-1945']['Mega Office']" + "lod1_buildings_dict['detached']['1800-1945']['Mega Office']" ] }, { @@ -2589,7 +2744,7 @@ }, { "cell_type": "code", - "execution_count": 52, + "execution_count": 71, "metadata": {}, "outputs": [ { @@ -2642,7 +2797,7 @@ }, { "cell_type": "code", - "execution_count": 54, + "execution_count": 76, "metadata": {}, "outputs": [ { @@ -2677,61 +2832,17 @@ " \n", " \n", " \n", - "