{ "cells": [ { "cell_type": "code", "execution_count": 2, "metadata": {}, "outputs": [], "source": [ "import pandas as pd\n", "import numpy as np\n", "import matplotlib.pyplot as plt\n", "\n", "import os\n", "import json" ] }, { "cell_type": "code", "execution_count": 3, "metadata": {}, "outputs": [], "source": [ "# a = pd.read_csv('./DOT_Traffic_Speeds_NBE.csv')\n", "# save it as parquet\n", "# a.to_parquet('./DOT_Traffic_Speeds_NBE.parquet')\n", "a = pd.read_parquet('../raw_data/all_data.parquet')\n" ] }, { "cell_type": "code", "execution_count": 4, "metadata": {}, "outputs": [], "source": [ "a = a.drop(columns=['ENCODED_POLY_LINE', 'ENCODED_POLY_LINE_LVLS', 'OWNER', 'TRANSCOM_ID', 'LINK_ID'])" ] }, { "cell_type": "code", "execution_count": 5, "metadata": {}, "outputs": [ { "data": { "application/vnd.microsoft.datawrangler.viewer.v0+json": { "columns": [ { "name": "index", "rawType": "int64", "type": "integer" }, { "name": "ID", "rawType": "object", "type": "string" }, { "name": "SPEED", "rawType": "object", "type": "string" }, { "name": "TRAVEL_TIME", "rawType": "object", "type": "string" }, { "name": "STATUS", "rawType": "object", "type": "string" }, { "name": "DATA_AS_OF", "rawType": "datetime64[ns]", "type": "datetime" }, { "name": "LINK_POINTS", "rawType": "object", "type": "string" }, { "name": "BOROUGH", "rawType": "object", "type": "string" }, { "name": "LINK_NAME", "rawType": "object", "type": "string" } ], "ref": "cf09b622-08cf-4f97-b9a4-f19c90ce192d", "rows": [ [ "0", "378", "15.53", "172", "0", "2025-03-06 22:58:09", "40.6210105,-74.168861 40.6207604,-74.168 40.6182105,-74.162381 40.6154,-74.15806 40.6149404,-74.15748", "Staten Island", "SIE E SOUTH AVENUE - RICHMOND AVENUE" ], [ "1", "129", "54.05", "86", "0", "2025-03-06 22:58:09", "40.8240706,-73.874311 40.8247,-73.86959 40.8251906,-73.86596 40.82536,-73.86426 40.82587,-73.85961 40.8266006,-73.85424 40.8271806,-73.84994", "Bronx", "BE N STRATFORD AVENUE - CASTLE HILL AVE" ], [ "2", "126", "54.05", "139", "0", "2025-03-06 22:58:09", "40.8271606,-73.84993 40.82771,-73.84671 40.8284105,-73.843471 40.82869,-73.84133 40.8287905,-73.8386 40.82891,-73.837 40.8292,-73.835541 40.82968,-73.834031 40.8305,-73.83239 40.83211,-73.82983 40.83305,-73.82826 40.83366,-73.82693 40.8343006,-73.82571", "Bronx", "BE N Castle Hill Avenue - Griswold Ave" ], [ "3", "295", "0", "0", "-101", "2025-03-06 22:58:09", "40.84064,-73.83831 40.83881,-73.83853 40.8346304,-73.83839 40.83261,-73.83804 40.83066,-73.837521 40.8280704,-73.83668 40.82495,-73.836211", "Bronx", "HRP N LAFAYETTE AVENUE - E TREMONT AVENUE" ], [ "4", "159", "36.66", "151", "0", "2025-03-06 22:58:09", "40.8563506,-73.87233 40.85219,-73.871371 40.85007,-73.87111 40.8469404,-73.87115 40.8459605,-73.871311 40.8424005,-73.87202 40.83961,-73.87273 40.8362404,-73.87372 40.8349506,-73.8739 40.8333606,-73.873831 40.8319705,-73.873681 40.82985,-73.87313 40.82683", "Bronx", "BRP N WATSON AVENUE - FORDHAM ROAD" ] ], "shape": { "columns": 8, "rows": 5 } }, "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", "
IDSPEEDTRAVEL_TIMESTATUSDATA_AS_OFLINK_POINTSBOROUGHLINK_NAME
037815.5317202025-03-06 22:58:0940.6210105,-74.168861 40.6207604,-74.168 40.61...Staten IslandSIE E SOUTH AVENUE - RICHMOND AVENUE
112954.058602025-03-06 22:58:0940.8240706,-73.874311 40.8247,-73.86959 40.825...BronxBE N STRATFORD AVENUE - CASTLE HILL AVE
212654.0513902025-03-06 22:58:0940.8271606,-73.84993 40.82771,-73.84671 40.828...BronxBE N Castle Hill Avenue - Griswold Ave
329500-1012025-03-06 22:58:0940.84064,-73.83831 40.83881,-73.83853 40.83463...BronxHRP N LAFAYETTE AVENUE - E TREMONT AVENUE
415936.6615102025-03-06 22:58:0940.8563506,-73.87233 40.85219,-73.871371 40.85...BronxBRP N WATSON AVENUE - FORDHAM ROAD
\n", "
" ], "text/plain": [ " ID SPEED TRAVEL_TIME STATUS DATA_AS_OF \\\n", "0 378 15.53 172 0 2025-03-06 22:58:09 \n", "1 129 54.05 86 0 2025-03-06 22:58:09 \n", "2 126 54.05 139 0 2025-03-06 22:58:09 \n", "3 295 0 0 -101 2025-03-06 22:58:09 \n", "4 159 36.66 151 0 2025-03-06 22:58:09 \n", "\n", " LINK_POINTS BOROUGH \\\n", "0 40.6210105,-74.168861 40.6207604,-74.168 40.61... Staten Island \n", "1 40.8240706,-73.874311 40.8247,-73.86959 40.825... Bronx \n", "2 40.8271606,-73.84993 40.82771,-73.84671 40.828... Bronx \n", "3 40.84064,-73.83831 40.83881,-73.83853 40.83463... Bronx \n", "4 40.8563506,-73.87233 40.85219,-73.871371 40.85... Bronx \n", "\n", " LINK_NAME \n", "0 SIE E SOUTH AVENUE - RICHMOND AVENUE \n", "1 BE N STRATFORD AVENUE - CASTLE HILL AVE \n", "2 BE N Castle Hill Avenue - Griswold Ave \n", "3 HRP N LAFAYETTE AVENUE - E TREMONT AVENUE \n", "4 BRP N WATSON AVENUE - FORDHAM ROAD " ] }, "execution_count": 5, "metadata": {}, "output_type": "execute_result" } ], "source": [ "a.head()\n" ] }, { "cell_type": "code", "execution_count": 6, "metadata": {}, "outputs": [], "source": [ "a['DATA_AS_OF'] = pd.to_datetime(a['DATA_AS_OF'], format='%m/%d/%Y %I:%M:%S %p').dt.strftime('%Y%m%d%H%M%S')" ] }, { "cell_type": "code", "execution_count": 7, "metadata": {}, "outputs": [ { "data": { "application/vnd.microsoft.datawrangler.viewer.v0+json": { "columns": [ { "name": "index", "rawType": "int64", "type": "integer" }, { "name": "ID", "rawType": "object", "type": "string" }, { "name": "SPEED", "rawType": "object", "type": "string" }, { "name": "TRAVEL_TIME", "rawType": "object", "type": "string" }, { "name": "STATUS", "rawType": "object", "type": "string" }, { "name": "DATA_AS_OF", "rawType": "object", "type": "string" }, { "name": "LINK_POINTS", "rawType": "object", "type": "string" }, { "name": "BOROUGH", "rawType": "object", "type": "string" }, { "name": "LINK_NAME", "rawType": "object", "type": "string" } ], "ref": "6ad787ae-2106-465b-bbfe-11d18a636980", "rows": [ [ "0", "378", "15.53", "172", "0", "20250306225809", "40.6210105,-74.168861 40.6207604,-74.168 40.6182105,-74.162381 40.6154,-74.15806 40.6149404,-74.15748", "Staten Island", "SIE E SOUTH AVENUE - RICHMOND AVENUE" ], [ "1", "129", "54.05", "86", "0", "20250306225809", "40.8240706,-73.874311 40.8247,-73.86959 40.8251906,-73.86596 40.82536,-73.86426 40.82587,-73.85961 40.8266006,-73.85424 40.8271806,-73.84994", "Bronx", "BE N STRATFORD AVENUE - CASTLE HILL AVE" ], [ "2", "126", "54.05", "139", "0", "20250306225809", "40.8271606,-73.84993 40.82771,-73.84671 40.8284105,-73.843471 40.82869,-73.84133 40.8287905,-73.8386 40.82891,-73.837 40.8292,-73.835541 40.82968,-73.834031 40.8305,-73.83239 40.83211,-73.82983 40.83305,-73.82826 40.83366,-73.82693 40.8343006,-73.82571", "Bronx", "BE N Castle Hill Avenue - Griswold Ave" ], [ "3", "295", "0", "0", "-101", "20250306225809", "40.84064,-73.83831 40.83881,-73.83853 40.8346304,-73.83839 40.83261,-73.83804 40.83066,-73.837521 40.8280704,-73.83668 40.82495,-73.836211", "Bronx", "HRP N LAFAYETTE AVENUE - E TREMONT AVENUE" ], [ "4", "159", "36.66", "151", "0", "20250306225809", "40.8563506,-73.87233 40.85219,-73.871371 40.85007,-73.87111 40.8469404,-73.87115 40.8459605,-73.871311 40.8424005,-73.87202 40.83961,-73.87273 40.8362404,-73.87372 40.8349506,-73.8739 40.8333606,-73.873831 40.8319705,-73.873681 40.82985,-73.87313 40.82683", "Bronx", "BRP N WATSON AVENUE - FORDHAM ROAD" ] ], "shape": { "columns": 8, "rows": 5 } }, "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", "
IDSPEEDTRAVEL_TIMESTATUSDATA_AS_OFLINK_POINTSBOROUGHLINK_NAME
037815.5317202025030622580940.6210105,-74.168861 40.6207604,-74.168 40.61...Staten IslandSIE E SOUTH AVENUE - RICHMOND AVENUE
112954.058602025030622580940.8240706,-73.874311 40.8247,-73.86959 40.825...BronxBE N STRATFORD AVENUE - CASTLE HILL AVE
212654.0513902025030622580940.8271606,-73.84993 40.82771,-73.84671 40.828...BronxBE N Castle Hill Avenue - Griswold Ave
329500-1012025030622580940.84064,-73.83831 40.83881,-73.83853 40.83463...BronxHRP N LAFAYETTE AVENUE - E TREMONT AVENUE
415936.6615102025030622580940.8563506,-73.87233 40.85219,-73.871371 40.85...BronxBRP N WATSON AVENUE - FORDHAM ROAD
\n", "
" ], "text/plain": [ " ID SPEED TRAVEL_TIME STATUS DATA_AS_OF \\\n", "0 378 15.53 172 0 20250306225809 \n", "1 129 54.05 86 0 20250306225809 \n", "2 126 54.05 139 0 20250306225809 \n", "3 295 0 0 -101 20250306225809 \n", "4 159 36.66 151 0 20250306225809 \n", "\n", " LINK_POINTS BOROUGH \\\n", "0 40.6210105,-74.168861 40.6207604,-74.168 40.61... Staten Island \n", "1 40.8240706,-73.874311 40.8247,-73.86959 40.825... Bronx \n", "2 40.8271606,-73.84993 40.82771,-73.84671 40.828... Bronx \n", "3 40.84064,-73.83831 40.83881,-73.83853 40.83463... Bronx \n", "4 40.8563506,-73.87233 40.85219,-73.871371 40.85... Bronx \n", "\n", " LINK_NAME \n", "0 SIE E SOUTH AVENUE - RICHMOND AVENUE \n", "1 BE N STRATFORD AVENUE - CASTLE HILL AVE \n", "2 BE N Castle Hill Avenue - Griswold Ave \n", "3 HRP N LAFAYETTE AVENUE - E TREMONT AVENUE \n", "4 BRP N WATSON AVENUE - FORDHAM ROAD " ] }, "execution_count": 7, "metadata": {}, "output_type": "execute_result" } ], "source": [ "a.head()" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "---------------------------------" ] }, { "cell_type": "code", "execution_count": 8, "metadata": {}, "outputs": [ { "data": { "text/plain": [ "['378',\n", " '129',\n", " '126',\n", " '295',\n", " '159',\n", " '338',\n", " '427',\n", " '381',\n", " '350',\n", " '154',\n", " '435',\n", " '384',\n", " '439',\n", " '385',\n", " '390',\n", " '351',\n", " '388',\n", " '434',\n", " '382',\n", " '383',\n", " '258',\n", " '259',\n", " '261',\n", " '137',\n", " '399',\n", " '426',\n", " '369',\n", " '315',\n", " '171',\n", " '142',\n", " '170',\n", " '425',\n", " '145',\n", " '150',\n", " '4',\n", " '1',\n", " '215',\n", " '217',\n", " '165',\n", " '422',\n", " '377',\n", " '325',\n", " '329',\n", " '265',\n", " '324',\n", " '311',\n", " '119',\n", " '298',\n", " '364',\n", " '211',\n", " '318',\n", " '124',\n", " '365',\n", " '213',\n", " '212',\n", " '405',\n", " '319',\n", " '441',\n", " '345',\n", " '186',\n", " '344',\n", " '191',\n", " '190',\n", " '448',\n", " '417',\n", " '195',\n", " '411',\n", " '207',\n", " '331',\n", " '332',\n", " '169',\n", " '199',\n", " '208',\n", " '450',\n", " '223',\n", " '149',\n", " '221',\n", " '222',\n", " '2',\n", " '3',\n", " '106',\n", " '204',\n", " '167',\n", " '172',\n", " '177',\n", " '424',\n", " '423',\n", " '178',\n", " '157',\n", " '185',\n", " '160',\n", " '148',\n", " '184',\n", " '428',\n", " '453',\n", " '354',\n", " '394',\n", " '433',\n", " '431',\n", " '430',\n", " '387',\n", " '437',\n", " '375',\n", " '376',\n", " '406',\n", " '402',\n", " '451',\n", " '164',\n", " '168',\n", " '202',\n", " '398',\n", " '140',\n", " '141',\n", " '347',\n", " '395',\n", " '330',\n", " '349',\n", " '436',\n", " '264',\n", " '263',\n", " '339',\n", " '445',\n", " '257',\n", " '153',\n", " '155',\n", " '110',\n", " '440',\n", " '206',\n", " '205',\n", " '262',\n", " '418',\n", " '412',\n", " '419',\n", " '413',\n", " '379',\n", " '410',\n", " '416',\n", " '380']" ] }, "execution_count": 8, "metadata": {}, "output_type": "execute_result" } ], "source": [ "# get the unique values of ID\n", "id_list = a['ID'].unique().tolist()\n", "id_list" ] }, { "cell_type": "code", "execution_count": 9, "metadata": {}, "outputs": [ { "data": { "text/plain": [ "138" ] }, "execution_count": 9, "metadata": {}, "output_type": "execute_result" } ], "source": [ "len(id_list)" ] }, { "cell_type": "code", "execution_count": 18, "metadata": {}, "outputs": [ { "data": { "application/vnd.microsoft.datawrangler.viewer.v0+json": { "columns": [ { "name": "index", "rawType": "int64", "type": "integer" }, { "name": "ID", "rawType": "int64", "type": "integer" }, { "name": "SPEED", "rawType": "float64", "type": "float" }, { "name": "TRAVEL_TIME", "rawType": "int64", "type": "integer" }, { "name": "STATUS", "rawType": "int64", "type": "integer" }, { "name": "DATA_AS_OF", "rawType": "object", "type": "string" }, { "name": "LINK_POINTS", "rawType": "object", "type": "string" }, { "name": "BOROUGH", "rawType": "object", "type": "string" }, { "name": "LINK_NAME", "rawType": "object", "type": "string" } ], "conversionMethod": "pd.DataFrame", "ref": "88ca17ea-1389-41fa-ba6c-2c211baa054a", "rows": [ [ "0", "444", "0.0", "0", "-101", "19780101000000", "40.7051105,-74.01663 40.70432,-74.01667 40.7035205,-74.016561 40.70224,-74.015841 40.7016205,-74.01527 40.701401,-74.01473 40.7012804,-74.01399 40.7012,-74.01327 40.701401,-74.012031 40.7018906,-74.00995 40.70306,-74.007731 40.70481,-74.004951 40.70656,-7", "Manhattan", "West St S Battery Pl - FDR N Catherine Slip" ], [ "1", "444", "13.05", "105", "0", "20151208152435", "40.7051105,-74.01663 40.70432,-74.01667 40.7035205,-74.016561 40.70224,-74.015841 40.7016205,-74.01527 40.701401,-74.01473 40.7012804,-74.01399 40.7012,-74.01327 40.701401,-74.012031 40.7018906,-74.00995 40.70306,-74.007731 40.70481,-74.004951 40.70656,-7", "Manhattan", "West St S Battery Pl - FDR N Catherine Slip" ] ], "shape": { "columns": 8, "rows": 2 } }, "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", "
IDSPEEDTRAVEL_TIMESTATUSDATA_AS_OFLINK_POINTSBOROUGHLINK_NAME
04440.000-1011978010100000040.7051105,-74.01663 40.70432,-74.01667 40.703...ManhattanWest St S Battery Pl - FDR N Catherine Slip
144413.0510502015120815243540.7051105,-74.01663 40.70432,-74.01667 40.703...ManhattanWest St S Battery Pl - FDR N Catherine Slip
\n", "
" ], "text/plain": [ " ID SPEED TRAVEL_TIME STATUS DATA_AS_OF \\\n", "0 444 0.00 0 -101 19780101000000 \n", "1 444 13.05 105 0 20151208152435 \n", "\n", " LINK_POINTS BOROUGH \\\n", "0 40.7051105,-74.01663 40.70432,-74.01667 40.703... Manhattan \n", "1 40.7051105,-74.01663 40.70432,-74.01667 40.703... Manhattan \n", "\n", " LINK_NAME \n", "0 West St S Battery Pl - FDR N Catherine Slip \n", "1 West St S Battery Pl - FDR N Catherine Slip " ] }, "execution_count": 18, "metadata": {}, "output_type": "execute_result" } ], "source": [ "df = a[a['ID'].apply(str).str.contains(\"444\", regex=False, na=False, case=False)]\n", "# convert DATA_AS_OF from %m/%d/%Y %I:%M:%S %p to %Y%m%d%H%M%S\n", "# df['DATA_AS_OF'] = pd.to_datetime(df['DATA_AS_OF'], format='%m/%d/%Y %I:%M:%S %p').dt.strftime('%Y%m%d%H%M%S')\n", "df = df.sort_values(['DATA_AS_OF'])\n", "# reset the index\n", "df = df.reset_index(drop=True)\n", "df" ] }, { "cell_type": "code", "execution_count": 10, "metadata": {}, "outputs": [ { "name": "stdout", "output_type": "stream", "text": [ "doing 378doing 129doing 427doing 159doing 126doing 295doing 350doing 381doing 338\n", "doing 435\n", "doing 384doing 439\n", "\n", "doing 154doing 390doing 383doing 382\n", "\n", "doing 434\n", "\n", "doing 261doing 351doing 385\n", "doing 388\n", "doing 315\n", "doing 426\n", "doing 399doing 171\n", "\n", "doing 369doing 137doing 142doing 170\n", "doing 150\n", "doing 4\n", "doing 145doing 215doing 217\n", "doing 1doing 422\n", "doing 425\n", "\n", "doing 377doing 165\n", "doing 119\n", "\n", "doing 265\n", "doing 311doing 298doing 324doing 364doing 124doing 325\n", "doing 211\n", "doing 405doing 213\n", "doing 212\n", "doing 344doing 448\n", "\n", "doing 191\n", "\n", "doing 365\n", "\n", "\n", "\n", "\n", "\n", "\n", "\n", "\n", "doing 345\n", "\n", "\n", "\n", "doing 186\n", "doing 318doing 319doing 190\n", "doing 329\n", "\n", "\n", "\n", "\n", "\n", "\n", "\n", "doing 441\n", "\n", "\n", "\n", "\n", "\n", "doing 259doing 258\n", "\n", "doing 417\n", "doing 195\n", "doing 411\n", "doing 207\n", "doing 331\n", "doing 332\n", "doing 169\n", "doing 199\n", "doing 208\n", "doing 450\n", "doing 223\n", "doing 149\n", "doing 221\n", "doing 222\n", "doing 2\n", "doing 3\n", "doing 106\n", "doing 204\n", "doing 167\n", "doing 172\n", "doing 177\n", "doing 424\n", "doing 423\n", "doing 178\n", "doing 157\n", "doing 185\n", "doing 160doing 148\n", "\n", "doing 428doing 184doing 453\n", "\n", "\n", "doing 354\n", "doing 394\n", "doing 433\n", "doing 431\n", "doing 430\n", "doing 387\n", "doing 437\n", "doing 375\n", "doing 376doing 406\n", "\n", "doing 451doing 402\n", "\n", "doing 164doing 168doing 202\n", "\n", "\n", "doing 398\n", "doing 140doing 141\n", "\n", "doing 347\n", "doing 395\n", "doing 330\n", "doing 349\n", "doing 436\n", "doing 264\n", "doing 263\n", "doing 339\n", "doing 445\n", "doing 257\n", "doing 153\n", "doing 155\n", "doing 110\n", "doing 440\n", "doing 206\n", "doing 205\n", "doing 262\n", "doing 418\n", "doing 412\n", "doing 419\n", "doing 413\n", "doing 379\n", "doing 410\n", "doing 416\n", "doing 380\n" ] } ], "source": [ "from multiprocessing import Pool\n", "\n", "os.makedirs('./full_data', exist_ok=True)\n", "os.makedirs('./slim_data', exist_ok=True)\n", "\n", "def process_id(id):\n", " print(f'doing {id}')\n", " # filter the data by id\n", " df = a[a['ID'] == id]\n", " \n", " # convert DATA_AS_OF from %m/%d/%Y %I:%M:%S %p to %Y%m%d%H%M%S\n", " df = df.sort_values(['DATA_AS_OF'])\n", " # reset the index\n", " df = df.reset_index(drop=True)\n", " df.to_parquet('./full_data/id_{}.parquet'.format(id))\n", " # get the value of BOROUGH column of first raw\n", " borough = df['BOROUGH'].iloc[0]\n", " link = df['LINK_NAME'].iloc[0]\n", " length = len(df)\n", " id_info = {id: {'borough': borough, 'link': link, 'len': length}}\n", " df = df.drop(columns=['BOROUGH', 'LINK_NAME', 'ID','LINK_POINTS', 'STATUS'])\n", " # rearrange the columns\n", " df = df[['DATA_AS_OF', 'SPEED', 'TRAVEL_TIME']]\n", " df.to_parquet('./slim_data/id_{}.parquet'.format(id))\n", " return id_info\n", "\n", "with Pool() as pool:\n", " results = pool.map(process_id, id_list)\n", "\n", "# Combine all the id_info dictionaries into one\n", "id_info = {}\n", "for result in results:\n", " id_info.update(result)\n", "\n", "with open('./id_info.json', 'w') as f:\n", " json.dump(id_info, f)" ] }, { "cell_type": "code", "execution_count": 20, "metadata": {}, "outputs": [ { "data": { "application/vnd.microsoft.datawrangler.viewer.v0+json": { "columns": [ { "name": "index", "rawType": "int64", "type": "integer" }, { "name": "ID", "rawType": "int64", "type": "integer" }, { "name": "SPEED", "rawType": "float64", "type": "float" }, { "name": "TRAVEL_TIME", "rawType": "int64", "type": "integer" }, { "name": "STATUS", "rawType": "int64", "type": "integer" }, { "name": "DATA_AS_OF", "rawType": "object", "type": "string" }, { "name": "LINK_POINTS", "rawType": "object", "type": "string" }, { "name": "BOROUGH", "rawType": "object", "type": "string" }, { "name": "LINK_NAME", "rawType": "object", "type": "string" } ], "conversionMethod": "pd.DataFrame", "ref": "ebc49528-2e7d-4a5d-9cb1-fc940f203bea", "rows": [ [ "0", "444", "0.0", "0", "-101", "19780101000000", "40.7051105,-74.01663 40.70432,-74.01667 40.7035205,-74.016561 40.70224,-74.015841 40.7016205,-74.01527 40.701401,-74.01473 40.7012804,-74.01399 40.7012,-74.01327 40.701401,-74.012031 40.7018906,-74.00995 40.70306,-74.007731 40.70481,-74.004951 40.70656,-7", "Manhattan", "West St S Battery Pl - FDR N Catherine Slip" ], [ "1", "444", "13.05", "105", "0", "20151208152435", "40.7051105,-74.01663 40.70432,-74.01667 40.7035205,-74.016561 40.70224,-74.015841 40.7016205,-74.01527 40.701401,-74.01473 40.7012804,-74.01399 40.7012,-74.01327 40.701401,-74.012031 40.7018906,-74.00995 40.70306,-74.007731 40.70481,-74.004951 40.70656,-7", "Manhattan", "West St S Battery Pl - FDR N Catherine Slip" ] ], "shape": { "columns": 8, "rows": 2 } }, "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", "
IDSPEEDTRAVEL_TIMESTATUSDATA_AS_OFLINK_POINTSBOROUGHLINK_NAME
04440.000-1011978010100000040.7051105,-74.01663 40.70432,-74.01667 40.703...ManhattanWest St S Battery Pl - FDR N Catherine Slip
144413.0510502015120815243540.7051105,-74.01663 40.70432,-74.01667 40.703...ManhattanWest St S Battery Pl - FDR N Catherine Slip
\n", "
" ], "text/plain": [ " ID SPEED TRAVEL_TIME STATUS DATA_AS_OF \\\n", "0 444 0.00 0 -101 19780101000000 \n", "1 444 13.05 105 0 20151208152435 \n", "\n", " LINK_POINTS BOROUGH \\\n", "0 40.7051105,-74.01663 40.70432,-74.01667 40.703... Manhattan \n", "1 40.7051105,-74.01663 40.70432,-74.01667 40.703... Manhattan \n", "\n", " LINK_NAME \n", "0 West St S Battery Pl - FDR N Catherine Slip \n", "1 West St S Battery Pl - FDR N Catherine Slip " ] }, "execution_count": 20, "metadata": {}, "output_type": "execute_result" } ], "source": [ "# convert the DATA_AS_OF to datetime\n", "\n", "df" ] }, { "cell_type": "code", "execution_count": 11, "metadata": {}, "outputs": [ { "data": { "text/plain": [ "{'378': {'borough': 'Staten Island',\n", " 'link': 'SIE E SOUTH AVENUE - RICHMOND AVENUE',\n", " 'len': 322884},\n", " '129': {'borough': 'Bronx',\n", " 'link': 'BE N STRATFORD AVENUE - CASTLE HILL AVE',\n", " 'len': 322899},\n", " '126': {'borough': 'Bronx',\n", " 'link': 'BE N Castle Hill Avenue - Griswold Ave',\n", " 'len': 322897},\n", " '295': {'borough': 'Bronx',\n", " 'link': 'HRP N LAFAYETTE AVENUE - E TREMONT AVENUE',\n", " 'len': 322895},\n", " '159': {'borough': 'Bronx',\n", " 'link': 'BRP N WATSON AVENUE - FORDHAM ROAD',\n", " 'len': 322911},\n", " '338': {'borough': 'Bronx',\n", " 'link': 'MDE N RFK Bridge - 142nd St',\n", " 'len': 322890},\n", " '427': {'borough': 'Queens',\n", " 'link': 'VWE S MP6.39 (Exit 11 Jewel Ave) - MP4.63 (Exit 6 Jamaica Ave)',\n", " 'len': 322867},\n", " '381': {'borough': 'Staten Island',\n", " 'link': 'SIE E WOOLEY AVENUE - BRADLEY AVENUE',\n", " 'len': 322882},\n", " '350': {'borough': 'Staten Island',\n", " 'link': 'MLK S - SIE E WALKER STREET - WOOLEY AVENUE',\n", " 'len': 322889},\n", " '154': {'borough': 'Brooklyn',\n", " 'link': 'BQE S - GOW S ALTANTIC AVENUE - 9TH STREET',\n", " 'len': 322901},\n", " '435': {'borough': 'Staten Island',\n", " 'link': 'WSE N-SIE E SOUTH AVENUE - SOUTH AVENUE',\n", " 'len': 322863},\n", " '384': {'borough': 'Staten Island',\n", " 'link': 'SIE W - WSE S SOUTH AVENUE - SOUTH AVENUE',\n", " 'len': 322883},\n", " '439': {'borough': 'Staten Island',\n", " 'link': 'WSE S SOUTH AVENUE - VICTORY BOULEVARD',\n", " 'len': 322861},\n", " '385': {'borough': 'Staten Island',\n", " 'link': 'SIE W BRADLEY AVENUE - WOOLEY AVENUE',\n", " 'len': 322882},\n", " '390': {'borough': 'Staten Island',\n", " 'link': 'SIE W WOOLEY AVENUE - RICHMOND AVENUE',\n", " 'len': 322875},\n", " '351': {'borough': 'Staten Island',\n", " 'link': 'MLK S - SIE W WALKER STREET - RICHMOND AVENUE',\n", " 'len': 322890},\n", " '388': {'borough': 'Staten Island',\n", " 'link': 'SIE W RICHMOND AVENUE - SOUTH AVENUE',\n", " 'len': 322883},\n", " '434': {'borough': 'Staten Island',\n", " 'link': 'WSE N VICTORY BLVD - SOUTH AVENUE',\n", " 'len': 322864},\n", " '382': {'borough': 'Staten Island',\n", " 'link': 'SIE E-MLK N RICHMOND AVENUE - WALKER STREET',\n", " 'len': 322883},\n", " '383': {'borough': 'Staten Island',\n", " 'link': 'SIE W - MLK N WOOLEY AVENUE - WLAKER STREET',\n", " 'len': 322880},\n", " '258': {'borough': 'Brooklyn',\n", " 'link': 'GOW N 92ND STREET - 7TH AVENUE',\n", " 'len': 322897},\n", " '259': {'borough': 'Brooklyn',\n", " 'link': 'GOW N 9TH STREET - ATLANTIC AVENUE',\n", " 'len': 322888},\n", " '261': {'borough': 'Brooklyn',\n", " 'link': 'GOW S 7TH AVENUE - 92ND STREET',\n", " 'len': 322898},\n", " '137': {'borough': 'Bronx',\n", " 'link': 'BE S CASTLE HILL AVENUE - STRATFORD AVENUE',\n", " 'len': 322898},\n", " '399': {'borough': 'Manhattan',\n", " 'link': 'TBB W - FDR S MANHATTAN TRUSS - E116TH STREET',\n", " 'len': 319530},\n", " '426': {'borough': 'Queens',\n", " 'link': 'VWE S MP4.63 (Exit 6 Jamaica Ave) - MP2.66 (Exit 2 Roackaway Blvd)',\n", " 'len': 322866},\n", " '369': {'borough': 'Staten Island',\n", " 'link': 'ROUTE 169 S - MLK WALKER STREET',\n", " 'len': 321735},\n", " '315': {'borough': 'Queens',\n", " 'link': 'LIE W 108TH ST - 84TH ST',\n", " 'len': 322886},\n", " '171': {'borough': 'Queens',\n", " 'link': 'Belt Pkwy W JFK Expressway - VWE N Jamaica Ave',\n", " 'len': 322910},\n", " '142': {'borough': 'Bronx',\n", " 'link': 'BE S Griswold - Castle Hill Avenue',\n", " 'len': 322898},\n", " '170': {'borough': 'Queens',\n", " 'link': 'Belt Pkwy W 182nd St - JFK Expressway',\n", " 'len': 322912},\n", " '425': {'borough': 'Queens',\n", " 'link': 'VWE S MP2.66 (Exit 2 Rockaway Blvd) - Belt Pkwy E 182nd St',\n", " 'len': 322872},\n", " '145': {'borough': 'Manhattan',\n", " 'link': 'BKN Bridge Manhattan Side - FDR N Catherine Slip',\n", " 'len': 322918},\n", " '150': {'borough': 'Manhattan',\n", " 'link': 'BQE N Atlantic Ave - MAN Bridge Manhattan Side',\n", " 'len': 317848},\n", " '4': {'borough': 'Manhattan',\n", " 'link': '12th Ave N 40th - 57th St',\n", " 'len': 322884},\n", " '1': {'borough': 'Manhattan',\n", " 'link': '11th ave n ganservoort - 12th ave @ 40th st',\n", " 'len': 322923},\n", " '215': {'borough': 'Manhattan',\n", " 'link': 'FDR N 25th - 63rd St',\n", " 'len': 322908},\n", " '217': {'borough': 'Manhattan',\n", " 'link': 'FDR N Catherine Slip - 25th St',\n", " 'len': 322907},\n", " '165': {'borough': 'Bronx',\n", " 'link': 'BWB N Toll Plaza - HRP N Lafayatte Ave',\n", " 'len': 321809},\n", " '422': {'borough': 'Queens',\n", " 'link': 'VWE N MP4.63 (Exit 6 - Jamaica Ave) - MP6.39 (Exit 11 Jewel Ave)',\n", " 'len': 322871},\n", " '377': {'borough': 'Staten Island',\n", " 'link': 'SIE E RICHMOND AVENUE - WOOLEY AVENUE',\n", " 'len': 322889},\n", " '325': {'borough': 'Manhattan',\n", " 'link': 'LINCOLN TUNNEL E SOUTH TUBE - NJ - NY',\n", " 'len': 321917},\n", " '329': {'borough': 'Manhattan',\n", " 'link': 'LINCOLN TUNNEL W CENTER TUBE NY - NJ',\n", " 'len': 321919},\n", " '265': {'borough': 'Manhattan',\n", " 'link': 'GWB E LOWER LEVEL PLAZA - CBE E LOWER LEVEL AMSTERDAM AVE',\n", " 'len': 321909},\n", " '324': {'borough': 'Manhattan',\n", " 'link': 'LINCOLN TUNNEL E CENTER TUBE NJ - NY',\n", " 'len': 321919},\n", " '311': {'borough': 'Queens',\n", " 'link': 'LIE E 84TH ST - 108TH ST',\n", " 'len': 322354},\n", " '119': {'borough': 'Manhattan',\n", " 'link': 'BBT E Manhattan Portal - Toll Plaza',\n", " 'len': 322016},\n", " '298': {'borough': 'Bronx',\n", " 'link': 'HRP S Lafayette Ave - BWB S Toll Plaza',\n", " 'len': 321991},\n", " '364': {'borough': 'Manhattan',\n", " 'link': 'QMT E Manhattan Side - Toll Plaza',\n", " 'len': 321989},\n", " '211': {'borough': 'Queens',\n", " 'link': 'CVE NB GCP - WILLETS PT BLVD',\n", " 'len': 322372},\n", " '318': {'borough': 'Queens',\n", " 'link': 'LIE WB LITTLE NECK PKWY - NB CIP',\n", " 'len': 322365},\n", " '124': {'borough': 'Manhattan',\n", " 'link': 'BBT W Toll Plaza - Manhattan Portal',\n", " 'len': 317681},\n", " '365': {'borough': 'Queens',\n", " 'link': 'QMT W Toll Plaza - Manhattan Side',\n", " 'len': 321990},\n", " '213': {'borough': 'Manhattan',\n", " 'link': 'FDR N - TBB E 116TH STREET - MANHATTAN TRUSS',\n", " 'len': 322001},\n", " '212': {'borough': 'Queens',\n", " 'link': 'CVE NB LIE - WILLETS PT BLVD',\n", " 'len': 322369},\n", " '405': {'borough': 'Queens',\n", " 'link': 'TNB S Qns Anchorage - CIP S @ TNB',\n", " 'len': 322325},\n", " '319': {'borough': 'Queens',\n", " 'link': 'LIE WB LITTLE NECK PKWY - NB CVE',\n", " 'len': 322362},\n", " '441': {'borough': 'Staten Island',\n", " 'link': 'WSE S VICTORY BOULEVARD - ARDEN AVENUE',\n", " 'len': 322852},\n", " '345': {'borough': 'Bronx',\n", " 'link': 'MDE S HARLEM RIVER PARK - GWB W AMSTERDAM AVENUE UPPER LEVEL',\n", " 'len': 321909},\n", " '186': {'borough': 'Bronx',\n", " 'link': 'CBE W L/LE V AMSTERDAM AVE - I 95 S LOC LNS',\n", " 'len': 321916},\n", " '344': {'borough': 'Bronx',\n", " 'link': 'MDE S HARLEM RIVER PARK - GWB W AMSTERDAM AVENUE LOWER LEVEL',\n", " 'len': 321908},\n", " '191': {'borough': 'Bronx',\n", " 'link': 'CBE W MORRIS AVE - GWB W AMSTERDAM AVE (U/LVL)',\n", " 'len': 319864},\n", " '190': {'borough': 'Bronx',\n", " 'link': 'CBE W MORRIS AVE - GWB W AMSTERDAM AVE (L/LVL)',\n", " 'len': 321922},\n", " '448': {'borough': 'Manhattan',\n", " 'link': 'Westside Hwy N 57th St - GWB',\n", " 'len': 321874},\n", " '417': {'borough': 'Brooklyn',\n", " 'link': 'VNB W BROOKLYN GANTRY UPPER LEVEL - SI GANTRY UPPER LEVEL',\n", " 'len': 278893},\n", " '195': {'borough': 'Bronx',\n", " 'link': 'CBE W U/LEV AMSTERDAM AVE - I95 S EXP LNS',\n", " 'len': 321922},\n", " '411': {'borough': 'Brooklyn',\n", " 'link': 'VNB E SI GANTRY UPPER LEVEL - BROOKLYN GANTRY UPPER LEVEL',\n", " 'len': 278894},\n", " '207': {'borough': 'Queens',\n", " 'link': 'CIP S Hempstead Tpk - Laurelton Pkwy @ SSP',\n", " 'len': 322892},\n", " '331': {'borough': 'Queens',\n", " 'link': 'Laurelton Pkwy N @ SSP - CIP N Hempstead Tpk',\n", " 'len': 322884},\n", " '332': {'borough': 'Queens',\n", " 'link': 'Laurelton Pkwy S @ SSP - Belt Pkwy W 182nd St',\n", " 'len': 322884},\n", " '169': {'borough': 'Queens',\n", " 'link': 'Belt Pkwy E 182nd St - Laurelton Pkwy N @ SSP',\n", " 'len': 322909},\n", " '199': {'borough': 'Queens',\n", " 'link': 'CIP N Hempstead Tpk - LIE',\n", " 'len': 322896},\n", " '208': {'borough': 'Queens',\n", " 'link': 'CIP S LIE - Hempstead Tpk',\n", " 'len': 322895},\n", " '450': {'borough': 'Manhattan',\n", " 'link': 'Westside Hwy S GWB - 57th St',\n", " 'len': 322780},\n", " '223': {'borough': 'Manhattan',\n", " 'link': 'FDR S Catherine Slip - BKN Bridge Manhattan Side',\n", " 'len': 322897},\n", " '149': {'borough': 'Manhattan',\n", " 'link': 'BQE N Atlantic Ave - BKN Bridge Manhattan Side',\n", " 'len': 322901},\n", " '221': {'borough': 'Manhattan',\n", " 'link': 'FDR S 25th St - Catherine Slip',\n", " 'len': 322897},\n", " '222': {'borough': 'Manhattan',\n", " 'link': 'FDR S 63rd - 25th St',\n", " 'len': 322899},\n", " '2': {'borough': 'Manhattan',\n", " 'link': '11th ave s ganservoort - west st @ spring st',\n", " 'len': 322913},\n", " '3': {'borough': 'Manhattan',\n", " 'link': '12th ave @ 45th - 11 ave ganservoort st',\n", " 'len': 322891},\n", " '106': {'borough': 'Manhattan',\n", " 'link': '12th Ave S 57th St - 45th St',\n", " 'len': 322910},\n", " '204': {'borough': 'Queens',\n", " 'link': 'CIP N TNB - Whitestone Expwy S Exit 14 (Linden Pl)',\n", " 'len': 322895},\n", " '167': {'borough': 'Queens',\n", " 'link': 'BWB S Queens Anchorage - WSE S Exit 14 (Linden Pl)',\n", " 'len': 321010},\n", " '172': {'borough': 'Bronx',\n", " 'link': 'CBE AMSTERDAM AVE (L/LVL) - MORRIS AVE',\n", " 'len': 322901},\n", " '177': {'borough': 'Bronx',\n", " 'link': 'CBE E AMSTERDAM AVE(U/LVL) - MORRIS AVE',\n", " 'len': 322903},\n", " '424': {'borough': 'Queens',\n", " 'link': 'VWE N MP8.64 (Exit 13 Northern Blvd) - Whitestone Expwy Exit 14 (Linden Pl)',\n", " 'len': 322863},\n", " '423': {'borough': 'Queens',\n", " 'link': 'VWE N MP6.39 (Exit 11 Jewel Ave) - MP8.65 (Exit 13 Northern Blvd)',\n", " 'len': 322859},\n", " '178': {'borough': 'Bronx',\n", " 'link': 'CBE E CASTLE HILL AVE - BE N WATERBURY AVE',\n", " 'len': 322898},\n", " '157': {'borough': 'Brooklyn',\n", " 'link': 'BQE S LEONARD STREET - ATLANTIC AVENUE',\n", " 'len': 303601},\n", " '185': {'borough': 'Bronx',\n", " 'link': 'CBE W CASTLE HILL AVENUE - TAYLOR AVENUE',\n", " 'len': 322899},\n", " '160': {'borough': 'Bronx',\n", " 'link': 'BRP S FORDHAM ROAD - WATSON AVENUE',\n", " 'len': 322905},\n", " '148': {'borough': 'Brooklyn',\n", " 'link': 'BQE N ATLANTIC AVENUE - LEONARD STREET',\n", " 'len': 322904},\n", " '184': {'borough': 'Bronx',\n", " 'link': 'CBE E TAYLOR AVENUE - CASTLE HILL AVENUE',\n", " 'len': 318446},\n", " '428': {'borough': 'Queens',\n", " 'link': 'VWE S MP8.65 (Exit 13 Northern Blvd) - MP6.39 (Exit 11 Jewel Ave)',\n", " 'len': 322858},\n", " '453': {'borough': 'Queens',\n", " 'link': 'Whitestone Expwy S Exit 14 (Linden Pl) - VWE S MP8.65 (Exit 13 Northern Blvd)',\n", " 'len': 322828},\n", " '354': {'borough': 'Bronx',\n", " 'link': 'I-87 NYST S Exit 1 - MDE S Van Cortlandt Park',\n", " 'len': 322878},\n", " '394': {'borough': 'Queens',\n", " 'link': 'TBB N QUEENS ANCHORAGE - BE N',\n", " 'len': 321958},\n", " '433': {'borough': 'Staten Island',\n", " 'link': 'WSE N TYRELLAN AVENUE - BLOOMINGDALE ROAD',\n", " 'len': 322852},\n", " '431': {'borough': 'Staten Island',\n", " 'link': 'WSE N BLOOMUINGDALE ROAD - ARDEN AVENUE',\n", " 'len': 322858},\n", " '430': {'borough': 'Staten Island',\n", " 'link': 'WSE N ARDEN AVENUE - VICTORY BLVD',\n", " 'len': 322859},\n", " '387': {'borough': 'Staten Island',\n", " 'link': 'SIE W FINGERBOARD ROAD - CLOVE ROAD',\n", " 'len': 322872},\n", " '437': {'borough': 'Staten Island',\n", " 'link': 'WSE S BLLOMINGDALE ROAD - TYRELLAN AVENUE',\n", " 'len': 322854},\n", " '375': {'borough': 'Staten Island',\n", " 'link': 'SIE E BRADLEY AVENUE - CLOVE ROAD',\n", " 'len': 322879},\n", " '376': {'borough': 'Staten Island',\n", " 'link': 'SIE E CLOVE ROAD - FINGERBOARD ROAD',\n", " 'len': 322878},\n", " '406': {'borough': 'Queens',\n", " 'link': 'TNB S Toll Plaza - Queens Anchorage',\n", " 'len': 321972},\n", " '402': {'borough': 'Queens',\n", " 'link': 'TNB N Queens Anchorage - Toll Plaza',\n", " 'len': 321977},\n", " '451': {'borough': 'Queens',\n", " 'link': 'Whitestone Expwy N Exit 14 (Linden Pl) - BWB N Queens Anchorage',\n", " 'len': 321938},\n", " '164': {'borough': 'Queens',\n", " 'link': 'BWB N Queens Anchorage - Toll Plaza',\n", " 'len': 322011},\n", " '168': {'borough': 'Bronx',\n", " 'link': 'BWB S Toll Plaza - Queens Anchorage',\n", " 'len': 322010},\n", " '202': {'borough': 'Queens',\n", " 'link': 'CIP N ramp to TNB - TNB Queens Anchorage',\n", " 'len': 321999},\n", " '398': {'borough': 'Queens',\n", " 'link': 'TBB S MANHATTAN LIFT SPAN - QUEENS ANCHORAGE',\n", " 'len': 321978},\n", " '140': {'borough': 'Queens',\n", " 'link': 'BE S TBB EXIT RAMP - MANHATTAN LIFT SPAN',\n", " 'len': 322002},\n", " '141': {'borough': 'Queens',\n", " 'link': 'BE S TBB EXIT RAMP - QUEENS ANCHORAGE',\n", " 'len': 322000},\n", " '347': {'borough': 'Queens',\n", " 'link': 'MDE S TBB EXIT RAMP - QUEENS ANCHORAGE',\n", " 'len': 321981},\n", " '395': {'borough': 'Queens',\n", " 'link': 'TBB N QUEENS ANCHORAGE - MANHATTAN LIFT SPAN',\n", " 'len': 321978},\n", " '330': {'borough': 'Manhattan',\n", " 'link': 'LINCOLN TUNNEL W NORTH TUBE NY - NJ',\n", " 'len': 321918},\n", " '349': {'borough': 'Staten Island',\n", " 'link': 'MLK N WALKER STREET - NJ ROUTE 169',\n", " 'len': 321907},\n", " '436': {'borough': 'Staten Island',\n", " 'link': 'WSE S ARDEN AVENUE - BLOOMINGDALE ROAD',\n", " 'len': 322852},\n", " '264': {'borough': 'Brooklyn',\n", " 'link': 'GOW S VNB W 92ND STREET - BKLYN GANTRY UPPER LEVEL',\n", " 'len': 173235},\n", " '263': {'borough': 'Brooklyn',\n", " 'link': 'GOW S VNB W 92ND STREET - BKLYN GANTRY LOWER LEVEL',\n", " 'len': 173235},\n", " '339': {'borough': 'Bronx',\n", " 'link': 'MDE N VAN CORTLAND PARK - NYST N EXIT 1 (MP.48)',\n", " 'len': 52636},\n", " '445': {'borough': 'Manhattan',\n", " 'link': 'West St S Spring St - BBT Manhattan Portal outbound',\n", " 'len': 304827},\n", " '257': {'borough': 'Brooklyn',\n", " 'link': 'GOW N 7TH AVENUE - 9TH STREET',\n", " 'len': 105550},\n", " '153': {'borough': 'Brooklyn',\n", " 'link': 'BQE N LEONARD STREET - 46TH STREET',\n", " 'len': 238449},\n", " '155': {'borough': 'Brooklyn',\n", " 'link': 'BQE S 46TH STREET - LEONARD STREET',\n", " 'len': 238447},\n", " '110': {'borough': 'Staten Island',\n", " 'link': '440 N FRANCIS STREET - WSE N TYRELLAN AVE',\n", " 'len': 129201},\n", " '440': {'borough': 'Staten Island',\n", " 'link': 'WSE S TYRELLAN AVENUE - 440 S FRANCIS STREET',\n", " 'len': 128660},\n", " '206': {'borough': 'Queens', 'link': 'CIP N LIE ramp - TNB', 'len': 162815},\n", " '205': {'borough': 'Queens', 'link': 'CIP NB GCP - TNB', 'len': 151638},\n", " '262': {'borough': 'Brooklyn',\n", " 'link': 'GOW S 9TH STREET - 7TH AVENUE',\n", " 'len': 79441},\n", " '418': {'borough': 'Staten Island',\n", " 'link': 'VNB W-SIE W SI GANTRY LOWER LEVEL - FINGERBOARD ROAD',\n", " 'len': 15499},\n", " '412': {'borough': 'Brooklyn',\n", " 'link': 'VNB E-GOWANUS N BROOKLYN GANTRY LOWER LEVEL - 92ND STREET',\n", " 'len': 15499},\n", " '419': {'borough': 'Staten island',\n", " 'link': 'VNB W-SIE W SI GANTRY UPPER LEVEL - FINGERBOARD ROAD',\n", " 'len': 15499},\n", " '413': {'borough': 'Brooklyn',\n", " 'link': 'VNB E-GOWANUS N BROOKLYN GANTRY UPPER LEVEL - 92ND STREET',\n", " 'len': 15499},\n", " '379': {'borough': 'Staten Island',\n", " 'link': 'SIE E VNB E FINGERBOARD ROAD - SI GANTRY LOWER LEVEL',\n", " 'len': 15493},\n", " '410': {'borough': 'Brooklyn',\n", " 'link': 'VNB E SI GANTRY LOWER LEVEL - BROOLKYN GANTRY LOWER LEVEL',\n", " 'len': 15493},\n", " '416': {'borough': 'Brooklyn',\n", " 'link': 'VNB W BROOKLYN GANTRY LOWER LEVEL - SI GANTRY LOWER LEVEL',\n", " 'len': 15494},\n", " '380': {'borough': 'Staten Island',\n", " 'link': 'SIE E VNB E FINGERBOARD ROAD - SI GANTRY UPPER LEVEL',\n", " 'len': 15493}}" ] }, "execution_count": 11, "metadata": {}, "output_type": "execute_result" } ], "source": [ "id_info" ] }, { "cell_type": "code", "execution_count": 12, "metadata": {}, "outputs": [ { "data": { "text/plain": [ "{'1': {'borough': 'Manhattan',\n", " 'link': '11th ave n ganservoort - 12th ave @ 40th st',\n", " 'len': 322923},\n", " '145': {'borough': 'Manhattan',\n", " 'link': 'BKN Bridge Manhattan Side - FDR N Catherine Slip',\n", " 'len': 322918},\n", " '2': {'borough': 'Manhattan',\n", " 'link': '11th ave s ganservoort - west st @ spring st',\n", " 'len': 322913},\n", " '170': {'borough': 'Queens',\n", " 'link': 'Belt Pkwy W 182nd St - JFK Expressway',\n", " 'len': 322912},\n", " '159': {'borough': 'Bronx',\n", " 'link': 'BRP N WATSON AVENUE - FORDHAM ROAD',\n", " 'len': 322911},\n", " '171': {'borough': 'Queens',\n", " 'link': 'Belt Pkwy W JFK Expressway - VWE N Jamaica Ave',\n", " 'len': 322910},\n", " '106': {'borough': 'Manhattan',\n", " 'link': '12th Ave S 57th St - 45th St',\n", " 'len': 322910},\n", " '169': {'borough': 'Queens',\n", " 'link': 'Belt Pkwy E 182nd St - Laurelton Pkwy N @ SSP',\n", " 'len': 322909},\n", " '215': {'borough': 'Manhattan',\n", " 'link': 'FDR N 25th - 63rd St',\n", " 'len': 322908},\n", " '217': {'borough': 'Manhattan',\n", " 'link': 'FDR N Catherine Slip - 25th St',\n", " 'len': 322907},\n", " '160': {'borough': 'Bronx',\n", " 'link': 'BRP S FORDHAM ROAD - WATSON AVENUE',\n", " 'len': 322905},\n", " '148': {'borough': 'Brooklyn',\n", " 'link': 'BQE N ATLANTIC AVENUE - LEONARD STREET',\n", " 'len': 322904},\n", " '177': {'borough': 'Bronx',\n", " 'link': 'CBE E AMSTERDAM AVE(U/LVL) - MORRIS AVE',\n", " 'len': 322903},\n", " '154': {'borough': 'Brooklyn',\n", " 'link': 'BQE S - GOW S ALTANTIC AVENUE - 9TH STREET',\n", " 'len': 322901},\n", " '149': {'borough': 'Manhattan',\n", " 'link': 'BQE N Atlantic Ave - BKN Bridge Manhattan Side',\n", " 'len': 322901},\n", " '172': {'borough': 'Bronx',\n", " 'link': 'CBE AMSTERDAM AVE (L/LVL) - MORRIS AVE',\n", " 'len': 322901},\n", " '129': {'borough': 'Bronx',\n", " 'link': 'BE N STRATFORD AVENUE - CASTLE HILL AVE',\n", " 'len': 322899},\n", " '222': {'borough': 'Manhattan',\n", " 'link': 'FDR S 63rd - 25th St',\n", " 'len': 322899},\n", " '185': {'borough': 'Bronx',\n", " 'link': 'CBE W CASTLE HILL AVENUE - TAYLOR AVENUE',\n", " 'len': 322899},\n", " '261': {'borough': 'Brooklyn',\n", " 'link': 'GOW S 7TH AVENUE - 92ND STREET',\n", " 'len': 322898},\n", " '137': {'borough': 'Bronx',\n", " 'link': 'BE S CASTLE HILL AVENUE - STRATFORD AVENUE',\n", " 'len': 322898},\n", " '142': {'borough': 'Bronx',\n", " 'link': 'BE S Griswold - Castle Hill Avenue',\n", " 'len': 322898},\n", " '178': {'borough': 'Bronx',\n", " 'link': 'CBE E CASTLE HILL AVE - BE N WATERBURY AVE',\n", " 'len': 322898},\n", " '126': {'borough': 'Bronx',\n", " 'link': 'BE N Castle Hill Avenue - Griswold Ave',\n", " 'len': 322897},\n", " '258': {'borough': 'Brooklyn',\n", " 'link': 'GOW N 92ND STREET - 7TH AVENUE',\n", " 'len': 322897},\n", " '223': {'borough': 'Manhattan',\n", " 'link': 'FDR S Catherine Slip - BKN Bridge Manhattan Side',\n", " 'len': 322897},\n", " '221': {'borough': 'Manhattan',\n", " 'link': 'FDR S 25th St - Catherine Slip',\n", " 'len': 322897},\n", " '199': {'borough': 'Queens',\n", " 'link': 'CIP N Hempstead Tpk - LIE',\n", " 'len': 322896},\n", " '295': {'borough': 'Bronx',\n", " 'link': 'HRP N LAFAYETTE AVENUE - E TREMONT AVENUE',\n", " 'len': 322895},\n", " '208': {'borough': 'Queens',\n", " 'link': 'CIP S LIE - Hempstead Tpk',\n", " 'len': 322895},\n", " '204': {'borough': 'Queens',\n", " 'link': 'CIP N TNB - Whitestone Expwy S Exit 14 (Linden Pl)',\n", " 'len': 322895},\n", " '207': {'borough': 'Queens',\n", " 'link': 'CIP S Hempstead Tpk - Laurelton Pkwy @ SSP',\n", " 'len': 322892},\n", " '3': {'borough': 'Manhattan',\n", " 'link': '12th ave @ 45th - 11 ave ganservoort st',\n", " 'len': 322891},\n", " '338': {'borough': 'Bronx',\n", " 'link': 'MDE N RFK Bridge - 142nd St',\n", " 'len': 322890},\n", " '351': {'borough': 'Staten Island',\n", " 'link': 'MLK S - SIE W WALKER STREET - RICHMOND AVENUE',\n", " 'len': 322890},\n", " '350': {'borough': 'Staten Island',\n", " 'link': 'MLK S - SIE E WALKER STREET - WOOLEY AVENUE',\n", " 'len': 322889},\n", " '377': {'borough': 'Staten Island',\n", " 'link': 'SIE E RICHMOND AVENUE - WOOLEY AVENUE',\n", " 'len': 322889},\n", " '259': {'borough': 'Brooklyn',\n", " 'link': 'GOW N 9TH STREET - ATLANTIC AVENUE',\n", " 'len': 322888},\n", " '315': {'borough': 'Queens',\n", " 'link': 'LIE W 108TH ST - 84TH ST',\n", " 'len': 322886},\n", " '378': {'borough': 'Staten Island',\n", " 'link': 'SIE E SOUTH AVENUE - RICHMOND AVENUE',\n", " 'len': 322884},\n", " '4': {'borough': 'Manhattan',\n", " 'link': '12th Ave N 40th - 57th St',\n", " 'len': 322884},\n", " '331': {'borough': 'Queens',\n", " 'link': 'Laurelton Pkwy N @ SSP - CIP N Hempstead Tpk',\n", " 'len': 322884},\n", " '332': {'borough': 'Queens',\n", " 'link': 'Laurelton Pkwy S @ SSP - Belt Pkwy W 182nd St',\n", " 'len': 322884},\n", " '384': {'borough': 'Staten Island',\n", " 'link': 'SIE W - WSE S SOUTH AVENUE - SOUTH AVENUE',\n", " 'len': 322883},\n", " '388': {'borough': 'Staten Island',\n", " 'link': 'SIE W RICHMOND AVENUE - SOUTH AVENUE',\n", " 'len': 322883},\n", " '382': {'borough': 'Staten Island',\n", " 'link': 'SIE E-MLK N RICHMOND AVENUE - WALKER STREET',\n", " 'len': 322883},\n", " '381': {'borough': 'Staten Island',\n", " 'link': 'SIE E WOOLEY AVENUE - BRADLEY AVENUE',\n", " 'len': 322882},\n", " '385': {'borough': 'Staten Island',\n", " 'link': 'SIE W BRADLEY AVENUE - WOOLEY AVENUE',\n", " 'len': 322882},\n", " '383': {'borough': 'Staten Island',\n", " 'link': 'SIE W - MLK N WOOLEY AVENUE - WLAKER STREET',\n", " 'len': 322880},\n", " '375': {'borough': 'Staten Island',\n", " 'link': 'SIE E BRADLEY AVENUE - CLOVE ROAD',\n", " 'len': 322879},\n", " '354': {'borough': 'Bronx',\n", " 'link': 'I-87 NYST S Exit 1 - MDE S Van Cortlandt Park',\n", " 'len': 322878},\n", " '376': {'borough': 'Staten Island',\n", " 'link': 'SIE E CLOVE ROAD - FINGERBOARD ROAD',\n", " 'len': 322878},\n", " '390': {'borough': 'Staten Island',\n", " 'link': 'SIE W WOOLEY AVENUE - RICHMOND AVENUE',\n", " 'len': 322875},\n", " '425': {'borough': 'Queens',\n", " 'link': 'VWE S MP2.66 (Exit 2 Rockaway Blvd) - Belt Pkwy E 182nd St',\n", " 'len': 322872},\n", " '387': {'borough': 'Staten Island',\n", " 'link': 'SIE W FINGERBOARD ROAD - CLOVE ROAD',\n", " 'len': 322872},\n", " '422': {'borough': 'Queens',\n", " 'link': 'VWE N MP4.63 (Exit 6 - Jamaica Ave) - MP6.39 (Exit 11 Jewel Ave)',\n", " 'len': 322871},\n", " '427': {'borough': 'Queens',\n", " 'link': 'VWE S MP6.39 (Exit 11 Jewel Ave) - MP4.63 (Exit 6 Jamaica Ave)',\n", " 'len': 322867},\n", " '426': {'borough': 'Queens',\n", " 'link': 'VWE S MP4.63 (Exit 6 Jamaica Ave) - MP2.66 (Exit 2 Roackaway Blvd)',\n", " 'len': 322866},\n", " '434': {'borough': 'Staten Island',\n", " 'link': 'WSE N VICTORY BLVD - SOUTH AVENUE',\n", " 'len': 322864},\n", " '435': {'borough': 'Staten Island',\n", " 'link': 'WSE N-SIE E SOUTH AVENUE - SOUTH AVENUE',\n", " 'len': 322863},\n", " '424': {'borough': 'Queens',\n", " 'link': 'VWE N MP8.64 (Exit 13 Northern Blvd) - Whitestone Expwy Exit 14 (Linden Pl)',\n", " 'len': 322863},\n", " '439': {'borough': 'Staten Island',\n", " 'link': 'WSE S SOUTH AVENUE - VICTORY BOULEVARD',\n", " 'len': 322861},\n", " '423': {'borough': 'Queens',\n", " 'link': 'VWE N MP6.39 (Exit 11 Jewel Ave) - MP8.65 (Exit 13 Northern Blvd)',\n", " 'len': 322859},\n", " '430': {'borough': 'Staten Island',\n", " 'link': 'WSE N ARDEN AVENUE - VICTORY BLVD',\n", " 'len': 322859},\n", " '428': {'borough': 'Queens',\n", " 'link': 'VWE S MP8.65 (Exit 13 Northern Blvd) - MP6.39 (Exit 11 Jewel Ave)',\n", " 'len': 322858},\n", " '431': {'borough': 'Staten Island',\n", " 'link': 'WSE N BLOOMUINGDALE ROAD - ARDEN AVENUE',\n", " 'len': 322858},\n", " '437': {'borough': 'Staten Island',\n", " 'link': 'WSE S BLLOMINGDALE ROAD - TYRELLAN AVENUE',\n", " 'len': 322854},\n", " '441': {'borough': 'Staten Island',\n", " 'link': 'WSE S VICTORY BOULEVARD - ARDEN AVENUE',\n", " 'len': 322852},\n", " '433': {'borough': 'Staten Island',\n", " 'link': 'WSE N TYRELLAN AVENUE - BLOOMINGDALE ROAD',\n", " 'len': 322852},\n", " '436': {'borough': 'Staten Island',\n", " 'link': 'WSE S ARDEN AVENUE - BLOOMINGDALE ROAD',\n", " 'len': 322852},\n", " '453': {'borough': 'Queens',\n", " 'link': 'Whitestone Expwy S Exit 14 (Linden Pl) - VWE S MP8.65 (Exit 13 Northern Blvd)',\n", " 'len': 322828},\n", " '450': {'borough': 'Manhattan',\n", " 'link': 'Westside Hwy S GWB - 57th St',\n", " 'len': 322780},\n", " '211': {'borough': 'Queens',\n", " 'link': 'CVE NB GCP - WILLETS PT BLVD',\n", " 'len': 322372},\n", " '212': {'borough': 'Queens',\n", " 'link': 'CVE NB LIE - WILLETS PT BLVD',\n", " 'len': 322369},\n", " '318': {'borough': 'Queens',\n", " 'link': 'LIE WB LITTLE NECK PKWY - NB CIP',\n", " 'len': 322365},\n", " '319': {'borough': 'Queens',\n", " 'link': 'LIE WB LITTLE NECK PKWY - NB CVE',\n", " 'len': 322362},\n", " '311': {'borough': 'Queens',\n", " 'link': 'LIE E 84TH ST - 108TH ST',\n", " 'len': 322354},\n", " '405': {'borough': 'Queens',\n", " 'link': 'TNB S Qns Anchorage - CIP S @ TNB',\n", " 'len': 322325},\n", " '119': {'borough': 'Manhattan',\n", " 'link': 'BBT E Manhattan Portal - Toll Plaza',\n", " 'len': 322016},\n", " '164': {'borough': 'Queens',\n", " 'link': 'BWB N Queens Anchorage - Toll Plaza',\n", " 'len': 322011},\n", " '168': {'borough': 'Bronx',\n", " 'link': 'BWB S Toll Plaza - Queens Anchorage',\n", " 'len': 322010},\n", " '140': {'borough': 'Queens',\n", " 'link': 'BE S TBB EXIT RAMP - MANHATTAN LIFT SPAN',\n", " 'len': 322002},\n", " '213': {'borough': 'Manhattan',\n", " 'link': 'FDR N - TBB E 116TH STREET - MANHATTAN TRUSS',\n", " 'len': 322001},\n", " '141': {'borough': 'Queens',\n", " 'link': 'BE S TBB EXIT RAMP - QUEENS ANCHORAGE',\n", " 'len': 322000},\n", " '202': {'borough': 'Queens',\n", " 'link': 'CIP N ramp to TNB - TNB Queens Anchorage',\n", " 'len': 321999},\n", " '298': {'borough': 'Bronx',\n", " 'link': 'HRP S Lafayette Ave - BWB S Toll Plaza',\n", " 'len': 321991},\n", " '365': {'borough': 'Queens',\n", " 'link': 'QMT W Toll Plaza - Manhattan Side',\n", " 'len': 321990},\n", " '364': {'borough': 'Manhattan',\n", " 'link': 'QMT E Manhattan Side - Toll Plaza',\n", " 'len': 321989},\n", " '347': {'borough': 'Queens',\n", " 'link': 'MDE S TBB EXIT RAMP - QUEENS ANCHORAGE',\n", " 'len': 321981},\n", " '398': {'borough': 'Queens',\n", " 'link': 'TBB S MANHATTAN LIFT SPAN - QUEENS ANCHORAGE',\n", " 'len': 321978},\n", " '395': {'borough': 'Queens',\n", " 'link': 'TBB N QUEENS ANCHORAGE - MANHATTAN LIFT SPAN',\n", " 'len': 321978},\n", " '402': {'borough': 'Queens',\n", " 'link': 'TNB N Queens Anchorage - Toll Plaza',\n", " 'len': 321977},\n", " '406': {'borough': 'Queens',\n", " 'link': 'TNB S Toll Plaza - Queens Anchorage',\n", " 'len': 321972},\n", " '394': {'borough': 'Queens',\n", " 'link': 'TBB N QUEENS ANCHORAGE - BE N',\n", " 'len': 321958},\n", " '451': {'borough': 'Queens',\n", " 'link': 'Whitestone Expwy N Exit 14 (Linden Pl) - BWB N Queens Anchorage',\n", " 'len': 321938},\n", " '190': {'borough': 'Bronx',\n", " 'link': 'CBE W MORRIS AVE - GWB W AMSTERDAM AVE (L/LVL)',\n", " 'len': 321922},\n", " '195': {'borough': 'Bronx',\n", " 'link': 'CBE W U/LEV AMSTERDAM AVE - I95 S EXP LNS',\n", " 'len': 321922},\n", " '329': {'borough': 'Manhattan',\n", " 'link': 'LINCOLN TUNNEL W CENTER TUBE NY - NJ',\n", " 'len': 321919},\n", " '324': {'borough': 'Manhattan',\n", " 'link': 'LINCOLN TUNNEL E CENTER TUBE NJ - NY',\n", " 'len': 321919},\n", " '330': {'borough': 'Manhattan',\n", " 'link': 'LINCOLN TUNNEL W NORTH TUBE NY - NJ',\n", " 'len': 321918},\n", " '325': {'borough': 'Manhattan',\n", " 'link': 'LINCOLN TUNNEL E SOUTH TUBE - NJ - NY',\n", " 'len': 321917},\n", " '186': {'borough': 'Bronx',\n", " 'link': 'CBE W L/LE V AMSTERDAM AVE - I 95 S LOC LNS',\n", " 'len': 321916},\n", " '265': {'borough': 'Manhattan',\n", " 'link': 'GWB E LOWER LEVEL PLAZA - CBE E LOWER LEVEL AMSTERDAM AVE',\n", " 'len': 321909},\n", " '345': {'borough': 'Bronx',\n", " 'link': 'MDE S HARLEM RIVER PARK - GWB W AMSTERDAM AVENUE UPPER LEVEL',\n", " 'len': 321909},\n", " '344': {'borough': 'Bronx',\n", " 'link': 'MDE S HARLEM RIVER PARK - GWB W AMSTERDAM AVENUE LOWER LEVEL',\n", " 'len': 321908},\n", " '349': {'borough': 'Staten Island',\n", " 'link': 'MLK N WALKER STREET - NJ ROUTE 169',\n", " 'len': 321907},\n", " '448': {'borough': 'Manhattan',\n", " 'link': 'Westside Hwy N 57th St - GWB',\n", " 'len': 321874},\n", " '165': {'borough': 'Bronx',\n", " 'link': 'BWB N Toll Plaza - HRP N Lafayatte Ave',\n", " 'len': 321809},\n", " '369': {'borough': 'Staten Island',\n", " 'link': 'ROUTE 169 S - MLK WALKER STREET',\n", " 'len': 321735},\n", " '167': {'borough': 'Queens',\n", " 'link': 'BWB S Queens Anchorage - WSE S Exit 14 (Linden Pl)',\n", " 'len': 321010},\n", " '191': {'borough': 'Bronx',\n", " 'link': 'CBE W MORRIS AVE - GWB W AMSTERDAM AVE (U/LVL)',\n", " 'len': 319864},\n", " '399': {'borough': 'Manhattan',\n", " 'link': 'TBB W - FDR S MANHATTAN TRUSS - E116TH STREET',\n", " 'len': 319530},\n", " '184': {'borough': 'Bronx',\n", " 'link': 'CBE E TAYLOR AVENUE - CASTLE HILL AVENUE',\n", " 'len': 318446},\n", " '150': {'borough': 'Manhattan',\n", " 'link': 'BQE N Atlantic Ave - MAN Bridge Manhattan Side',\n", " 'len': 317848},\n", " '124': {'borough': 'Manhattan',\n", " 'link': 'BBT W Toll Plaza - Manhattan Portal',\n", " 'len': 317681},\n", " '445': {'borough': 'Manhattan',\n", " 'link': 'West St S Spring St - BBT Manhattan Portal outbound',\n", " 'len': 304827},\n", " '157': {'borough': 'Brooklyn',\n", " 'link': 'BQE S LEONARD STREET - ATLANTIC AVENUE',\n", " 'len': 303601},\n", " '411': {'borough': 'Brooklyn',\n", " 'link': 'VNB E SI GANTRY UPPER LEVEL - BROOKLYN GANTRY UPPER LEVEL',\n", " 'len': 278894},\n", " '417': {'borough': 'Brooklyn',\n", " 'link': 'VNB W BROOKLYN GANTRY UPPER LEVEL - SI GANTRY UPPER LEVEL',\n", " 'len': 278893},\n", " '153': {'borough': 'Brooklyn',\n", " 'link': 'BQE N LEONARD STREET - 46TH STREET',\n", " 'len': 238449},\n", " '155': {'borough': 'Brooklyn',\n", " 'link': 'BQE S 46TH STREET - LEONARD STREET',\n", " 'len': 238447},\n", " '264': {'borough': 'Brooklyn',\n", " 'link': 'GOW S VNB W 92ND STREET - BKLYN GANTRY UPPER LEVEL',\n", " 'len': 173235},\n", " '263': {'borough': 'Brooklyn',\n", " 'link': 'GOW S VNB W 92ND STREET - BKLYN GANTRY LOWER LEVEL',\n", " 'len': 173235},\n", " '206': {'borough': 'Queens', 'link': 'CIP N LIE ramp - TNB', 'len': 162815},\n", " '205': {'borough': 'Queens', 'link': 'CIP NB GCP - TNB', 'len': 151638},\n", " '110': {'borough': 'Staten Island',\n", " 'link': '440 N FRANCIS STREET - WSE N TYRELLAN AVE',\n", " 'len': 129201},\n", " '440': {'borough': 'Staten Island',\n", " 'link': 'WSE S TYRELLAN AVENUE - 440 S FRANCIS STREET',\n", " 'len': 128660},\n", " '257': {'borough': 'Brooklyn',\n", " 'link': 'GOW N 7TH AVENUE - 9TH STREET',\n", " 'len': 105550},\n", " '262': {'borough': 'Brooklyn',\n", " 'link': 'GOW S 9TH STREET - 7TH AVENUE',\n", " 'len': 79441},\n", " '339': {'borough': 'Bronx',\n", " 'link': 'MDE N VAN CORTLAND PARK - NYST N EXIT 1 (MP.48)',\n", " 'len': 52636},\n", " '418': {'borough': 'Staten Island',\n", " 'link': 'VNB W-SIE W SI GANTRY LOWER LEVEL - FINGERBOARD ROAD',\n", " 'len': 15499},\n", " '412': {'borough': 'Brooklyn',\n", " 'link': 'VNB E-GOWANUS N BROOKLYN GANTRY LOWER LEVEL - 92ND STREET',\n", " 'len': 15499},\n", " '419': {'borough': 'Staten island',\n", " 'link': 'VNB W-SIE W SI GANTRY UPPER LEVEL - FINGERBOARD ROAD',\n", " 'len': 15499},\n", " '413': {'borough': 'Brooklyn',\n", " 'link': 'VNB E-GOWANUS N BROOKLYN GANTRY UPPER LEVEL - 92ND STREET',\n", " 'len': 15499},\n", " '416': {'borough': 'Brooklyn',\n", " 'link': 'VNB W BROOKLYN GANTRY LOWER LEVEL - SI GANTRY LOWER LEVEL',\n", " 'len': 15494},\n", " '379': {'borough': 'Staten Island',\n", " 'link': 'SIE E VNB E FINGERBOARD ROAD - SI GANTRY LOWER LEVEL',\n", " 'len': 15493},\n", " '410': {'borough': 'Brooklyn',\n", " 'link': 'VNB E SI GANTRY LOWER LEVEL - BROOLKYN GANTRY LOWER LEVEL',\n", " 'len': 15493},\n", " '380': {'borough': 'Staten Island',\n", " 'link': 'SIE E VNB E FINGERBOARD ROAD - SI GANTRY UPPER LEVEL',\n", " 'len': 15493}}" ] }, "execution_count": 12, "metadata": {}, "output_type": "execute_result" } ], "source": [ "# sort the entries of id_info by the \"len\"\n", "\n", "id_info = dict(sorted(id_info.items(), key=lambda item: item[1]['len'], reverse=True))\n", "\n", "id_info" ] }, { "cell_type": "code", "execution_count": 16, "metadata": {}, "outputs": [ { "data": { "application/vnd.microsoft.datawrangler.viewer.v0+json": { "columns": [ { "name": "index", "rawType": "int64", "type": "integer" }, { "name": "ID", "rawType": "object", "type": "string" }, { "name": "SPEED", "rawType": "object", "type": "string" }, { "name": "TRAVEL_TIME", "rawType": "object", "type": "string" }, { "name": "STATUS", "rawType": "object", "type": "string" }, { "name": "DATA_AS_OF", "rawType": "object", "type": "string" }, { "name": "LINK_POINTS", "rawType": "object", "type": "string" }, { "name": "BOROUGH", "rawType": "object", "type": "string" }, { "name": "LINK_NAME", "rawType": "object", "type": "string" } ], "ref": "3f691a84-a340-4a83-823f-9b14f640fd79", "rows": [ [ "0", "262", "51.57", "245", "0", "20210831231304", "40.6332305,-74.016151 40.63391,-74.01613 40.6343505,-74.016241 40.63485,-74.016501 40.63533,-74.01694 40.63622,-74.01827 40.6375704,-74.02046 40.63803,-74.021071 40.6385,-74.02146 40.63908,-74.02173 40.63967,-74.02185 40.64036,-74.02172 40.64103,-74.02143", "Brooklyn", "GOW S 9TH STREET - 7TH AVENUE" ], [ "1", "262", "50.95", "248", "0", "20210831231804", "40.6332305,-74.016151 40.63391,-74.01613 40.6343505,-74.016241 40.63485,-74.016501 40.63533,-74.01694 40.63622,-74.01827 40.6375704,-74.02046 40.63803,-74.021071 40.6385,-74.02146 40.63908,-74.02173 40.63967,-74.02185 40.64036,-74.02172 40.64103,-74.02143", "Brooklyn", "GOW S 9TH STREET - 7TH AVENUE" ], [ "2", "262", "51.57", "246", "0", "20210831232305", "40.6332305,-74.016151 40.63391,-74.01613 40.6343505,-74.016241 40.63485,-74.016501 40.63533,-74.01694 40.63622,-74.01827 40.6375704,-74.02046 40.63803,-74.021071 40.6385,-74.02146 40.63908,-74.02173 40.63967,-74.02185 40.64036,-74.02172 40.64103,-74.02143", "Brooklyn", "GOW S 9TH STREET - 7TH AVENUE" ], [ "3", "262", "54.68", "230", "0", "20210831232804", "40.6332305,-74.016151 40.63391,-74.01613 40.6343505,-74.016241 40.63485,-74.016501 40.63533,-74.01694 40.63622,-74.01827 40.6375704,-74.02046 40.63803,-74.021071 40.6385,-74.02146 40.63908,-74.02173 40.63967,-74.02185 40.64036,-74.02172 40.64103,-74.02143", "Brooklyn", "GOW S 9TH STREET - 7TH AVENUE" ], [ "4", "262", "55.92", "225", "0", "20210831233304", "40.6332305,-74.016151 40.63391,-74.01613 40.6343505,-74.016241 40.63485,-74.016501 40.63533,-74.01694 40.63622,-74.01827 40.6375704,-74.02046 40.63803,-74.021071 40.6385,-74.02146 40.63908,-74.02173 40.63967,-74.02185 40.64036,-74.02172 40.64103,-74.02143", "Brooklyn", "GOW S 9TH STREET - 7TH AVENUE" ], [ "5", "262", "54.68", "231", "0", "20210831233804", "40.6332305,-74.016151 40.63391,-74.01613 40.6343505,-74.016241 40.63485,-74.016501 40.63533,-74.01694 40.63622,-74.01827 40.6375704,-74.02046 40.63803,-74.021071 40.6385,-74.02146 40.63908,-74.02173 40.63967,-74.02185 40.64036,-74.02172 40.64103,-74.02143", "Brooklyn", "GOW S 9TH STREET - 7TH AVENUE" ], [ "6", "262", "55.92", "227", "0", "20210831234304", "40.6332305,-74.016151 40.63391,-74.01613 40.6343505,-74.016241 40.63485,-74.016501 40.63533,-74.01694 40.63622,-74.01827 40.6375704,-74.02046 40.63803,-74.021071 40.6385,-74.02146 40.63908,-74.02173 40.63967,-74.02185 40.64036,-74.02172 40.64103,-74.02143", "Brooklyn", "GOW S 9TH STREET - 7TH AVENUE" ], [ "7", "262", "56.54", "224", "0", "20210831234804", "40.6332305,-74.016151 40.63391,-74.01613 40.6343505,-74.016241 40.63485,-74.016501 40.63533,-74.01694 40.63622,-74.01827 40.6375704,-74.02046 40.63803,-74.021071 40.6385,-74.02146 40.63908,-74.02173 40.63967,-74.02185 40.64036,-74.02172 40.64103,-74.02143", "Brooklyn", "GOW S 9TH STREET - 7TH AVENUE" ], [ "8", "262", "54.05", "233", "0", "20210831235305", "40.6332305,-74.016151 40.63391,-74.01613 40.6343505,-74.016241 40.63485,-74.016501 40.63533,-74.01694 40.63622,-74.01827 40.6375704,-74.02046 40.63803,-74.021071 40.6385,-74.02146 40.63908,-74.02173 40.63967,-74.02185 40.64036,-74.02172 40.64103,-74.02143", "Brooklyn", "GOW S 9TH STREET - 7TH AVENUE" ], [ "9", "262", "53.43", "236", "0", "20210831235804", "40.6332305,-74.016151 40.63391,-74.01613 40.6343505,-74.016241 40.63485,-74.016501 40.63533,-74.01694 40.63622,-74.01827 40.6375704,-74.02046 40.63803,-74.021071 40.6385,-74.02146 40.63908,-74.02173 40.63967,-74.02185 40.64036,-74.02172 40.64103,-74.02143", "Brooklyn", "GOW S 9TH STREET - 7TH AVENUE" ], [ "10", "262", "53.43", "236", "0", "20210901000304", "40.6332305,-74.016151 40.63391,-74.01613 40.6343505,-74.016241 40.63485,-74.016501 40.63533,-74.01694 40.63622,-74.01827 40.6375704,-74.02046 40.63803,-74.021071 40.6385,-74.02146 40.63908,-74.02173 40.63967,-74.02185 40.64036,-74.02172 40.64103,-74.02143", "Brooklyn", "GOW S 9TH STREET - 7TH AVENUE" ], [ "11", "262", "52.19", "240", "0", "20210901000804", "40.6332305,-74.016151 40.63391,-74.01613 40.6343505,-74.016241 40.63485,-74.016501 40.63533,-74.01694 40.63622,-74.01827 40.6375704,-74.02046 40.63803,-74.021071 40.6385,-74.02146 40.63908,-74.02173 40.63967,-74.02185 40.64036,-74.02172 40.64103,-74.02143", "Brooklyn", "GOW S 9TH STREET - 7TH AVENUE" ], [ "12", "262", "52.81", "238", "0", "20210901001304", "40.6332305,-74.016151 40.63391,-74.01613 40.6343505,-74.016241 40.63485,-74.016501 40.63533,-74.01694 40.63622,-74.01827 40.6375704,-74.02046 40.63803,-74.021071 40.6385,-74.02146 40.63908,-74.02173 40.63967,-74.02185 40.64036,-74.02172 40.64103,-74.02143", "Brooklyn", "GOW S 9TH STREET - 7TH AVENUE" ], [ "13", "262", "54.68", "232", "0", "20210901001804", "40.6332305,-74.016151 40.63391,-74.01613 40.6343505,-74.016241 40.63485,-74.016501 40.63533,-74.01694 40.63622,-74.01827 40.6375704,-74.02046 40.63803,-74.021071 40.6385,-74.02146 40.63908,-74.02173 40.63967,-74.02185 40.64036,-74.02172 40.64103,-74.02143", "Brooklyn", "GOW S 9TH STREET - 7TH AVENUE" ], [ "14", "262", "54.68", "231", "0", "20210901002304", "40.6332305,-74.016151 40.63391,-74.01613 40.6343505,-74.016241 40.63485,-74.016501 40.63533,-74.01694 40.63622,-74.01827 40.6375704,-74.02046 40.63803,-74.021071 40.6385,-74.02146 40.63908,-74.02173 40.63967,-74.02185 40.64036,-74.02172 40.64103,-74.02143", "Brooklyn", "GOW S 9TH STREET - 7TH AVENUE" ], [ "15", "262", "52.81", "239", "0", "20210901002804", "40.6332305,-74.016151 40.63391,-74.01613 40.6343505,-74.016241 40.63485,-74.016501 40.63533,-74.01694 40.63622,-74.01827 40.6375704,-74.02046 40.63803,-74.021071 40.6385,-74.02146 40.63908,-74.02173 40.63967,-74.02185 40.64036,-74.02172 40.64103,-74.02143", "Brooklyn", "GOW S 9TH STREET - 7TH AVENUE" ], [ "16", "262", "50.95", "248", "0", "20210901003304", "40.6332305,-74.016151 40.63391,-74.01613 40.6343505,-74.016241 40.63485,-74.016501 40.63533,-74.01694 40.63622,-74.01827 40.6375704,-74.02046 40.63803,-74.021071 40.6385,-74.02146 40.63908,-74.02173 40.63967,-74.02185 40.64036,-74.02172 40.64103,-74.02143", "Brooklyn", "GOW S 9TH STREET - 7TH AVENUE" ], [ "17", "262", "52.81", "239", "0", "20210901003804", "40.6332305,-74.016151 40.63391,-74.01613 40.6343505,-74.016241 40.63485,-74.016501 40.63533,-74.01694 40.63622,-74.01827 40.6375704,-74.02046 40.63803,-74.021071 40.6385,-74.02146 40.63908,-74.02173 40.63967,-74.02185 40.64036,-74.02172 40.64103,-74.02143", "Brooklyn", "GOW S 9TH STREET - 7TH AVENUE" ], [ "18", "262", "55.30", "229", "0", "20210901004304", "40.6332305,-74.016151 40.63391,-74.01613 40.6343505,-74.016241 40.63485,-74.016501 40.63533,-74.01694 40.63622,-74.01827 40.6375704,-74.02046 40.63803,-74.021071 40.6385,-74.02146 40.63908,-74.02173 40.63967,-74.02185 40.64036,-74.02172 40.64103,-74.02143", "Brooklyn", "GOW S 9TH STREET - 7TH AVENUE" ], [ "19", "262", "55.92", "226", "0", "20210901004804", "40.6332305,-74.016151 40.63391,-74.01613 40.6343505,-74.016241 40.63485,-74.016501 40.63533,-74.01694 40.63622,-74.01827 40.6375704,-74.02046 40.63803,-74.021071 40.6385,-74.02146 40.63908,-74.02173 40.63967,-74.02185 40.64036,-74.02172 40.64103,-74.02143", "Brooklyn", "GOW S 9TH STREET - 7TH AVENUE" ], [ "20", "262", "54.68", "232", "0", "20210901005305", "40.6332305,-74.016151 40.63391,-74.01613 40.6343505,-74.016241 40.63485,-74.016501 40.63533,-74.01694 40.63622,-74.01827 40.6375704,-74.02046 40.63803,-74.021071 40.6385,-74.02146 40.63908,-74.02173 40.63967,-74.02185 40.64036,-74.02172 40.64103,-74.02143", "Brooklyn", "GOW S 9TH STREET - 7TH AVENUE" ], [ "21", "262", "54.68", "232", "0", "20210901005804", "40.6332305,-74.016151 40.63391,-74.01613 40.6343505,-74.016241 40.63485,-74.016501 40.63533,-74.01694 40.63622,-74.01827 40.6375704,-74.02046 40.63803,-74.021071 40.6385,-74.02146 40.63908,-74.02173 40.63967,-74.02185 40.64036,-74.02172 40.64103,-74.02143", "Brooklyn", "GOW S 9TH STREET - 7TH AVENUE" ], [ "22", "262", "55.30", "228", "0", "20210901010304", "40.6332305,-74.016151 40.63391,-74.01613 40.6343505,-74.016241 40.63485,-74.016501 40.63533,-74.01694 40.63622,-74.01827 40.6375704,-74.02046 40.63803,-74.021071 40.6385,-74.02146 40.63908,-74.02173 40.63967,-74.02185 40.64036,-74.02172 40.64103,-74.02143", "Brooklyn", "GOW S 9TH STREET - 7TH AVENUE" ], [ "23", "262", "53.43", "237", "0", "20210901010804", "40.6332305,-74.016151 40.63391,-74.01613 40.6343505,-74.016241 40.63485,-74.016501 40.63533,-74.01694 40.63622,-74.01827 40.6375704,-74.02046 40.63803,-74.021071 40.6385,-74.02146 40.63908,-74.02173 40.63967,-74.02185 40.64036,-74.02172 40.64103,-74.02143", "Brooklyn", "GOW S 9TH STREET - 7TH AVENUE" ], [ "24", "262", "52.81", "240", "0", "20210901011304", "40.6332305,-74.016151 40.63391,-74.01613 40.6343505,-74.016241 40.63485,-74.016501 40.63533,-74.01694 40.63622,-74.01827 40.6375704,-74.02046 40.63803,-74.021071 40.6385,-74.02146 40.63908,-74.02173 40.63967,-74.02185 40.64036,-74.02172 40.64103,-74.02143", "Brooklyn", "GOW S 9TH STREET - 7TH AVENUE" ], [ "25", "262", "53.43", "235", "0", "20210901011804", "40.6332305,-74.016151 40.63391,-74.01613 40.6343505,-74.016241 40.63485,-74.016501 40.63533,-74.01694 40.63622,-74.01827 40.6375704,-74.02046 40.63803,-74.021071 40.6385,-74.02146 40.63908,-74.02173 40.63967,-74.02185 40.64036,-74.02172 40.64103,-74.02143", "Brooklyn", "GOW S 9TH STREET - 7TH AVENUE" ], [ "26", "262", "45.36", "279", "0", "20210901012304", "40.6332305,-74.016151 40.63391,-74.01613 40.6343505,-74.016241 40.63485,-74.016501 40.63533,-74.01694 40.63622,-74.01827 40.6375704,-74.02046 40.63803,-74.021071 40.6385,-74.02146 40.63908,-74.02173 40.63967,-74.02185 40.64036,-74.02172 40.64103,-74.02143", "Brooklyn", "GOW S 9TH STREET - 7TH AVENUE" ], [ "27", "262", "55.30", "228", "0", "20210901012804", "40.6332305,-74.016151 40.63391,-74.01613 40.6343505,-74.016241 40.63485,-74.016501 40.63533,-74.01694 40.63622,-74.01827 40.6375704,-74.02046 40.63803,-74.021071 40.6385,-74.02146 40.63908,-74.02173 40.63967,-74.02185 40.64036,-74.02172 40.64103,-74.02143", "Brooklyn", "GOW S 9TH STREET - 7TH AVENUE" ], [ "28", "262", "55.30", "228", "0", "20210901013304", "40.6332305,-74.016151 40.63391,-74.01613 40.6343505,-74.016241 40.63485,-74.016501 40.63533,-74.01694 40.63622,-74.01827 40.6375704,-74.02046 40.63803,-74.021071 40.6385,-74.02146 40.63908,-74.02173 40.63967,-74.02185 40.64036,-74.02172 40.64103,-74.02143", "Brooklyn", "GOW S 9TH STREET - 7TH AVENUE" ], [ "29", "262", "54.05", "233", "0", "20210901013804", "40.6332305,-74.016151 40.63391,-74.01613 40.6343505,-74.016241 40.63485,-74.016501 40.63533,-74.01694 40.63622,-74.01827 40.6375704,-74.02046 40.63803,-74.021071 40.6385,-74.02146 40.63908,-74.02173 40.63967,-74.02185 40.64036,-74.02172 40.64103,-74.02143", "Brooklyn", "GOW S 9TH STREET - 7TH AVENUE" ], [ "30", "262", "52.81", "240", "0", "20210901014303", "40.6332305,-74.016151 40.63391,-74.01613 40.6343505,-74.016241 40.63485,-74.016501 40.63533,-74.01694 40.63622,-74.01827 40.6375704,-74.02046 40.63803,-74.021071 40.6385,-74.02146 40.63908,-74.02173 40.63967,-74.02185 40.64036,-74.02172 40.64103,-74.02143", "Brooklyn", "GOW S 9TH STREET - 7TH AVENUE" ], [ "31", "262", "52.81", "239", "0", "20210901014804", "40.6332305,-74.016151 40.63391,-74.01613 40.6343505,-74.016241 40.63485,-74.016501 40.63533,-74.01694 40.63622,-74.01827 40.6375704,-74.02046 40.63803,-74.021071 40.6385,-74.02146 40.63908,-74.02173 40.63967,-74.02185 40.64036,-74.02172 40.64103,-74.02143", "Brooklyn", "GOW S 9TH STREET - 7TH AVENUE" ], [ "32", "262", "52.19", "242", "0", "20210901015304", "40.6332305,-74.016151 40.63391,-74.01613 40.6343505,-74.016241 40.63485,-74.016501 40.63533,-74.01694 40.63622,-74.01827 40.6375704,-74.02046 40.63803,-74.021071 40.6385,-74.02146 40.63908,-74.02173 40.63967,-74.02185 40.64036,-74.02172 40.64103,-74.02143", "Brooklyn", "GOW S 9TH STREET - 7TH AVENUE" ], [ "33", "262", "53.43", "235", "0", "20210901015804", "40.6332305,-74.016151 40.63391,-74.01613 40.6343505,-74.016241 40.63485,-74.016501 40.63533,-74.01694 40.63622,-74.01827 40.6375704,-74.02046 40.63803,-74.021071 40.6385,-74.02146 40.63908,-74.02173 40.63967,-74.02185 40.64036,-74.02172 40.64103,-74.02143", "Brooklyn", "GOW S 9TH STREET - 7TH AVENUE" ], [ "34", "262", "54.68", "231", "0", "20210901020304", "40.6332305,-74.016151 40.63391,-74.01613 40.6343505,-74.016241 40.63485,-74.016501 40.63533,-74.01694 40.63622,-74.01827 40.6375704,-74.02046 40.63803,-74.021071 40.6385,-74.02146 40.63908,-74.02173 40.63967,-74.02185 40.64036,-74.02172 40.64103,-74.02143", "Brooklyn", "GOW S 9TH STREET - 7TH AVENUE" ], [ "35", "262", "54.05", "232", "0", "20210901020904", "40.6332305,-74.016151 40.63391,-74.01613 40.6343505,-74.016241 40.63485,-74.016501 40.63533,-74.01694 40.63622,-74.01827 40.6375704,-74.02046 40.63803,-74.021071 40.6385,-74.02146 40.63908,-74.02173 40.63967,-74.02185 40.64036,-74.02172 40.64103,-74.02143", "Brooklyn", "GOW S 9TH STREET - 7TH AVENUE" ], [ "36", "262", "51.57", "244", "0", "20210901021304", "40.6332305,-74.016151 40.63391,-74.01613 40.6343505,-74.016241 40.63485,-74.016501 40.63533,-74.01694 40.63622,-74.01827 40.6375704,-74.02046 40.63803,-74.021071 40.6385,-74.02146 40.63908,-74.02173 40.63967,-74.02185 40.64036,-74.02172 40.64103,-74.02143", "Brooklyn", "GOW S 9TH STREET - 7TH AVENUE" ], [ "37", "262", "54.68", "230", "0", "20210901021904", "40.6332305,-74.016151 40.63391,-74.01613 40.6343505,-74.016241 40.63485,-74.016501 40.63533,-74.01694 40.63622,-74.01827 40.6375704,-74.02046 40.63803,-74.021071 40.6385,-74.02146 40.63908,-74.02173 40.63967,-74.02185 40.64036,-74.02172 40.64103,-74.02143", "Brooklyn", "GOW S 9TH STREET - 7TH AVENUE" ], [ "38", "262", "52.19", "242", "0", "20210901022304", "40.6332305,-74.016151 40.63391,-74.01613 40.6343505,-74.016241 40.63485,-74.016501 40.63533,-74.01694 40.63622,-74.01827 40.6375704,-74.02046 40.63803,-74.021071 40.6385,-74.02146 40.63908,-74.02173 40.63967,-74.02185 40.64036,-74.02172 40.64103,-74.02143", "Brooklyn", "GOW S 9TH STREET - 7TH AVENUE" ], [ "39", "262", "54.05", "234", "0", "20210901022904", "40.6332305,-74.016151 40.63391,-74.01613 40.6343505,-74.016241 40.63485,-74.016501 40.63533,-74.01694 40.63622,-74.01827 40.6375704,-74.02046 40.63803,-74.021071 40.6385,-74.02146 40.63908,-74.02173 40.63967,-74.02185 40.64036,-74.02172 40.64103,-74.02143", "Brooklyn", "GOW S 9TH STREET - 7TH AVENUE" ], [ "40", "262", "52.81", "238", "0", "20210901023304", "40.6332305,-74.016151 40.63391,-74.01613 40.6343505,-74.016241 40.63485,-74.016501 40.63533,-74.01694 40.63622,-74.01827 40.6375704,-74.02046 40.63803,-74.021071 40.6385,-74.02146 40.63908,-74.02173 40.63967,-74.02185 40.64036,-74.02172 40.64103,-74.02143", "Brooklyn", "GOW S 9TH STREET - 7TH AVENUE" ], [ "41", "262", "54.05", "234", "0", "20210901023803", "40.6332305,-74.016151 40.63391,-74.01613 40.6343505,-74.016241 40.63485,-74.016501 40.63533,-74.01694 40.63622,-74.01827 40.6375704,-74.02046 40.63803,-74.021071 40.6385,-74.02146 40.63908,-74.02173 40.63967,-74.02185 40.64036,-74.02172 40.64103,-74.02143", "Brooklyn", "GOW S 9TH STREET - 7TH AVENUE" ], [ "42", "262", "52.81", "238", "0", "20210901024303", "40.6332305,-74.016151 40.63391,-74.01613 40.6343505,-74.016241 40.63485,-74.016501 40.63533,-74.01694 40.63622,-74.01827 40.6375704,-74.02046 40.63803,-74.021071 40.6385,-74.02146 40.63908,-74.02173 40.63967,-74.02185 40.64036,-74.02172 40.64103,-74.02143", "Brooklyn", "GOW S 9TH STREET - 7TH AVENUE" ], [ "43", "262", "53.43", "237", "0", "20210901024804", "40.6332305,-74.016151 40.63391,-74.01613 40.6343505,-74.016241 40.63485,-74.016501 40.63533,-74.01694 40.63622,-74.01827 40.6375704,-74.02046 40.63803,-74.021071 40.6385,-74.02146 40.63908,-74.02173 40.63967,-74.02185 40.64036,-74.02172 40.64103,-74.02143", "Brooklyn", "GOW S 9TH STREET - 7TH AVENUE" ], [ "44", "262", "53.43", "235", "0", "20210901025404", "40.6332305,-74.016151 40.63391,-74.01613 40.6343505,-74.016241 40.63485,-74.016501 40.63533,-74.01694 40.63622,-74.01827 40.6375704,-74.02046 40.63803,-74.021071 40.6385,-74.02146 40.63908,-74.02173 40.63967,-74.02185 40.64036,-74.02172 40.64103,-74.02143", "Brooklyn", "GOW S 9TH STREET - 7TH AVENUE" ], [ "45", "262", "52.19", "242", "0", "20210901025804", "40.6332305,-74.016151 40.63391,-74.01613 40.6343505,-74.016241 40.63485,-74.016501 40.63533,-74.01694 40.63622,-74.01827 40.6375704,-74.02046 40.63803,-74.021071 40.6385,-74.02146 40.63908,-74.02173 40.63967,-74.02185 40.64036,-74.02172 40.64103,-74.02143", "Brooklyn", "GOW S 9TH STREET - 7TH AVENUE" ], [ "46", "262", "52.81", "239", "0", "20210901030404", "40.6332305,-74.016151 40.63391,-74.01613 40.6343505,-74.016241 40.63485,-74.016501 40.63533,-74.01694 40.63622,-74.01827 40.6375704,-74.02046 40.63803,-74.021071 40.6385,-74.02146 40.63908,-74.02173 40.63967,-74.02185 40.64036,-74.02172 40.64103,-74.02143", "Brooklyn", "GOW S 9TH STREET - 7TH AVENUE" ], [ "47", "262", "54.68", "232", "0", "20210901030804", "40.6332305,-74.016151 40.63391,-74.01613 40.6343505,-74.016241 40.63485,-74.016501 40.63533,-74.01694 40.63622,-74.01827 40.6375704,-74.02046 40.63803,-74.021071 40.6385,-74.02146 40.63908,-74.02173 40.63967,-74.02185 40.64036,-74.02172 40.64103,-74.02143", "Brooklyn", "GOW S 9TH STREET - 7TH AVENUE" ], [ "48", "262", "53.43", "235", "0", "20210901031404", "40.6332305,-74.016151 40.63391,-74.01613 40.6343505,-74.016241 40.63485,-74.016501 40.63533,-74.01694 40.63622,-74.01827 40.6375704,-74.02046 40.63803,-74.021071 40.6385,-74.02146 40.63908,-74.02173 40.63967,-74.02185 40.64036,-74.02172 40.64103,-74.02143", "Brooklyn", "GOW S 9TH STREET - 7TH AVENUE" ], [ "49", "262", "54.05", "232", "0", "20210901031804", "40.6332305,-74.016151 40.63391,-74.01613 40.6343505,-74.016241 40.63485,-74.016501 40.63533,-74.01694 40.63622,-74.01827 40.6375704,-74.02046 40.63803,-74.021071 40.6385,-74.02146 40.63908,-74.02173 40.63967,-74.02185 40.64036,-74.02172 40.64103,-74.02143", "Brooklyn", "GOW S 9TH STREET - 7TH AVENUE" ] ], "shape": { "columns": 8, "rows": 79441 } }, "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", "
IDSPEEDTRAVEL_TIMESTATUSDATA_AS_OFLINK_POINTSBOROUGHLINK_NAME
026251.5724502021083123130440.6332305,-74.016151 40.63391,-74.01613 40.63...BrooklynGOW S 9TH STREET - 7TH AVENUE
126250.9524802021083123180440.6332305,-74.016151 40.63391,-74.01613 40.63...BrooklynGOW S 9TH STREET - 7TH AVENUE
226251.5724602021083123230540.6332305,-74.016151 40.63391,-74.01613 40.63...BrooklynGOW S 9TH STREET - 7TH AVENUE
326254.6823002021083123280440.6332305,-74.016151 40.63391,-74.01613 40.63...BrooklynGOW S 9TH STREET - 7TH AVENUE
426255.9222502021083123330440.6332305,-74.016151 40.63391,-74.01613 40.63...BrooklynGOW S 9TH STREET - 7TH AVENUE
...........................
7943626241.6330202022081111180440.6332305,-74.016151 40.63391,-74.01613 40.63...BrooklynGOW S 9TH STREET - 7TH AVENUE
7943726239.1432102022081111230440.6332305,-74.016151 40.63391,-74.01613 40.63...BrooklynGOW S 9TH STREET - 7TH AVENUE
794382620.000-1012022081111280440.6332305,-74.016151 40.63391,-74.01613 40.63...BrooklynGOW S 9TH STREET - 7TH AVENUE
794392620.000-1012023071215000440.6332305,-74.016151 40.63391,-74.01613 40.63...BrooklynGOW S 9TH STREET - 7TH AVENUE
7944026200-1012023101613440340.6332305,-74.016151 40.63391,-74.01613 40.63...BrooklynGOW S 9TH STREET - 7TH AVENUE
\n", "

79441 rows × 8 columns

\n", "
" ], "text/plain": [ " ID SPEED TRAVEL_TIME STATUS DATA_AS_OF \\\n", "0 262 51.57 245 0 20210831231304 \n", "1 262 50.95 248 0 20210831231804 \n", "2 262 51.57 246 0 20210831232305 \n", "3 262 54.68 230 0 20210831232804 \n", "4 262 55.92 225 0 20210831233304 \n", "... ... ... ... ... ... \n", "79436 262 41.63 302 0 20220811111804 \n", "79437 262 39.14 321 0 20220811112304 \n", "79438 262 0.00 0 -101 20220811112804 \n", "79439 262 0.00 0 -101 20230712150004 \n", "79440 262 0 0 -101 20231016134403 \n", "\n", " LINK_POINTS BOROUGH \\\n", "0 40.6332305,-74.016151 40.63391,-74.01613 40.63... Brooklyn \n", "1 40.6332305,-74.016151 40.63391,-74.01613 40.63... Brooklyn \n", "2 40.6332305,-74.016151 40.63391,-74.01613 40.63... Brooklyn \n", "3 40.6332305,-74.016151 40.63391,-74.01613 40.63... Brooklyn \n", "4 40.6332305,-74.016151 40.63391,-74.01613 40.63... Brooklyn \n", "... ... ... \n", "79436 40.6332305,-74.016151 40.63391,-74.01613 40.63... Brooklyn \n", "79437 40.6332305,-74.016151 40.63391,-74.01613 40.63... Brooklyn \n", "79438 40.6332305,-74.016151 40.63391,-74.01613 40.63... Brooklyn \n", "79439 40.6332305,-74.016151 40.63391,-74.01613 40.63... Brooklyn \n", "79440 40.6332305,-74.016151 40.63391,-74.01613 40.63... Brooklyn \n", "\n", " LINK_NAME \n", "0 GOW S 9TH STREET - 7TH AVENUE \n", "1 GOW S 9TH STREET - 7TH AVENUE \n", "2 GOW S 9TH STREET - 7TH AVENUE \n", "3 GOW S 9TH STREET - 7TH AVENUE \n", "4 GOW S 9TH STREET - 7TH AVENUE \n", "... ... \n", "79436 GOW S 9TH STREET - 7TH AVENUE \n", "79437 GOW S 9TH STREET - 7TH AVENUE \n", "79438 GOW S 9TH STREET - 7TH AVENUE \n", "79439 GOW S 9TH STREET - 7TH AVENUE \n", "79440 GOW S 9TH STREET - 7TH AVENUE \n", "\n", "[79441 rows x 8 columns]" ] }, "execution_count": 16, "metadata": {}, "output_type": "execute_result" } ], "source": [ "df = pd.read_parquet(\"./full_data/id_262.parquet\")\n", "df" ] }, { "cell_type": "code", "execution_count": 17, "metadata": {}, "outputs": [ { "data": { "text/plain": [ "['378',\n", " '129',\n", " '126',\n", " '295',\n", " '159',\n", " '338',\n", " '427',\n", " '381',\n", " '350',\n", " '154',\n", " '435',\n", " '384',\n", " '439',\n", " '385',\n", " '390',\n", " '351',\n", " '388',\n", " '434',\n", " '382',\n", " '383',\n", " '258',\n", " '259',\n", " '261',\n", " '137',\n", " '399',\n", " '426',\n", " '369',\n", " '315',\n", " '171',\n", " '142',\n", " '170',\n", " '425',\n", " '145',\n", " '150',\n", " '4',\n", " '1',\n", " '215',\n", " '217',\n", " '165',\n", " '422',\n", " '377',\n", " '325',\n", " '329',\n", " '265',\n", " '324',\n", " '311',\n", " '119',\n", " '298',\n", " '364',\n", " '211',\n", " '318',\n", " '124',\n", " '365',\n", " '213',\n", " '212',\n", " '405',\n", " '319',\n", " '441',\n", " '345',\n", " '186',\n", " '344',\n", " '191',\n", " '190',\n", " '448',\n", " '417',\n", " '195',\n", " '411',\n", " '207',\n", " '331',\n", " '332',\n", " '169',\n", " '199',\n", " '208',\n", " '450',\n", " '223',\n", " '149',\n", " '221',\n", " '222',\n", " '2',\n", " '3',\n", " '106',\n", " '204',\n", " '167',\n", " '172',\n", " '177',\n", " '424',\n", " '423',\n", " '178',\n", " '157',\n", " '185',\n", " '160',\n", " '148',\n", " '184',\n", " '428',\n", " '453',\n", " '354',\n", " '394',\n", " '433',\n", " '431',\n", " '430',\n", " '387',\n", " '437',\n", " '375',\n", " '376',\n", " '406',\n", " '402',\n", " '451',\n", " '164',\n", " '168',\n", " '202',\n", " '398',\n", " '140',\n", " '141',\n", " '347',\n", " '395',\n", " '330',\n", " '349',\n", " '436',\n", " '264',\n", " '263',\n", " '339',\n", " '445',\n", " '257',\n", " '153',\n", " '155',\n", " '110',\n", " '440',\n", " '206',\n", " '205',\n", " '262',\n", " '418',\n", " '412',\n", " '419',\n", " '413',\n", " '379',\n", " '410',\n", " '416',\n", " '380']" ] }, "execution_count": 17, "metadata": {}, "output_type": "execute_result" } ], "source": [ "id_list" ] }, { "cell_type": "code", "execution_count": 18, "metadata": {}, "outputs": [ { "data": { "text/plain": [ "dict_keys(['204', '184', '217', '221', '149', '223', '145', '208', '207', '332', '169', '170', '171', '315', '330', '345', '344', '191', '213', '399', '395', '410', '347', '140', '398', '202', '168', '298', '451', '416', '190', '212', '318', '211', '319', '311', '419', '418', '387', '385', '390', '388', '412', '413', '258', '259', '394', '261', '154', '155', '153', '453', '428', '129', '126', '295', '427', '142', '185', '426', '425', '178', '422', '423', '424', '165', '177', '172', '167', '257', '222', '215', '265', '380', '137', '124', '205', '206', '405', '376', '375', '381', '377', '378', '435', '384', '157'])" ] }, "execution_count": 18, "metadata": {}, "output_type": "execute_result" } ], "source": [ "# read data/NYC_traffic_speed/expanded_id_info.json, find all \n", "with open('../expanded_id_info.json', 'r') as f:\n", " expanded_id_info = json.load(f)\n", "expanded_id_info.keys()" ] }, { "cell_type": "code", "execution_count": 20, "metadata": {}, "outputs": [ { "data": { "text/plain": [ "51" ] }, "execution_count": 20, "metadata": {}, "output_type": "execute_result" } ], "source": [ "# find item in id_list but not in expanded_id_info\n", "missing_ids = [id for id in id_list if str(id) not in expanded_id_info]\n", "len(missing_ids)" ] }, { "cell_type": "code", "execution_count": 21, "metadata": {}, "outputs": [ { "data": { "text/plain": [ "{'159': {'borough': 'Bronx',\n", " 'link': 'BRP N WATSON AVENUE - FORDHAM ROAD',\n", " 'len': 322911},\n", " '338': {'borough': 'Bronx',\n", " 'link': 'MDE N RFK Bridge - 142nd St',\n", " 'len': 322890},\n", " '350': {'borough': 'Staten Island',\n", " 'link': 'MLK S - SIE E WALKER STREET - WOOLEY AVENUE',\n", " 'len': 322889},\n", " '439': {'borough': 'Staten Island',\n", " 'link': 'WSE S SOUTH AVENUE - VICTORY BOULEVARD',\n", " 'len': 322861},\n", " '351': {'borough': 'Staten Island',\n", " 'link': 'MLK S - SIE W WALKER STREET - RICHMOND AVENUE',\n", " 'len': 322890},\n", " '434': {'borough': 'Staten Island',\n", " 'link': 'WSE N VICTORY BLVD - SOUTH AVENUE',\n", " 'len': 322864},\n", " '382': {'borough': 'Staten Island',\n", " 'link': 'SIE E-MLK N RICHMOND AVENUE - WALKER STREET',\n", " 'len': 322883},\n", " '383': {'borough': 'Staten Island',\n", " 'link': 'SIE W - MLK N WOOLEY AVENUE - WLAKER STREET',\n", " 'len': 322880},\n", " '369': {'borough': 'Staten Island',\n", " 'link': 'ROUTE 169 S - MLK WALKER STREET',\n", " 'len': 321735},\n", " '150': {'borough': 'Manhattan',\n", " 'link': 'BQE N Atlantic Ave - MAN Bridge Manhattan Side',\n", " 'len': 317848},\n", " '4': {'borough': 'Manhattan',\n", " 'link': '12th Ave N 40th - 57th St',\n", " 'len': 322884},\n", " '1': {'borough': 'Manhattan',\n", " 'link': '11th ave n ganservoort - 12th ave @ 40th st',\n", " 'len': 322923},\n", " '325': {'borough': 'Manhattan',\n", " 'link': 'LINCOLN TUNNEL E SOUTH TUBE - NJ - NY',\n", " 'len': 321917},\n", " '329': {'borough': 'Manhattan',\n", " 'link': 'LINCOLN TUNNEL W CENTER TUBE NY - NJ',\n", " 'len': 321919},\n", " '324': {'borough': 'Manhattan',\n", " 'link': 'LINCOLN TUNNEL E CENTER TUBE NJ - NY',\n", " 'len': 321919},\n", " '119': {'borough': 'Manhattan',\n", " 'link': 'BBT E Manhattan Portal - Toll Plaza',\n", " 'len': 322016},\n", " '364': {'borough': 'Manhattan',\n", " 'link': 'QMT E Manhattan Side - Toll Plaza',\n", " 'len': 321989},\n", " '365': {'borough': 'Queens',\n", " 'link': 'QMT W Toll Plaza - Manhattan Side',\n", " 'len': 321990},\n", " '441': {'borough': 'Staten Island',\n", " 'link': 'WSE S VICTORY BOULEVARD - ARDEN AVENUE',\n", " 'len': 322852},\n", " '186': {'borough': 'Bronx',\n", " 'link': 'CBE W L/LE V AMSTERDAM AVE - I 95 S LOC LNS',\n", " 'len': 321916},\n", " '448': {'borough': 'Manhattan',\n", " 'link': 'Westside Hwy N 57th St - GWB',\n", " 'len': 321874},\n", " '417': {'borough': 'Brooklyn',\n", " 'link': 'VNB W BROOKLYN GANTRY UPPER LEVEL - SI GANTRY UPPER LEVEL',\n", " 'len': 278893},\n", " '195': {'borough': 'Bronx',\n", " 'link': 'CBE W U/LEV AMSTERDAM AVE - I95 S EXP LNS',\n", " 'len': 321922},\n", " '411': {'borough': 'Brooklyn',\n", " 'link': 'VNB E SI GANTRY UPPER LEVEL - BROOKLYN GANTRY UPPER LEVEL',\n", " 'len': 278894},\n", " '331': {'borough': 'Queens',\n", " 'link': 'Laurelton Pkwy N @ SSP - CIP N Hempstead Tpk',\n", " 'len': 322884},\n", " '199': {'borough': 'Queens',\n", " 'link': 'CIP N Hempstead Tpk - LIE',\n", " 'len': 322896},\n", " '450': {'borough': 'Manhattan',\n", " 'link': 'Westside Hwy S GWB - 57th St',\n", " 'len': 322780},\n", " '2': {'borough': 'Manhattan',\n", " 'link': '11th ave s ganservoort - west st @ spring st',\n", " 'len': 322913},\n", " '3': {'borough': 'Manhattan',\n", " 'link': '12th ave @ 45th - 11 ave ganservoort st',\n", " 'len': 322891},\n", " '106': {'borough': 'Manhattan',\n", " 'link': '12th Ave S 57th St - 45th St',\n", " 'len': 322910},\n", " '160': {'borough': 'Bronx',\n", " 'link': 'BRP S FORDHAM ROAD - WATSON AVENUE',\n", " 'len': 322905},\n", " '148': {'borough': 'Brooklyn',\n", " 'link': 'BQE N ATLANTIC AVENUE - LEONARD STREET',\n", " 'len': 322904},\n", " '354': {'borough': 'Bronx',\n", " 'link': 'I-87 NYST S Exit 1 - MDE S Van Cortlandt Park',\n", " 'len': 322878},\n", " '433': {'borough': 'Staten Island',\n", " 'link': 'WSE N TYRELLAN AVENUE - BLOOMINGDALE ROAD',\n", " 'len': 322852},\n", " '431': {'borough': 'Staten Island',\n", " 'link': 'WSE N BLOOMUINGDALE ROAD - ARDEN AVENUE',\n", " 'len': 322858},\n", " '430': {'borough': 'Staten Island',\n", " 'link': 'WSE N ARDEN AVENUE - VICTORY BLVD',\n", " 'len': 322859},\n", " '437': {'borough': 'Staten Island',\n", " 'link': 'WSE S BLLOMINGDALE ROAD - TYRELLAN AVENUE',\n", " 'len': 322854},\n", " '406': {'borough': 'Queens',\n", " 'link': 'TNB S Toll Plaza - Queens Anchorage',\n", " 'len': 321972},\n", " '402': {'borough': 'Queens',\n", " 'link': 'TNB N Queens Anchorage - Toll Plaza',\n", " 'len': 321977},\n", " '164': {'borough': 'Queens',\n", " 'link': 'BWB N Queens Anchorage - Toll Plaza',\n", " 'len': 322011},\n", " '141': {'borough': 'Queens',\n", " 'link': 'BE S TBB EXIT RAMP - QUEENS ANCHORAGE',\n", " 'len': 322000},\n", " '349': {'borough': 'Staten Island',\n", " 'link': 'MLK N WALKER STREET - NJ ROUTE 169',\n", " 'len': 321907},\n", " '436': {'borough': 'Staten Island',\n", " 'link': 'WSE S ARDEN AVENUE - BLOOMINGDALE ROAD',\n", " 'len': 322852},\n", " '264': {'borough': 'Brooklyn',\n", " 'link': 'GOW S VNB W 92ND STREET - BKLYN GANTRY UPPER LEVEL',\n", " 'len': 173235},\n", " '263': {'borough': 'Brooklyn',\n", " 'link': 'GOW S VNB W 92ND STREET - BKLYN GANTRY LOWER LEVEL',\n", " 'len': 173235},\n", " '339': {'borough': 'Bronx',\n", " 'link': 'MDE N VAN CORTLAND PARK - NYST N EXIT 1 (MP.48)',\n", " 'len': 52636},\n", " '445': {'borough': 'Manhattan',\n", " 'link': 'West St S Spring St - BBT Manhattan Portal outbound',\n", " 'len': 304827},\n", " '110': {'borough': 'Staten Island',\n", " 'link': '440 N FRANCIS STREET - WSE N TYRELLAN AVE',\n", " 'len': 129201},\n", " '440': {'borough': 'Staten Island',\n", " 'link': 'WSE S TYRELLAN AVENUE - 440 S FRANCIS STREET',\n", " 'len': 128660},\n", " '262': {'borough': 'Brooklyn',\n", " 'link': 'GOW S 9TH STREET - 7TH AVENUE',\n", " 'len': 79441},\n", " '379': {'borough': 'Staten Island',\n", " 'link': 'SIE E VNB E FINGERBOARD ROAD - SI GANTRY LOWER LEVEL',\n", " 'len': 15493}}" ] }, "execution_count": 21, "metadata": {}, "output_type": "execute_result" } ], "source": [ "missing_info = {str(id): id_info[str(id)] for id in missing_ids if str(id) in id_info}\n", "missing_info" ] }, { "cell_type": "code", "execution_count": 22, "metadata": {}, "outputs": [], "source": [ "# save the missing_ids to a json file\n", "with open('./missing_ids.json', 'w') as f:\n", " json.dump(missing_info, f)" ] }, { "cell_type": "code", "execution_count": 24, "metadata": {}, "outputs": [ { "data": { "application/vnd.microsoft.datawrangler.viewer.v0+json": { "columns": [ { "name": "index", "rawType": "int64", "type": "integer" }, { "name": "DATA_AS_OF", "rawType": "object", "type": "string" }, { "name": "SPEED", "rawType": "object", "type": "string" }, { "name": "TRAVEL_TIME", "rawType": "object", "type": "string" } ], "ref": "3e4cd871-1460-4c8a-96eb-4aa425b5ce15", "rows": [ [ "0", "20210831231304", "51.57", "245" ], [ "1", "20210831231804", "50.95", "248" ], [ "2", "20210831232305", "51.57", "246" ], [ "3", "20210831232804", "54.68", "230" ], [ "4", "20210831233304", "55.92", "225" ], [ "5", "20210831233804", "54.68", "231" ], [ "6", "20210831234304", "55.92", "227" ], [ "7", "20210831234804", "56.54", "224" ], [ "8", "20210831235305", "54.05", "233" ], [ "9", "20210831235804", "53.43", "236" ], [ "10", "20210901000304", "53.43", "236" ], [ "11", "20210901000804", "52.19", "240" ], [ "12", "20210901001304", "52.81", "238" ], [ "13", "20210901001804", "54.68", "232" ], [ "14", "20210901002304", "54.68", "231" ], [ "15", "20210901002804", "52.81", "239" ], [ "16", "20210901003304", "50.95", "248" ], [ "17", "20210901003804", "52.81", "239" ], [ "18", "20210901004304", "55.30", "229" ], [ "19", "20210901004804", "55.92", "226" ], [ "20", "20210901005305", "54.68", "232" ], [ "21", "20210901005804", "54.68", "232" ], [ "22", "20210901010304", "55.30", "228" ], [ "23", "20210901010804", "53.43", "237" ], [ "24", "20210901011304", "52.81", "240" ], [ "25", "20210901011804", "53.43", "235" ], [ "26", "20210901012304", "45.36", "279" ], [ "27", "20210901012804", "55.30", "228" ], [ "28", "20210901013304", "55.30", "228" ], [ "29", "20210901013804", "54.05", "233" ], [ "30", "20210901014303", "52.81", "240" ], [ "31", "20210901014804", "52.81", "239" ], [ "32", "20210901015304", "52.19", "242" ], [ "33", "20210901015804", "53.43", "235" ], [ "34", "20210901020304", "54.68", "231" ], [ "35", "20210901020904", "54.05", "232" ], [ "36", "20210901021304", "51.57", "244" ], [ "37", "20210901021904", "54.68", "230" ], [ "38", "20210901022304", "52.19", "242" ], [ "39", "20210901022904", "54.05", "234" ], [ "40", "20210901023304", "52.81", "238" ], [ "41", "20210901023803", "54.05", "234" ], [ "42", "20210901024303", "52.81", "238" ], [ "43", "20210901024804", "53.43", "237" ], [ "44", "20210901025404", "53.43", "235" ], [ "45", "20210901025804", "52.19", "242" ], [ "46", "20210901030404", "52.81", "239" ], [ "47", "20210901030804", "54.68", "232" ], [ "48", "20210901031404", "53.43", "235" ], [ "49", "20210901031804", "54.05", "232" ] ], "shape": { "columns": 3, "rows": 79441 } }, "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", "
DATA_AS_OFSPEEDTRAVEL_TIME
02021083123130451.57245
12021083123180450.95248
22021083123230551.57246
32021083123280454.68230
42021083123330455.92225
............
794362022081111180441.63302
794372022081111230439.14321
79438202208111128040.000
79439202307121500040.000
794402023101613440300
\n", "

79441 rows × 3 columns

\n", "
" ], "text/plain": [ " DATA_AS_OF SPEED TRAVEL_TIME\n", "0 20210831231304 51.57 245\n", "1 20210831231804 50.95 248\n", "2 20210831232305 51.57 246\n", "3 20210831232804 54.68 230\n", "4 20210831233304 55.92 225\n", "... ... ... ...\n", "79436 20220811111804 41.63 302\n", "79437 20220811112304 39.14 321\n", "79438 20220811112804 0.00 0\n", "79439 20230712150004 0.00 0\n", "79440 20231016134403 0 0\n", "\n", "[79441 rows x 3 columns]" ] }, "execution_count": 24, "metadata": {}, "output_type": "execute_result" } ], "source": [ "df = pd.read_parquet(\"./slim_data/id_262.parquet\")\n", "df" ] } ], "metadata": { "kernelspec": { "display_name": "IATSF", "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.11" } }, "nbformat": 4, "nbformat_minor": 2 }