{ "cells": [ { "cell_type": "code", "execution_count": 1, "metadata": {}, "outputs": [ { "name": "stdout", "output_type": "stream", "text": [ "Requirement already satisfied: folium in /home/a24jacqb/.julia/conda/3/x86_64/lib/python3.12/site-packages (0.19.4)\n", "Requirement already satisfied: pandas in /home/a24jacqb/.julia/conda/3/x86_64/lib/python3.12/site-packages (2.2.3)\n", "Requirement already satisfied: OSMnx in /home/a24jacqb/.julia/conda/3/x86_64/lib/python3.12/site-packages (2.0.1)\n", "Requirement already satisfied: networkx in /home/a24jacqb/.julia/conda/3/x86_64/lib/python3.12/site-packages (3.4.2)\n", "Requirement already satisfied: scikit-learn in /home/a24jacqb/.julia/conda/3/x86_64/lib/python3.12/site-packages (1.6.1)\n", "Requirement already satisfied: matplotlib in /home/a24jacqb/.julia/conda/3/x86_64/lib/python3.12/site-packages (3.10.1)\n", "Requirement already satisfied: numpy in /home/a24jacqb/.julia/conda/3/x86_64/lib/python3.12/site-packages (2.2.3)\n", "Requirement already satisfied: branca>=0.6.0 in /home/a24jacqb/.julia/conda/3/x86_64/lib/python3.12/site-packages (from folium) (0.8.1)\n", "Requirement already satisfied: jinja2>=2.9 in /home/a24jacqb/.julia/conda/3/x86_64/lib/python3.12/site-packages (from folium) (3.1.5)\n", "Requirement already satisfied: requests in /home/a24jacqb/.julia/conda/3/x86_64/lib/python3.12/site-packages (from folium) (2.32.3)\n", "Requirement already satisfied: xyzservices in /home/a24jacqb/.julia/conda/3/x86_64/lib/python3.12/site-packages (from folium) (2025.1.0)\n", "Requirement already satisfied: python-dateutil>=2.8.2 in /home/a24jacqb/.julia/conda/3/x86_64/lib/python3.12/site-packages (from pandas) (2.9.0.post0)\n", "Requirement already satisfied: pytz>=2020.1 in /home/a24jacqb/.julia/conda/3/x86_64/lib/python3.12/site-packages (from pandas) (2025.1)\n", "Requirement already satisfied: tzdata>=2022.7 in /home/a24jacqb/.julia/conda/3/x86_64/lib/python3.12/site-packages (from pandas) (2025.1)\n", "Requirement already satisfied: geopandas>=1.0 in /home/a24jacqb/.julia/conda/3/x86_64/lib/python3.12/site-packages (from OSMnx) (1.0.1)\n", "Requirement already satisfied: shapely>=2.0 in /home/a24jacqb/.julia/conda/3/x86_64/lib/python3.12/site-packages (from OSMnx) (2.0.7)\n", "Requirement already satisfied: scipy>=1.6.0 in /home/a24jacqb/.julia/conda/3/x86_64/lib/python3.12/site-packages (from scikit-learn) (1.15.2)\n", "Requirement already satisfied: joblib>=1.2.0 in /home/a24jacqb/.julia/conda/3/x86_64/lib/python3.12/site-packages (from scikit-learn) (1.4.2)\n", "Requirement already satisfied: threadpoolctl>=3.1.0 in /home/a24jacqb/.julia/conda/3/x86_64/lib/python3.12/site-packages (from scikit-learn) (3.5.0)\n", "Requirement already satisfied: contourpy>=1.0.1 in /home/a24jacqb/.julia/conda/3/x86_64/lib/python3.12/site-packages (from matplotlib) (1.3.1)\n", "Requirement already satisfied: cycler>=0.10 in /home/a24jacqb/.julia/conda/3/x86_64/lib/python3.12/site-packages (from matplotlib) (0.12.1)\n", "Requirement already satisfied: fonttools>=4.22.0 in /home/a24jacqb/.julia/conda/3/x86_64/lib/python3.12/site-packages (from matplotlib) (4.56.0)\n", "Requirement already satisfied: kiwisolver>=1.3.1 in /home/a24jacqb/.julia/conda/3/x86_64/lib/python3.12/site-packages (from matplotlib) (1.4.8)\n", "Requirement already satisfied: packaging>=20.0 in /home/a24jacqb/.julia/conda/3/x86_64/lib/python3.12/site-packages (from matplotlib) (24.2)\n", "Requirement already satisfied: pillow>=8 in /home/a24jacqb/.julia/conda/3/x86_64/lib/python3.12/site-packages (from matplotlib) (11.1.0)\n", "Requirement already satisfied: pyparsing>=2.3.1 in /home/a24jacqb/.julia/conda/3/x86_64/lib/python3.12/site-packages (from matplotlib) (3.2.1)\n", "Requirement already satisfied: pyogrio>=0.7.2 in /home/a24jacqb/.julia/conda/3/x86_64/lib/python3.12/site-packages (from geopandas>=1.0->OSMnx) (0.10.0)\n", "Requirement already satisfied: pyproj>=3.3.0 in /home/a24jacqb/.julia/conda/3/x86_64/lib/python3.12/site-packages (from geopandas>=1.0->OSMnx) (3.7.1)\n", "Requirement already satisfied: MarkupSafe>=2.0 in /home/a24jacqb/.julia/conda/3/x86_64/lib/python3.12/site-packages (from jinja2>=2.9->folium) (3.0.2)\n", "Requirement already satisfied: six>=1.5 in /home/a24jacqb/.julia/conda/3/x86_64/lib/python3.12/site-packages (from python-dateutil>=2.8.2->pandas) (1.17.0)\n", "Requirement already satisfied: charset_normalizer<4,>=2 in /home/a24jacqb/.julia/conda/3/x86_64/lib/python3.12/site-packages (from requests->folium) (3.4.1)\n", "Requirement already satisfied: idna<4,>=2.5 in /home/a24jacqb/.julia/conda/3/x86_64/lib/python3.12/site-packages (from requests->folium) (3.10)\n", "Requirement already satisfied: urllib3<3,>=1.21.1 in /home/a24jacqb/.julia/conda/3/x86_64/lib/python3.12/site-packages (from requests->folium) (2.3.0)\n", "Requirement already satisfied: certifi>=2017.4.17 in /home/a24jacqb/.julia/conda/3/x86_64/lib/python3.12/site-packages (from requests->folium) (2025.1.31)\n", "Note: you may need to restart the kernel to use updated packages.\n" ] } ], "source": [ "%pip install folium pandas OSMnx networkx scikit-learn matplotlib numpy" ] }, { "cell_type": "code", "execution_count": 2, "metadata": {}, "outputs": [], "source": [ "import solution_reader\n", "import datetime as dt\n", "import folium" ] }, { "cell_type": "code", "execution_count": 3, "metadata": {}, "outputs": [], "source": [ "# Files\n", "solutionFile = \"./../output/Nantes_1_sol.json\"\n", "dataFile = \"./../data_in/Nantes_1.json\"" ] }, { "cell_type": "code", "execution_count": 4, "metadata": {}, "outputs": [], "source": [ "solution = solution_reader.PDPTWSolution(solutionFile)\n", "data = solution_reader.PDPTWData(dataFile)" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "# Map" ] }, { "cell_type": "code", "execution_count": 5, "metadata": {}, "outputs": [ { "data": { "text/html": [ "<iframe srcdoc=\"<!DOCTYPE html>\n", "<html>\n", "<head>\n", " \n", " <meta http-equiv="content-type" content="text/html; charset=UTF-8" />\n", " \n", " <script>\n", " L_NO_TOUCH = false;\n", " L_DISABLE_3D = false;\n", " </script>\n", " \n", " <style>html, body {width: 100%;height: 100%;margin: 0;padding: 0;}</style>\n", " <style>#map {position:absolute;top:0;bottom:0;right:0;left:0;}</style>\n", " <script src="https://cdn.jsdelivr.net/npm/leaflet@1.9.3/dist/leaflet.js"></script>\n", " <script src="https://code.jquery.com/jquery-3.7.1.min.js"></script>\n", " <script src="https://cdn.jsdelivr.net/npm/bootstrap@5.2.2/dist/js/bootstrap.bundle.min.js"></script>\n", " <script src="https://cdnjs.cloudflare.com/ajax/libs/Leaflet.awesome-markers/2.0.2/leaflet.awesome-markers.js"></script>\n", " <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/leaflet@1.9.3/dist/leaflet.css"/>\n", " <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/bootstrap@5.2.2/dist/css/bootstrap.min.css"/>\n", " <link rel="stylesheet" href="https://netdna.bootstrapcdn.com/bootstrap/3.0.0/css/bootstrap-glyphicons.css"/>\n", " <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/@fortawesome/fontawesome-free@6.2.0/css/all.min.css"/>\n", " <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/Leaflet.awesome-markers/2.0.2/leaflet.awesome-markers.css"/>\n", " <link rel="stylesheet" href="https://cdn.jsdelivr.net/gh/python-visualization/folium/folium/templates/leaflet.awesome.rotate.min.css"/>\n", " \n", " <meta name="viewport" content="width=device-width,\n", " initial-scale=1.0, maximum-scale=1.0, user-scalable=no" />\n", " <style>\n", " #map_dd7aa15682fe2b2f86d0dd49ca124dfc {\n", " position: relative;\n", " width: 100.0%;\n", " height: 100.0%;\n", " left: 0.0%;\n", " top: 0.0%;\n", " }\n", " .leaflet-container { font-size: 1rem; }\n", " </style>\n", " \n", "</head>\n", "<body>\n", " \n", " \n", " <div class="folium-map" id="map_dd7aa15682fe2b2f86d0dd49ca124dfc" ></div>\n", " \n", "</body>\n", "<script>\n", " \n", " \n", " var map_dd7aa15682fe2b2f86d0dd49ca124dfc = L.map(\n", " "map_dd7aa15682fe2b2f86d0dd49ca124dfc",\n", " {\n", " center: [47.213811, -1.553168],\n", " crs: L.CRS.EPSG3857,\n", " ...{\n", " "zoom": 15,\n", " "zoomControl": true,\n", " "preferCanvas": false,\n", "}\n", "\n", " }\n", " );\n", "\n", " \n", "\n", " \n", " \n", " var tile_layer_313992cc9f44ab843f525d4d04dec547 = L.tileLayer(\n", " "https://tile.openstreetmap.org/{z}/{x}/{y}.png",\n", " {\n", " "minZoom": 0,\n", " "maxZoom": 19,\n", " "maxNativeZoom": 19,\n", " "noWrap": false,\n", " "attribution": "\\u0026copy; \\u003ca href=\\"https://www.openstreetmap.org/copyright\\"\\u003eOpenStreetMap\\u003c/a\\u003e contributors",\n", " "subdomains": "abc",\n", " "detectRetina": false,\n", " "tms": false,\n", " "opacity": 1,\n", "}\n", "\n", " );\n", " \n", " \n", " tile_layer_313992cc9f44ab843f525d4d04dec547.addTo(map_dd7aa15682fe2b2f86d0dd49ca124dfc);\n", " \n", " \n", " var marker_d375e836c2230fa062f3ecb808bf769d = L.marker(\n", " [47.218371, -1.553621],\n", " {\n", "}\n", " ).addTo(map_dd7aa15682fe2b2f86d0dd49ca124dfc);\n", " \n", " \n", " var icon_95224acef0ca520620255cc37f211201 = L.AwesomeMarkers.icon(\n", " {\n", " "markerColor": "red",\n", " "iconColor": "white",\n", " "icon": "info-sign",\n", " "prefix": "glyphicon",\n", " "extraClasses": "fa-rotate-0",\n", " "popup": "DEPOT",\n", "}\n", " );\n", " marker_d375e836c2230fa062f3ecb808bf769d.setIcon(icon_95224acef0ca520620255cc37f211201);\n", " \n", " \n", " var marker_0b7e1183770c1720ca8da3c6587e6882 = L.marker(\n", " [47.213568, -1.555056],\n", " {\n", "}\n", " ).addTo(map_dd7aa15682fe2b2f86d0dd49ca124dfc);\n", " \n", " \n", " var icon_9a7aa7e905876bbf5034ec91adc21c19 = L.AwesomeMarkers.icon(\n", " {\n", " "markerColor": "darkblue",\n", " "iconColor": "white",\n", " "icon": "info-sign",\n", " "prefix": "glyphicon",\n", " "extraClasses": "fa-rotate-0",\n", " "popup": "pickup",\n", "}\n", " );\n", " marker_0b7e1183770c1720ca8da3c6587e6882.setIcon(icon_9a7aa7e905876bbf5034ec91adc21c19);\n", " \n", " \n", " var marker_a568cbf56f9d1a8dff17476b96ff7c71 = L.marker(\n", " [47.220253, -1.550774],\n", " {\n", "}\n", " ).addTo(map_dd7aa15682fe2b2f86d0dd49ca124dfc);\n", " \n", " \n", " var icon_2e7843d0d13a055c3cde9f17694f6d66 = L.AwesomeMarkers.icon(\n", " {\n", " "markerColor": "darkblue",\n", " "iconColor": "white",\n", " "icon": "info-sign",\n", " "prefix": "glyphicon",\n", " "extraClasses": "fa-rotate-0",\n", " "popup": "pickup",\n", "}\n", " );\n", " marker_a568cbf56f9d1a8dff17476b96ff7c71.setIcon(icon_2e7843d0d13a055c3cde9f17694f6d66);\n", " \n", " \n", " var marker_b26dbe11a57522b60e2884531de8f9a9 = L.marker(\n", " [47.209292, -1.560482],\n", " {\n", "}\n", " ).addTo(map_dd7aa15682fe2b2f86d0dd49ca124dfc);\n", " \n", " \n", " var icon_4dcf58e2f04a64c634fa2dd57e84ff1f = L.AwesomeMarkers.icon(\n", " {\n", " "markerColor": "darkblue",\n", " "iconColor": "white",\n", " "icon": "info-sign",\n", " "prefix": "glyphicon",\n", " "extraClasses": "fa-rotate-0",\n", " "popup": "pickup",\n", "}\n", " );\n", " marker_b26dbe11a57522b60e2884531de8f9a9.setIcon(icon_4dcf58e2f04a64c634fa2dd57e84ff1f);\n", " \n", " \n", " var marker_63757d99daa23414c554eafbde0c6dfd = L.marker(\n", " [47.216312, -1.548712],\n", " {\n", "}\n", " ).addTo(map_dd7aa15682fe2b2f86d0dd49ca124dfc);\n", " \n", " \n", " var icon_ac0adf56db721078e50cbf7e9681940b = L.AwesomeMarkers.icon(\n", " {\n", " "markerColor": "darkblue",\n", " "iconColor": "white",\n", " "icon": "info-sign",\n", " "prefix": "glyphicon",\n", " "extraClasses": "fa-rotate-0",\n", " "popup": "pickup",\n", "}\n", " );\n", " marker_63757d99daa23414c554eafbde0c6dfd.setIcon(icon_ac0adf56db721078e50cbf7e9681940b);\n", " \n", " \n", " var marker_d5bc3f91330a41801f0308adfbfae9ee = L.marker(\n", " [47.223158, -1.557308],\n", " {\n", "}\n", " ).addTo(map_dd7aa15682fe2b2f86d0dd49ca124dfc);\n", " \n", " \n", " var icon_9962d6276856cd1fe843d9939cdd4888 = L.AwesomeMarkers.icon(\n", " {\n", " "markerColor": "darkblue",\n", " "iconColor": "white",\n", " "icon": "info-sign",\n", " "prefix": "glyphicon",\n", " "extraClasses": "fa-rotate-0",\n", " "popup": "pickup",\n", "}\n", " );\n", " marker_d5bc3f91330a41801f0308adfbfae9ee.setIcon(icon_9962d6276856cd1fe843d9939cdd4888);\n", " \n", " \n", " var marker_83286a922b2f5015d46c484654c73aea = L.marker(\n", " [47.219011, -1.563922],\n", " {\n", "}\n", " ).addTo(map_dd7aa15682fe2b2f86d0dd49ca124dfc);\n", " \n", " \n", " var icon_ee3bdddece3d607653dd237ebec9f3d6 = L.AwesomeMarkers.icon(\n", " {\n", " "markerColor": "lightblue",\n", " "iconColor": "white",\n", " "icon": "info-sign",\n", " "prefix": "glyphicon",\n", " "extraClasses": "fa-rotate-0",\n", " "popup": "delivery",\n", "}\n", " );\n", " marker_83286a922b2f5015d46c484654c73aea.setIcon(icon_ee3bdddece3d607653dd237ebec9f3d6);\n", " \n", " \n", " var marker_b4e58ebd871838badcd2195a232be79b = L.marker(\n", " [47.214682, -1.554387],\n", " {\n", "}\n", " ).addTo(map_dd7aa15682fe2b2f86d0dd49ca124dfc);\n", " \n", " \n", " var icon_09eb3daf0dfc60fcdd8a7c443bf6c9ba = L.AwesomeMarkers.icon(\n", " {\n", " "markerColor": "lightblue",\n", " "iconColor": "white",\n", " "icon": "info-sign",\n", " "prefix": "glyphicon",\n", " "extraClasses": "fa-rotate-0",\n", " "popup": "delivery",\n", "}\n", " );\n", " marker_b4e58ebd871838badcd2195a232be79b.setIcon(icon_09eb3daf0dfc60fcdd8a7c443bf6c9ba);\n", " \n", " \n", " var marker_8633392b937e16a6449f18ac6615299d = L.marker(\n", " [47.217748, -1.552834],\n", " {\n", "}\n", " ).addTo(map_dd7aa15682fe2b2f86d0dd49ca124dfc);\n", " \n", " \n", " var icon_df5e2ef2c374ae20979ca012840d207a = L.AwesomeMarkers.icon(\n", " {\n", " "markerColor": "lightblue",\n", " "iconColor": "white",\n", " "icon": "info-sign",\n", " "prefix": "glyphicon",\n", " "extraClasses": "fa-rotate-0",\n", " "popup": "delivery",\n", "}\n", " );\n", " marker_8633392b937e16a6449f18ac6615299d.setIcon(icon_df5e2ef2c374ae20979ca012840d207a);\n", " \n", " \n", " var marker_6a4e46838b3bdcb9f4e8d6aad5e27d50 = L.marker(\n", " [47.210421, -1.561234],\n", " {\n", "}\n", " ).addTo(map_dd7aa15682fe2b2f86d0dd49ca124dfc);\n", " \n", " \n", " var icon_edb2d99a2137a6868ba042de9d8572f1 = L.AwesomeMarkers.icon(\n", " {\n", " "markerColor": "lightblue",\n", " "iconColor": "white",\n", " "icon": "info-sign",\n", " "prefix": "glyphicon",\n", " "extraClasses": "fa-rotate-0",\n", " "popup": "delivery",\n", "}\n", " );\n", " marker_6a4e46838b3bdcb9f4e8d6aad5e27d50.setIcon(icon_edb2d99a2137a6868ba042de9d8572f1);\n", " \n", " \n", " var marker_ccf39a13dd1a51471522c6b3444785db = L.marker(\n", " [47.213824, -1.558907],\n", " {\n", "}\n", " ).addTo(map_dd7aa15682fe2b2f86d0dd49ca124dfc);\n", " \n", " \n", " var icon_a3655614d19e24a583d4c3330bc7df8b = L.AwesomeMarkers.icon(\n", " {\n", " "markerColor": "lightblue",\n", " "iconColor": "white",\n", " "icon": "info-sign",\n", " "prefix": "glyphicon",\n", " "extraClasses": "fa-rotate-0",\n", " "popup": "delivery",\n", "}\n", " );\n", " marker_ccf39a13dd1a51471522c6b3444785db.setIcon(icon_a3655614d19e24a583d4c3330bc7df8b);\n", " \n", " \n", " var poly_line_75be16bada57875ae31eed084aa1373e = L.polyline(\n", " [[47.2183453, -1.5534755], [47.2180456, -1.5534249], [47.2179026, -1.5534213], [47.2173096, -1.5533652], [47.2163273, -1.552867], [47.2160168, -1.5534298], [47.2158832, -1.5537904], [47.2156671, -1.5543686], [47.2155362, -1.5547237], [47.2154727, -1.5548879], [47.2154154, -1.5550336], [47.2153044, -1.555331], [47.2150828, -1.5559266], [47.2150388, -1.5560491], [47.2150223, -1.5560952], [47.2150106, -1.5561331], [47.2149286, -1.5563563], [47.2148674, -1.5565232], [47.2144755, -1.5576091], [47.2143928, -1.5578413], [47.2143668, -1.5579057], [47.2141806, -1.5584372], [47.2141855, -1.5586343], [47.2139823, -1.5587194], [47.2138656, -1.558768], [47.213595, -1.5588636], [47.2133024, -1.5589669], [47.2132707, -1.5589781], [47.2126378, -1.5591137], [47.2121042, -1.5593879], [47.2117136, -1.559891], [47.2116749, -1.5597488], [47.2113887, -1.5605287], [47.2112181, -1.5609503], [47.2110607, -1.5613661], [47.2101237, -1.5616227], [47.2100646, -1.5616045], [47.2100053, -1.5616541], [47.2099268, -1.5616842], [47.2098593, -1.5615066], [47.209841, -1.5614154], [47.2098043, -1.5612944], [47.2097481, -1.5610591], [47.2097481, -1.5610591], [47.2098572, -1.5612284], [47.2098934, -1.5611817], [47.210006, -1.5612451], [47.2104866, -1.5600564], [47.2105383, -1.5599477], [47.2106919, -1.5595986], [47.210698, -1.5595018], [47.210765, -1.559475], [47.2112648, -1.5589293], [47.2113092, -1.5587873], [47.2114439, -1.5587814], [47.2114847, -1.5588541], [47.2115747, -1.5588769], [47.2119118, -1.5588963], [47.2124823, -1.5576001], [47.2127522, -1.5569902], [47.2130621, -1.5562719], [47.2133885, -1.5554467], [47.2137115, -1.5552366], [47.2137115, -1.5552366], [47.2133885, -1.5554467], [47.2139676, -1.5558336], [47.214047, -1.5555956], [47.214322, -1.5558496], [47.2149286, -1.5563563], [47.2152704, -1.5565161], [47.2156942, -1.5566909], [47.2160719, -1.5568626], [47.2161023, -1.5566372], [47.2160668, -1.556594], [47.216062, -1.55652], [47.2160888, -1.5564689], [47.2161627, -1.5564754], [47.2162459, -1.5565005], [47.2162987, -1.5563239], [47.2163182, -1.5562613], [47.2166103, -1.5553853], [47.2166552, -1.5552407], [47.2167391, -1.5549874], [47.2168734, -1.5545202], [47.2170421, -1.5545425], [47.2171995, -1.5538062], [47.2173096, -1.5533652], [47.2179026, -1.5534213], [47.2179732, -1.5529077], [47.2179732, -1.5529077], [47.2179026, -1.5534213], [47.2178056, -1.5542105], [47.2177651, -1.5545826], [47.2177545, -1.554897], [47.2176684, -1.5548815], [47.2173841, -1.5547654], [47.2167391, -1.5549874], [47.2166552, -1.5552407], [47.2166103, -1.5553853], [47.2163182, -1.5562613], [47.2162987, -1.5563239], [47.2164163, -1.5564274], [47.2163872, -1.5565937], [47.2163782, -1.5566448], [47.2163685, -1.5566999], [47.2163262, -1.5569411], [47.2162653, -1.5569158], [47.2163908, -1.5570911], [47.2168916, -1.5577689], [47.2178606, -1.5591488], [47.2177585, -1.5592958], [47.2174626, -1.5595293], [47.2173537, -1.5596481], [47.2173628, -1.5597536], [47.217422, -1.5601737], [47.2176085, -1.5613937], [47.2176974, -1.5620016], [47.217875, -1.5623626], [47.2180253, -1.5626025], [47.2184235, -1.5632157], [47.2184899, -1.5633144], [47.2185675, -1.5632755], [47.2186651, -1.563122], [47.2187473, -1.5632832], [47.2186498, -1.56339], [47.2186631, -1.5636429], [47.219081, -1.5643201], [47.219081, -1.5643201], [47.2195174, -1.5638054], [47.2192922, -1.5634829], [47.2202091, -1.5623961], [47.2202406, -1.5620657], [47.2201827, -1.561978], [47.2202337, -1.5618217], [47.2202964, -1.5618185], [47.2208756, -1.5619707], [47.2209515, -1.5616614], [47.2208425, -1.5614354], [47.2205302, -1.5607196], [47.2204977, -1.5606348], [47.2204344, -1.560452], [47.2200804, -1.5592354], [47.2200109, -1.5589945], [47.2199823, -1.558947], [47.2199731, -1.5589098], [47.2200193, -1.5586361], [47.2200296, -1.5586236], [47.2201608, -1.558607], [47.2203358, -1.558474], [47.2207131, -1.557133], [47.2209603, -1.5563172], [47.2209331, -1.5562339], [47.2209355, -1.5562025], [47.220957, -1.5561485], [47.221036, -1.5557407], [47.2210876, -1.5556392], [47.2211358, -1.5556193], [47.2211711, -1.5555632], [47.2211884, -1.5555797], [47.2211918, -1.5556247], [47.2215321, -1.5559809], [47.2218819, -1.5562763], [47.2225196, -1.556822], [47.2227481, -1.5570086], [47.2227481, -1.5570086], [47.2225196, -1.556822], [47.2218819, -1.5562763], [47.2215321, -1.5559809], [47.2211643, -1.5556505], [47.2211358, -1.5556193], [47.2210876, -1.5556392], [47.2205384, -1.5551774], [47.220372, -1.5554198], [47.2192285, -1.5569368], [47.218466, -1.5575159], [47.2177308, -1.5576904], [47.2175953, -1.5575156], [47.2173674, -1.5579742], [47.2155435, -1.558366], [47.2150354, -1.558371], [47.2148049, -1.5582289], [47.2146123, -1.5587577], [47.214493, -1.5588765], [47.2143149, -1.5588703], [47.2141855, -1.5586343], [47.2139823, -1.5587194], [47.2138656, -1.558768], [47.2138656, -1.558768], [47.2139823, -1.5587194], [47.2141855, -1.5586343], [47.2143149, -1.5588703], [47.214493, -1.5588765], [47.2146123, -1.5587577], [47.2148049, -1.5582289], [47.214887, -1.5579725], [47.2148938, -1.5575822], [47.2155597, -1.557499], [47.2159756, -1.5575279], [47.2160405, -1.5570888], [47.2160719, -1.5568626], [47.2161023, -1.5566372], [47.2160668, -1.556594], [47.216062, -1.55652], [47.2160888, -1.5564689], [47.2161627, -1.5564754], [47.2162459, -1.5565005], [47.2162987, -1.5563239], [47.2163182, -1.5562613], [47.2166103, -1.5553853], [47.2166552, -1.5552407], [47.2167391, -1.5549874], [47.2168734, -1.5545202], [47.2170421, -1.5545425], [47.2171995, -1.5538062], [47.2173096, -1.5533652], [47.2179026, -1.5534213], [47.2179732, -1.5529077], [47.218073, -1.5520648], [47.2182157, -1.5515226], [47.2182438, -1.5515083], [47.218417, -1.5510646], [47.2185079, -1.5509195], [47.2190188, -1.5503685], [47.2191832, -1.5500264], [47.2195042, -1.5493542], [47.2198147, -1.5496147], [47.2200423, -1.5497925], [47.2204434, -1.5501244], [47.2204434, -1.5501244], [47.220934, -1.5505257], [47.2212358, -1.5507737], [47.2214556, -1.5509554], [47.221637, -1.5511152], [47.2216744, -1.551218], [47.2216325, -1.5513221], [47.2214653, -1.5517728], [47.2213479, -1.5518279], [47.221019, -1.5515593], [47.2209031, -1.5514647], [47.2195467, -1.550357], [47.219292, -1.5501333], [47.2190188, -1.5503685], [47.2185079, -1.5509195], [47.218417, -1.5510646], [47.2183259, -1.5510647], [47.2181201, -1.550995], [47.2180341, -1.5509182], [47.2178395, -1.5507793], [47.2177663, -1.5507359], [47.2168008, -1.5502658], [47.2163767, -1.5505283], [47.2161313, -1.550635], [47.2158726, -1.5506172], [47.2152464, -1.5503023], [47.2164709, -1.5469394], [47.216637, -1.5470663], [47.2169383, -1.5473231], [47.2168447, -1.5475416], [47.2167752, -1.5477259], [47.2167752, -1.5477259], [47.2168447, -1.5475416], [47.2169383, -1.5473231], [47.2171505, -1.5467129], [47.2167226, -1.5464322], [47.2165366, -1.5468755], [47.216637, -1.5470663], [47.2164709, -1.5469394], [47.2152464, -1.5503023], [47.2151655, -1.5505279], [47.2149818, -1.5512832], [47.214797, -1.5521377], [47.2145791, -1.5531581], [47.2147045, -1.5531551], [47.214902, -1.5541819], [47.2147737, -1.5544478], [47.2147737, -1.5544478], [47.2146992, -1.5547583], [47.214458, -1.5554], [47.2147699, -1.5556873], [47.2147364, -1.5557976], [47.2150388, -1.5560491], [47.2150223, -1.5560952], [47.2150106, -1.5561331], [47.2149286, -1.5563563], [47.2148674, -1.5565232], [47.2144755, -1.5576091], [47.2143928, -1.5578413], [47.2143668, -1.5579057], [47.2141806, -1.5584372], [47.2141855, -1.5586343], [47.2139823, -1.5587194], [47.2138656, -1.558768], [47.213595, -1.5588636], [47.2133024, -1.5589669], [47.2132707, -1.5589781], [47.2126378, -1.5591137], [47.2121042, -1.5593879], [47.2117136, -1.559891], [47.2116749, -1.5597488], [47.2113887, -1.5605287], [47.2111879, -1.5603633], [47.2109976, -1.5604866], [47.210882, -1.5603657], [47.2108289, -1.5605005], [47.2105292, -1.5612745], [47.2105292, -1.5612745], [47.2108289, -1.5605005], [47.210882, -1.5603657], [47.2107742, -1.560242], [47.2106689, -1.5601512], [47.2106179, -1.5601071], [47.2105539, -1.5601544], [47.2104866, -1.5600564], [47.2105383, -1.5599477], [47.2106919, -1.5595986], [47.210698, -1.5595018], [47.210765, -1.559475], [47.2112648, -1.5589293], [47.2113092, -1.5587873], [47.2114439, -1.5587814], [47.2114847, -1.5588541], [47.2115747, -1.5588769], [47.2119118, -1.5588963], [47.2120003, -1.5591216], [47.2121042, -1.5593879], [47.2126378, -1.5591137], [47.2132707, -1.5589781], [47.2133024, -1.5589669], [47.213595, -1.5588636], [47.2138656, -1.558768], [47.2139823, -1.5587194], [47.2141855, -1.5586343], [47.2143149, -1.5588703], [47.214493, -1.5588765], [47.2146123, -1.5587577], [47.2148049, -1.5582289], [47.214887, -1.5579725], [47.2148938, -1.5575822], [47.2155597, -1.557499], [47.2159756, -1.5575279], [47.2160405, -1.5570888], [47.2160719, -1.5568626], [47.2161023, -1.5566372], [47.2160668, -1.556594], [47.216062, -1.55652], [47.2160888, -1.5564689], [47.2161627, -1.5564754], [47.2162459, -1.5565005], [47.2162987, -1.5563239], [47.2163182, -1.5562613], [47.2166103, -1.5553853], [47.2166552, -1.5552407], [47.2167391, -1.5549874], [47.2173841, -1.5547654], [47.2176684, -1.5548815], [47.2177545, -1.554897], [47.2177651, -1.5545826], [47.2178056, -1.5542105], [47.2179086, -1.5542302], [47.2179566, -1.5542666], [47.2181433, -1.5539675], [47.2183453, -1.5534755]],\n", " {"bubblingMouseEvents": true, "color": "red", "dashArray": null, "dashOffset": null, "fill": false, "fillColor": "red", "fillOpacity": 0.2, "fillRule": "evenodd", "lineCap": "round", "lineJoin": "round", "noClip": false, "opacity": 0.5, "smoothFactor": 0, "stroke": true, "weight": 5}\n", " ).addTo(map_dd7aa15682fe2b2f86d0dd49ca124dfc);\n", " \n", "</script>\n", "</html>\" width=\"1000\" height=\"1000\"style=\"border:none !important;\" \"allowfullscreen\" \"webkitallowfullscreen\" \"mozallowfullscreen\"></iframe>" ], "text/plain": [ "<branca.element.Figure at 0x7ff1b3228f20>" ] }, "execution_count": 5, "metadata": {}, "output_type": "execute_result" } ], "source": [ "f = folium.Figure(width=1000, height=1000)\n", "map = folium.Map(location=(47.213811, -1.553168), zoom_start=15)\n", "solution_reader.display_points_of_interest(map, data)\n", "solution_reader.display_route(map, data, solution, 0)\n", "f.add_child(map)\n", "f" ] } ], "metadata": { "kernelspec": { "display_name": "base", "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.12.8" } }, "nbformat": 4, "nbformat_minor": 2 }