Predicion error dictionary prepartion

In this module, the prediction error dictionary is formed based on the arrival time predictions computed in the previous module.

The dictionary contains the actual time of arrival, predicted arrival time, error in arrival time prediction for all the bus-stops of the routes.

[1]:
import json
from pymongo import MongoClient
import math
import numpy as np
[2]:
import pprint
[3]:
con = MongoClient()
[4]:
RouteName='Git_ISCON_PDPU'
[5]:
def TActual(TripIndex, SingleTripsInfo, BusStopsCount, TripStartHour, Bound,
            RouteName, ResultPathDir, ResultPathDir_Np, UseMongoDB, PredictionDictLists):
    '''
    Input: Trip index, trips list, bus-stop count, trip start hour, trip direction (or bound)
    route name, directory paths, the flag `UseMongoDB` to determine whether MongoDB database or
    numpy files are used, and dictionary of prediction and actual values.
    Output: The actual time for different bus-stop for the provided trip
    Function: It extracts the actual time at different bus-stops for the provided trip.
    '''
    TActualNpArray =  np.full((BusStopsCount),np.inf,dtype=float)
    for index in range(BusStopsCount):

        AcutalValueList = [record['TActual'] for record in PredictionDictLists
                           if record['id']==index]

        if len(AcutalValueList)!=0:
            try:
                TActualNpArray[index] = AcutalValueList[0]
                #print('AcutalValueList', AcutalValueList)
            except IndexError:
                print('AcutalValueList Error', AcutalValueList)
                #input()
    return(TActualNpArray)
[6]:
def ErrorMatrix(TripIndex, SingleTripsInfo, BusStopsCount, TripStartHour, Bound,
                RouteName, ResultPathDir, ResultPathDir_Np, UseMongoDB):

    '''
    Input: Trip index, trips list, bus-stop count, trip start hour, trip direction (or bound)
    route name, directory paths, the flag `UseMongoDB` to determine whether MongoDB database or
    numpy files are used.
    Output: The dictionary of prediction error for different bus-stop for the provided trip.
    Function: It extracts the prediction value and computes the dictionary of prediction error for
    different bus-stop for the provided trip.
    '''

    SingleTripInfo = SingleTripsInfo[TripIndex]

    if UseMongoDB==True:
        PredictionDictLists = [record for record in
                               con[RouteName][SingleTripsInfo[TripIndex]+'.PredictionResult_Dist_th_50'].find()]

    else:
        PredictionDictLists = np.load(f'{ResultPathDir_Np}/{RouteName}/{SingleTripInfo}.PredictionResult_Dist_th_50.npy', allow_pickle=True)

    TActualNpArray = TActual(TripIndex, SingleTripsInfo, BusStopsCount, TripStartHour, Bound,
                             RouteName, ResultPathDir, ResultPathDir_Np, UseMongoDB, PredictionDictLists)



    ErrorNpMatrix = np.full((BusStopsCount,BusStopsCount),np.inf,dtype=float)

    for index in range (BusStopsCount):
        PredictionDictList = [rec for rec in PredictionDictLists if rec['id']==index]

        if len(PredictionDictList)!=0:
            if PredictionDictList[0]['PredictionAvailable'] ==True:
                for PredIndex in range(len(PredictionDictList[0]['PredictionTupleList'])):
                    BusStopPredictionIndex = PredictionDictList[0]['PredictionTupleList'][PredIndex][0]
                    if TActualNpArray[BusStopPredictionIndex]!=np.inf:

                        '''For margin considering in prediction error calculation'''
                        ErrorList =[]
                        ErrorList.append(abs(TActualNpArray[BusStopPredictionIndex]-PredictionDictList[0]['PredictionTupleList'][PredIndex][1]))
                        # The prediction and margin are generated at same time and stored subsequently. Hence PredictionIndex must get access
                        # for the same ID

                        if PredictionDictList[0]['PredictionMarginTupleList'][PredIndex][0]==PredictionDictList[0]['PredictionTupleList'][PredIndex][0]:
                            PredictionL=int(PredictionDictList[0]['PredictionTupleList'][PredIndex][1]-PredictionDictList[0]['PredictionMarginTupleList'][PredIndex][1])
                            PredictionH=int(PredictionDictList[0]['PredictionTupleList'][PredIndex][1]+PredictionDictList[0]['PredictionMarginTupleList'][PredIndex][1])
                            for Prediction in range (PredictionL,PredictionH,1000):
                                ErrorList.append(abs(TActualNpArray[BusStopPredictionIndex]-Prediction))
                            #ErrorList.append(abs(TActualNpArray[BusStopPredictionIndex]-()))
                            #ErrorList.append(abs(TActualNpArray[BusStopPredictionIndex]-(PredictionDictList[0]['PredictionTupleList'][PredIndex][1]+PredictionDictList[0]['PredictionMarginTupleList'][PredIndex][1])))

                        ErrorConsideringMargin=min(ErrorList)
                        ErrorNpMatrix[PredictionDictList[0]['PredictionTupleList'][PredIndex][0]][index]=ErrorConsideringMargin
                        '''For margin considering in prediction error calculation'''

                        #ErrorNpMatrix[PredictionDictList[0]['PredictionTupleList'][PredIndex][0]][index]=abs(TActualNpArray[BusStopPredictionIndex]-PredictionDictList[0]['PredictionTupleList'][PredIndex][1])

    return(ErrorNpMatrix)
[7]:
def InitializeErrorMatrixList(SingleTripsInfo, BusStopsCount, TripStartHour, Bound,
                              RouteName, ResultPathDir, ResultPathDir_Np, UseMongoDB):
    '''
    Input: Trips list, bus-stop count, trip start hour, trip direction (or bound)
    route name, directory paths, the flag `UseMongoDB` to determine whether MongoDB database or
    numpy files are used, and dictionary of prediction and actual values.
    Output: The dictionary of prediction error for different bus-stop for all the trips.
    Function: It forms the dictionary of prediction error for different bus-stop for all the trips.
    '''
    ErrorMatrixList = []
    for TripIndex in range(len(SingleTripsInfo)):
        ErrorMatrixList.append(ErrorMatrix(TripIndex, SingleTripsInfo, BusStopsCount, TripStartHour, Bound,
                                           RouteName, ResultPathDir, ResultPathDir_Np, UseMongoDB))
    return(ErrorMatrixList)

[8]:
def GetErrorMatrixList(SingleTripsInfo, BusStopsCount, TripStartHour, Bound,
                       RouteName, ResultPathDir, ResultPathDir_Np, UseMongoDB
                      ):

    '''
    Input: Trips list, bus-stop count, trip start hour, trip direction (or bound)
    route name, directory paths, the flag `UseMongoDB` to determine whether MongoDB database or
    numpy files are used.
    Output: None
    Function: It extracts the prediction value and computes the dictionary of prediction error for
    different bus-stop and stores either in MongoDB or in Numpy file.
    '''
    ErrorMatrixList = InitializeErrorMatrixList(SingleTripsInfo, BusStopsCount, TripStartHour, Bound,
                                                RouteName, ResultPathDir, ResultPathDir_Np, UseMongoDB)

    ErrorDictList =[]
    for PredictionForIndex in range(BusStopsCount):
        ErrorDict ={}
        ErrorDict['id']=PredictionForIndex
        ErrorDict['PredictionByIndexList']=[]
        PredictionAvailable = False

        '''List for Error for given BusStop by all stops in all trips'''
        ErrorListForID =[]

        for PredictionByIndex in range(BusStopsCount):
            '''List for Error for given BusStop by given stop in all trips'''
            ErrorList =[]

            for ErrorIndex in range(len(ErrorMatrixList)):
                if ErrorMatrixList[ErrorIndex][PredictionForIndex][PredictionByIndex] != np.inf:
                    ErrorList.append(ErrorMatrixList[ErrorIndex][PredictionForIndex][PredictionByIndex])

                    ErrorListForID.append(ErrorMatrixList[ErrorIndex][PredictionForIndex][PredictionByIndex])
            if len(ErrorList) != 0:
                PredictionAvailable = True
                ErrorListNP = np.asarray(ErrorList)
                print('PredictionFor: '+str(PredictionForIndex))
                print('PredictionByIndex: '+str(PredictionByIndex))
                print(ErrorList)
                #input()
                ErrorDict['PredictionByIndexList'].append(PredictionByIndex)
                ErrorDict[str(PredictionByIndex)]=(np.mean(ErrorListNP),np.std(ErrorListNP))

        if len(ErrorListForID)!=0:
            ErrorListForIDNP = np.asarray(ErrorListForID)

            ErrorDict['PredictionErrorAggregateMean'] = np.mean(ErrorListForIDNP)
            ErrorDict['PredictionErrorAggregateSTD'] = np.std(ErrorListForIDNP)
            ErrorDict['PredictionErrorAggregateMax'] = np.amax(ErrorListForIDNP)

            ErrorListForID.sort()
            NinetyPercentileValueIndex = int(len(ErrorListForID)*0.9)

            ErrorDict['PredictionErrorAggregateNinetyPercentileValue'] = ErrorListForID [NinetyPercentileValueIndex]

        ErrorDict['PredictionAvailable'] = PredictionAvailable
        ErrorDictList.append(ErrorDict)

    print('ErrorDictList', ErrorDictList)

    if UseMongoDB==True:
        #con[RouteName].drop_collection(f'PredictionErrorForSubStopsV2.{TripStartHour}.{Bound}')
        con[RouteName][f'PredictionErrorForSubStopsV2.{TripStartHour}.{Bound}'].insert_many(ErrorDictList)
    else:
        np.save(f'{ResultPathDir_Np}/{RouteName}/PredictionErrorForSubStopsV2.{TripStartHour}.{Bound}.npy',
                ErrorDictList
               )

    return(ErrorDictList)

Considered Trips for prediction

[9]:
from pathlib import Path
import os
'''For directory management'''

path = Path(os.getcwd())

OneLevelUpPath = path.parents[0]
NpPathDir = os.path.join(str(OneLevelUpPath), 'data','NpData')
ResultPathDir = os.path.join(str(OneLevelUpPath), 'results','PredictionError','')

ResultPathDir_Np = os.path.join(str(OneLevelUpPath), 'results','NpData','')

[10]:
#'''
ProjectDataUsed = True
UsedPreTrained = False
UseMongoDB = True
#'''
'''
ProjectDataUsed = True
UsedPreTrained = True
UseMongoDB = False
'''
[10]:
'\nProjectDataUsed = True\nUsedPreTrained = True\nUseMongoDB = False\n'

’‘’SingleTripsInfo is initialized with list of selected trips’’’

[12]:
SingleTripsInfo = ['19_01_2018__07_38_47',
 '22_12_2017__07_38_21',
 '20_12_2017__07_38_14',
 '29_12_2017__07_37_27',
 '29_01_2018__07_39_47',
 '30_01_2018__07_42_30',
 '02_02_2018__07_38_50',
 '12_02_2018__07_40_14',
 '16_02_2018__07_45_41',
# '14_03_2018__07_35_46',
# '20_03_2018__07_28_45',
# '22_03_2018__07_38_43',
 '14_02_2018__07_41_04',
 '22_02_2018__07_42_45',
# '03_04_2018__07_38_31',
 #Added morning
'18_01_2018__07_38_10',
'08_01_2018__07_41_43',
'09_01_2018__07_40_01',]
[13]:
if UseMongoDB==True:
    TripInfo = [rec for rec in con[RouteName]['TripInfo'].find({'SingleTripInfo':SingleTripsInfo[0]})]
    TripStartHour = TripInfo[0]['TripStartHour']
    Bound = TripInfo[0]['Bound']

    BusStopsList = [BusStop for BusStop in con[RouteName][f'BusStops.{Bound}Bound'].find().sort([('id',1)])]
else:
    TripsInfo = np.load(f'{NpPathDir}/{RouteName}/TripInfo.npy',allow_pickle=True)
    TripInfo = [rec for rec in TripsInfo if rec['SingleTripInfo']==SingleTripsInfo[0]]
    TripStartHour = TripInfo[0]['TripStartHour']
    Bound = TripInfo[0]['Bound']

    BusStopsList = np.load(f'{NpPathDir}/{RouteName}/BusStops.{Bound}Bound.npy',allow_pickle=True)

print('StartHour, Bound, BusStopsCount', TripStartHour, Bound, len (BusStopsList))
StartHour, Bound, BusStopsCount 07 North 15
[14]:
BusStopsCount = len (BusStopsList)
[15]:
ErrorDictList = GetErrorMatrixList(SingleTripsInfo, BusStopsCount, TripStartHour, Bound,
                                   RouteName, ResultPathDir, ResultPathDir_Np, UseMongoDB
                                  )
PredictionFor: 1
PredictionByIndex: 1
[64000.0]
PredictionFor: 2
PredictionByIndex: 1
[19000.0]
PredictionFor: 2
PredictionByIndex: 2
[11832.0, 218.0, 93.0, 179950.0, 70561.0, 10193.0, 247.0, 170.0, 48.0, 7085.0, 79683.87084960938, 471.0, 15583.0]
PredictionFor: 3
PredictionByIndex: 1
[54740.0]
PredictionFor: 3
PredictionByIndex: 2
[37837.0, 6634.0, 224.0, 162015.0, 90996.0, 71078.0, 2435.0, 22.0, 41013.0, 160817.0, 2227.0, 26766.0]
PredictionFor: 3
PredictionByIndex: 3
[463.0, 99.0, 106.0, 180.0, 48114.0, 276.0, 9289.0, 21521.0, 20378.0, 17.0, 63041.0, 478.0, 9736.0]
PredictionFor: 4
PredictionByIndex: 1
[79218.0]
PredictionFor: 4
PredictionByIndex: 2
[50514.0, 199.0, 62.0, 130155.0, 91767.0, 118610.0, 38108.0, 9569.0, 30431.0, 57344.0, 190273.0, 12657.0, 14134.0]
PredictionFor: 4
PredictionByIndex: 3
[336.0, 316.0, 26130.0, 883.0, 128484.0, 26777.0, 46844.0, 60505.0, 62503.0, 467.0, 82762.0, 81.0, 36640.0]
PredictionFor: 4
PredictionByIndex: 4
[461.0, 419.0, 2823.0, 383.0, 183.0, 357.0, 6051.0, 286.0, 3549.0, 477.0, 37.0, 20618.0, 168.0, 113.0]
PredictionFor: 5
PredictionByIndex: 1
[77610.0]
PredictionFor: 5
PredictionByIndex: 2
[37349.0, 21.0, 256.0, 93256.0, 63096.0, 160901.0, 76974.0, 8365.0, 84448.0, 38762.0, 193822.0, 4762.0, 2074.0]
PredictionFor: 5
PredictionByIndex: 3
[22895.0, 3823.0, 30730.0, 475.0, 195397.0, 67112.0, 79859.0, 102418.0, 120738.0, 225.0, 73167.0, 101.0, 48413.0]
PredictionFor: 5
PredictionByIndex: 4
[30470.0, 118.0, 108.0, 15854.0, 408.0, 954.0, 17339.0, 136.0, 677.0, 18895.0, 441.0, 97793.0, 492.0, 398.0]
PredictionFor: 5
PredictionByIndex: 5
[2921.0, 225.0, 414.0, 572.0, 446.0, 27.0, 449.0, 255.0, 436.0, 5098.0, 9985.0, 4471.0, 61.0, 372.0]
PredictionFor: 6
PredictionByIndex: 1
[18345.0]
PredictionFor: 6
PredictionByIndex: 2
[140761.0, 241.0, 351.0, 14450.0, 145634.0, 211326.0, 17731.0, 285.0, 123603.0, 42645.0, 137282.0, 419.0, 127.0]
PredictionFor: 6
PredictionByIndex: 3
[278.0, 52214.0, 31039.0, 42.0, 263638.0, 52.0, 126309.0, 44514.0, 161693.0, 372.0, 11365.0, 81.0, 57258.0]
PredictionFor: 6
PredictionByIndex: 4
[466.0, 78222.0, 499.0, 36884.0, 32008.0, 41483.0, 54482.0, 16181.0, 85.0, 44977.0, 466.0, 166382.0, 243.0, 351.0]
PredictionFor: 6
PredictionByIndex: 5
[22.0, 59606.0, 71.0, 17679.0, 8373.0, 42644.0, 9603.0, 22590.0, 96.0, 27810.0, 282.0, 48665.0, 238.0, 258.0]
PredictionFor: 6
PredictionByIndex: 6
[22402.0, 86160.0, 258.0, 83.0, 19185.0, 73834.0, 14427.0, 36934.0, 51.0, 5.0, 296.0, 12374.0, 89.0, 458.0]
PredictionFor: 7
PredictionByIndex: 1
[28962.0]
PredictionFor: 7
PredictionByIndex: 2
[151427.0, 6176.0, 37173.0, 10712.0, 144440.0, 241984.0, 43007.0, 3225.0, 162982.0, 46879.0, 148091.0, 11627.0, 474.0]
PredictionFor: 7
PredictionByIndex: 3
[13774.0, 60969.0, 58580.0, 33704.0, 312856.0, 13336.0, 155218.0, 70387.0, 201851.0, 6903.0, 21435.0, 246.0, 82734.0]
PredictionFor: 7
PredictionByIndex: 4
[4538.0, 88420.0, 19855.0, 77089.0, 68081.0, 39690.0, 79292.0, 30528.0, 20539.0, 78700.0, 5943.0, 209529.0, 4218.0, 3315.0]
PredictionFor: 7
PredictionByIndex: 5
[41942.0, 68271.0, 3104.0, 56161.0, 42395.0, 40957.0, 30456.0, 37514.0, 9447.0, 60077.0, 20382.0, 81141.0, 332.0, 58.0]
PredictionFor: 7
PredictionByIndex: 6
[76590.0, 97352.0, 2881.0, 22205.0, 54756.0, 74362.0, 35979.0, 51714.0, 293.0, 26006.0, 401.0, 39515.0, 475.0, 5409.0]
PredictionFor: 7
PredictionByIndex: 7
[6896.0, 25373.0, 360.0, 496.0, 382.0, 32347.0, 459.0, 5212.0, 3163.0, 282.0, 7743.0, 351.0, 158.0, 368.0537109375]
PredictionFor: 8
PredictionByIndex: 1
[4605.0]
PredictionFor: 8
PredictionByIndex: 2
[115584.0, 33066.0, 26671.0, 478.0, 109102.0, 266543.0, 83133.0, 304.0, 204773.0, 19267.0, 124654.0, 30158.0, 98.0]
PredictionFor: 8
PredictionByIndex: 3
[136.0, 24529.0, 86312.0, 23143.0, 341786.0, 34091.0, 178430.0, 110985.0, 244218.0, 19866.0, 115.0, 13005.0, 92699.0]
PredictionFor: 8
PredictionByIndex: 4
[486.0, 52185.0, 45949.0, 68431.0, 87001.0, 4679.0, 99351.0, 381.0, 42311.0, 116301.0, 18864.0, 230821.0, 214.0, 8825.0]
PredictionFor: 8
PredictionByIndex: 5
[8351.0, 31757.0, 301.0, 46170.0, 59753.0, 6031.0, 47469.0, 60.0, 31910.0, 96598.0, 34211.0, 94199.0, 22.0, 472.0]
PredictionFor: 8
PredictionByIndex: 6
[46601.0, 62783.0, 29176.0, 8840.0, 73294.0, 42869.0, 53531.0, 3722.0, 20778.0, 59367.0, 13.0, 48457.0, 6487.0, 11674.0]
PredictionFor: 8
PredictionByIndex: 7
[131.0, 88494.0, 11966.0, 393.0, 442.0, 85685.0, 139.0, 62598.0, 25696.0, 14186.0, 25718.0, 337.0, 8567.0, 165.0]
PredictionFor: 8
PredictionByIndex: 8
[48256.0, 399.0, 3339.0, 1744.0, 185.0, 72.0, 133.0, 17907.0, 333.0, 6740.0, 350.0, 80.0, 591.0, 81.0]
PredictionFor: 9
PredictionByIndex: 1
[30951.0]
PredictionFor: 9
PredictionByIndex: 2
[9940.0, 108.0, 29504.0, 233.0, 9742.0, 281785.0, 95578.0, 486.0, 230406.0, 228.0, 151305.0, 184.0, 295105.0]
PredictionFor: 9
PredictionByIndex: 3
[122.0, 346.0, 426.0, 25955.0, 344951.0, 20606.0, 193217.0, 123588.0, 270045.0, 361.0, 20837.0, 433.0, 393423.0]
PredictionFor: 9
PredictionByIndex: 4
[90.0, 409.0, 495.0, 71892.0, 86792.0, 430.0, 113071.0, 83.0, 390.0, 140530.0, 346.0, 97748.0, 76.0, 309417.0]
PredictionFor: 9
PredictionByIndex: 5
[229.0, 452.0, 134.0, 49176.0, 59018.0, 189.0, 60160.0, 490.0, 223.0, 120465.0, 0.0, 405.0, 220.0, 291743.0]
PredictionFor: 9
PredictionByIndex: 6
[217.0, 431.0, 179.87548828125, 10696.0, 72957.0, 190.0, 66404.0, 340.0, 240.0, 82175.0, 310.0, 303.0, 291.0, 312514.0]
PredictionFor: 9
PredictionByIndex: 7
[187.0, 94098.0, 335.0, 387.0, 368.0, 83219.0, 356.0, 80809.0, 33.0, 33822.0, 93.0, 15185.0, 476.0, 284179.0]
PredictionFor: 9
PredictionByIndex: 8
[38762.0, 193.0, 248.0, 45.0, 345.0, 159.0, 8750.0, 27685.0, 107.0, 24981.0, 384.0, 245.0, 16.0, 285073.0]
PredictionFor: 9
PredictionByIndex: 9
[341.0, 87.0, 481.0, 201.0, 403.0, 16.0, 109.0, 93.0, 54.0, 248.0, 269.0, 10898.0, 73.0, 271003.0]
PredictionFor: 10
PredictionByIndex: 1
[134833.0]
PredictionFor: 10
PredictionByIndex: 2
[43714.0, 27914.0, 94104.0, 62585.0, 70976.0, 371178.0, 179703.0, 371.0, 331599.0, 54211.0, 255365.0, 247.0, 321789.0]
PredictionFor: 10
PredictionByIndex: 3
[49144.0, 5205.0, 81614.0, 90544.0, 424922.0, 77070.0, 282340.0, 207808.0, 371350.0, 342.0, 125487.0, 2059.0, 420404.0]
PredictionFor: 10
PredictionByIndex: 4
[59017.0, 104.0, 40368.0, 136870.0, 164736.0, 269.0, 201560.0, 70162.0, 17449.0, 240898.0, 366.0, 116374.0, 32958.0, 335752.0]
PredictionFor: 10
PredictionByIndex: 5
[17832.0, 18.0, 345.0, 113881.0, 136645.0, 129.0, 148037.0, 62477.0, 7424.0, 220621.0, 2476.0, 435.0, 27599.0, 318895.0]
PredictionFor: 10
PredictionByIndex: 6
[351.0, 397.0, 23703.0, 74710.0, 150823.0, 5830.0, 154389.0, 46033.0, 239.0, 181710.0, 6126.0, 35465.0, 8190.0, 338991.0]
PredictionFor: 10
PredictionByIndex: 7
[74725.0, 186344.0, 4506.0, 35041.0, 59718.0, 146347.0, 72442.0, 168398.0, 1248.0, 131497.0, 240.0, 119104.0, 5865.0, 309613.0]
PredictionFor: 10
PredictionByIndex: 8
[138572.0, 68684.0, 431.0, 11266.0, 50926.0, 13615.0, 95553.0, 110207.0, 2980.0, 121838.0, 19454.0, 103875.0, 16295.0, 310587.0]
PredictionFor: 10
PredictionByIndex: 9
[32594.0, 37599.0, 7586.0, 46016.0, 41915.0, 5264.0, 65769.0, 51207.0, 20262.0, 80427.0, 21921.0, 115043.0, 50182.0, 296686.0]
PredictionFor: 10
PredictionByIndex: 10
[2161.0, 309.0, 36790.0, 319.0, 13.0, 384.0, 203.0, 340.0, 289.0, 2799.0, 117.0, 3961.0, 194.0, 98319.0]
PredictionFor: 11
PredictionByIndex: 1
[125948.0]
PredictionFor: 11
PredictionByIndex: 2
[31782.0, 14539.0, 87642.0, 86330.0, 127412.0, 394612.0, 211878.0, 97.0, 361833.0, 40866.0, 246529.0, 495.0, 318415.0]
PredictionFor: 11
PredictionByIndex: 3
[74729.0, 31223.0, 68286.0, 84078.0, 448975.0, 38805.0, 305702.0, 240007.0, 401614.0, 16078.0, 116539.0, 173.0, 417129.0]
PredictionFor: 11
PredictionByIndex: 4
[84625.0, 2850.0, 26949.0, 130509.0, 188248.0, 23184.0, 224756.0, 102060.0, 32028.0, 270921.0, 15052.0, 135942.0, 30795.0, 332263.0]
PredictionFor: 11
PredictionByIndex: 5
[43308.0, 24040.0, 4255.0, 107447.0, 160073.0, 24587.0, 171072.0, 94352.0, 22041.0, 250590.0, 30944.0, 432.0, 25419.0, 315345.0]
PredictionFor: 11
PredictionByIndex: 6
[2930.0, 260.0, 10295.0, 68089.0, 174315.0, 62460.0, 177452.0, 77831.0, 10324.0, 211519.0, 95.0, 26549.0, 5919.0, 335548.0]
PredictionFor: 11
PredictionByIndex: 7
[101072.0, 214670.0, 105.0, 27993.0, 82271.0, 109714.0, 94664.0, 201484.0, 15869.0, 160830.0, 23940.0, 111048.0, 3568.0, 306827.0]
PredictionFor: 11
PredictionByIndex: 8
[166471.0, 94258.0, 278.0, 3648.0, 73274.0, 878.0, 118304.0, 141960.0, 2458.0, 150962.0, 7155.0, 95467.0, 14248.0, 307827.0]
PredictionFor: 11
PredictionByIndex: 9
[56578.0, 62015.0, 32928.0, 39719.0, 63926.0, 9517.0, 87427.0, 80796.0, 20397.0, 108095.0, 9717.0, 107049.0, 49432.0, 293321.0]
PredictionFor: 11
PredictionByIndex: 10
[22724.0, 10911.0, 29630.0, 16244.0, 562.0, 54575.0, 6320.0, 10159.0, 16971.0, 22144.0, 444.0, 175.599365234375, 6728.0, 170239.0]
PredictionFor: 11
PredictionByIndex: 11
[205.0, 499.0, 25531.0, 2094.0, 87.0, 33910.0, 473.0, 477.0, 165.0, 5.0, 16251.0, 22000.0, 442.0, 46.912353515625]
PredictionFor: 12
PredictionByIndex: 1
[119957.0]
PredictionFor: 12
PredictionByIndex: 2
[21014.0, 8611.0, 99155.0, 94427.0, 152552.0, 417000.0, 236758.0, 4527.0, 381184.0, 53033.0, 240559.0, 429.0, 325911.0]
PredictionFor: 12
PredictionByIndex: 3
[57914.0, 51028.0, 62379.0, 95590.0, 457206.0, 19736.0, 328060.0, 264898.0, 420977.0, 11946.0, 110520.0, 4758.0, 424668.0]
PredictionFor: 12
PredictionByIndex: 4
[67820.0, 22627.0, 21003.0, 142069.0, 196244.0, 48331.0, 247040.0, 126825.0, 29618.0, 290181.0, 10918.0, 148236.0, 35756.0, 339708.0]
PredictionFor: 12
PredictionByIndex: 5
[26442.0, 43847.0, 16282.0, 118973.0, 168032.0, 49735.0, 193287.0, 119106.0, 19648.0, 269826.0, 26834.0, 6669.0, 30373.0, 322764.0]
PredictionFor: 12
PredictionByIndex: 6
[25.0, 10999.0, 4353.0, 79532.0, 182302.0, 87680.0, 199679.0, 102552.0, 7907.0, 230687.0, 5127.0, 20545.0, 10832.0, 343014.0]
PredictionFor: 12
PredictionByIndex: 7
[84609.0, 235463.0, 136.0, 39246.0, 89850.0, 91325.0, 116527.0, 226751.0, 13478.0, 179792.0, 19935.0, 105424.0, 8471.0, 314140.0]
PredictionFor: 12
PredictionByIndex: 8
[150726.0, 113873.0, 4414.0, 14646.0, 80764.0, 26458.0, 140397.0, 166662.0, 14335.0, 169834.0, 19794.0, 89687.0, 19260.0, 315152.0]
PredictionFor: 12
PredictionByIndex: 9
[39022.0, 81134.0, 45727.0, 51307.0, 71269.0, 35217.0, 109047.0, 104582.0, 32565.0, 126341.0, 22399.0, 101452.0, 55011.0, 300379.0]
PredictionFor: 12
PredictionByIndex: 10
[3583.0, 27806.0, 26898.0, 16508.0, 5096.0, 81016.0, 24422.0, 30945.0, 16819.0, 36805.0, 279.0, 2404.0, 13985.0, 198486.0]
PredictionFor: 12
PredictionByIndex: 11
[17537.0, 7612.0, 48334.0, 1161.0, 404.0, 58450.0, 3696.0, 18584.0, 172.0, 714.0, 16622.0, 45390.0, 4341.0, 476.0]
PredictionFor: 12
PredictionByIndex: 12
[23788.0, 498.0, 316.0, 2665.0, 416.0, 112.0, 2.0, 208.0, 20.0, 140.0, 7204.0, 80.0, 107.0, 409.0]
PredictionFor: 13
PredictionByIndex: 1
[119606.0]
PredictionFor: 13
PredictionByIndex: 2
[4946.0, 2944.0, 88008.0, 104601.0, 151846.0, 422161.0, 261691.0, 425.0, 401859.0, 46958.0, 240217.0, 245.0, 342250.0]
PredictionFor: 13
PredictionByIndex: 3
[86299.0, 64112.0, 56721.0, 84442.0, 467438.0, 16474.0, 333207.0, 289835.0, 441658.0, 15035.0, 110157.0, 17088.0, 441025.0]
PredictionFor: 13
PredictionByIndex: 4
[96210.0, 35699.0, 15327.0, 130941.0, 206374.0, 47627.0, 252157.0, 151708.0, 51730.0, 310818.0, 14008.0, 146719.0, 48098.0, 356025.0]
PredictionFor: 13
PredictionByIndex: 5
[54803.0, 56932.0, 19992.0, 107831.0, 178146.0, 49033.0, 198374.0, 143985.0, 41767.0, 290453.0, 29933.0, 5068.0, 42712.0, 339069.0]
PredictionFor: 13
PredictionByIndex: 6
[14293.0, 24054.0, 320.0, 68354.0, 192428.0, 87009.0, 204771.0, 127417.0, 30016.0, 251285.0, 76.0, 20187.0, 23154.0, 359340.0]
PredictionFor: 13
PredictionByIndex: 7
[113159.0, 248967.0, 152.0, 27985.0, 99801.0, 88364.0, 121464.0, 251845.0, 35598.0, 200303.0, 23080.0, 105231.0, 20788.0, 330401.0]
PredictionFor: 13
PredictionByIndex: 8
[179614.0, 126876.0, 8171.0, 3275.0, 90676.0, 25946.0, 145431.0, 191519.0, 427.0, 190306.0, 13923.0, 89428.0, 31624.0, 331418.0]
PredictionFor: 13
PredictionByIndex: 9
[67058.0, 93926.0, 49771.0, 40192.0, 81118.0, 34758.0, 113879.0, 129055.0, 9784.0, 146547.0, 16547.0, 101272.0, 67621.0, 316530.0]
PredictionFor: 13
PredictionByIndex: 10
[30875.0, 39651.0, 21617.0, 27290.0, 13734.0, 81327.0, 27749.0, 54159.0, 39915.0, 55488.0, 213.0, 2951.0, 38.0, 191581.0]
PredictionFor: 13
PredictionByIndex: 11
[126.0, 18273.0, 56717.0, 9992.0, 4518.0, 57478.0, 5793.0, 41094.0, 5301.0, 17293.0, 20660.0, 48685.0, 195.0, 14327.0]
PredictionFor: 13
PredictionByIndex: 12
[177.0, 5544.0, 131.0, 454.0, 91.0, 92.0, 1557.0, 18963.0, 319.0, 9767.0, 5706.0, 493.0, 8164.0, 14404.0]
PredictionFor: 13
PredictionByIndex: 13
[29975.0, 241.0, 479.0, 2326.0, 139.0, 329.0, 102.0, 6165.0, 15420.0, 3963.0, 458.0, 169.0, 1646.0, 4556.0]
PredictionFor: 14
PredictionByIndex: 1
[110010.0]
PredictionFor: 14
PredictionByIndex: 2
[357.0, 471.0, 57027.0, 121672.0, 128255.0, 459220.0, 272322.0, 6545.0, 418809.0, 66779.0, 230628.0, 223.0, 339132.0]
PredictionFor: 14
PredictionByIndex: 3
[85382.0, 66426.0, 47311.0, 53460.0, 484547.0, 38087.0, 370257.0, 300470.0, 458611.0, 225.0, 100553.0, 14112.0, 437921.0]
PredictionFor: 14
PredictionByIndex: 4
[95296.0, 38004.0, 5906.0, 99972.0, 223416.0, 24039.0, 289187.0, 162306.0, 60705.0, 327742.0, 197.0, 153404.0, 45131.0, 352893.0]
PredictionFor: 14
PredictionByIndex: 5
[53868.0, 59246.0, 25437.0, 76853.0, 195178.0, 25445.0, 235384.0, 154580.0, 50747.0, 307371.0, 8129.0, 11697.0, 39743.0, 335929.0]
PredictionFor: 14
PredictionByIndex: 6
[13328.0, 26348.0, 260.0, 37353.0, 209467.0, 63443.0, 241786.0, 138003.0, 38989.0, 268183.0, 18914.0, 10588.0, 20173.0, 356213.0]
PredictionFor: 14
PredictionByIndex: 7
[112362.0, 251567.0, 3295.0, 70.0, 116722.0, 110184.0, 158377.0, 262587.0, 44578.0, 217143.0, 1307.0, 95744.0, 17804.0, 327229.0]
PredictionFor: 14
PredictionByIndex: 8
[179060.0, 129135.0, 13648.0, 2852.0, 107572.0, 2490.0, 182408.0, 202100.0, 408.0, 207120.0, 33885.0, 79894.0, 28672.0, 328250.0]
PredictionFor: 14
PredictionByIndex: 9
[65889.0, 96041.0, 55442.0, 9231.0, 97971.0, 11338.0, 150725.0, 139373.0, 35.0, 163184.0, 36522.0, 91793.0, 64837.0, 313282.0]
PredictionFor: 14
PredictionByIndex: 10
[29169.0, 41122.0, 14140.0, 56342.0, 29777.0, 58437.0, 63617.0, 63617.0, 49564.0, 71107.0, 1734.0, 11042.0, 957.0, 199642.0]
PredictionFor: 14
PredictionByIndex: 11
[482.0, 18939.0, 65328.0, 39422.0, 20211.0, 32704.0, 40860.0, 50070.0, 14603.0, 31508.0, 196.0, 58647.0, 323.0, 11227.0]
PredictionFor: 14
PredictionByIndex: 12
[455.0, 5112.0, 62.0, 9604.0, 6707.0, 24764.0, 36272.0, 26056.0, 8082.0, 23345.0, 28694.0, 88.0, 6514.0, 11311.0]
PredictionFor: 14
PredictionByIndex: 13
[37402.0, 256.0, 141.0, 32426.0, 14087.0, 25055.0, 18742.0, 10429.0, 26603.0, 16280.0, 272.0, 20.0, 473.0, 450.0]
PredictionFor: 14
PredictionByIndex: 14
[8127.0, 218.0, 426.0, 10430.0, 145.0, 10987.0, 21405.0, 90.0, 135.0, 487.0, 11014.0, 86.0, 341.0, 163.0]
ErrorDictList [{'id': 0, 'PredictionByIndexList': [], 'PredictionAvailable': False}, {'id': 1, 'PredictionByIndexList': [1], '1': (64000.0, 0.0), 'PredictionErrorAggregateMean': 64000.0, 'PredictionErrorAggregateSTD': 0.0, 'PredictionErrorAggregateMax': 64000.0, 'PredictionErrorAggregateNinetyPercentileValue': 64000.0, 'PredictionAvailable': True}, {'id': 2, 'PredictionByIndexList': [1, 2], '1': (19000.0, 0.0), '2': (28933.451603816105, 50660.85366764), 'PredictionErrorAggregateMean': 28223.91934640067, 'PredictionErrorAggregateSTD': 48885.00543021303, 'PredictionErrorAggregateMax': 179950.0, 'PredictionErrorAggregateNinetyPercentileValue': 79683.87084960938, 'PredictionAvailable': True}, {'id': 3, 'PredictionByIndexList': [1, 2, 3], '1': (54740.0, 0.0), '2': (50172.0, 57097.60624725582), '3': (13361.384615384615, 19667.120529680855), 'PredictionErrorAggregateMean': 31942.384615384617, 'PredictionErrorAggregateSTD': 45211.399576856995, 'PredictionErrorAggregateMax': 162015.0, 'PredictionErrorAggregateNinetyPercentileValue': 90996.0, 'PredictionAvailable': True}, {'id': 4, 'PredictionByIndexList': [1, 2, 3, 4], '1': (79218.0, 0.0), '2': (57217.153846153844, 56666.40619632677), '3': (36363.692307692305, 37899.54642794273), '4': (2566.0714285714284, 5285.712108590285), 'PredictionErrorAggregateMean': 32480.341463414636, 'PredictionErrorAggregateSTD': 45174.852337205055, 'PredictionErrorAggregateMax': 190273.0, 'PredictionErrorAggregateNinetyPercentileValue': 91767.0, 'PredictionAvailable': True}, {'id': 5, 'PredictionByIndexList': [1, 2, 3, 4, 5], '1': (77610.0, 0.0), '2': (58775.846153846156, 60303.721150454025), '3': (57334.846153846156, 55866.960085609644), '4': (13148.785714285714, 25330.119045962914), '5': (1838.0, 2780.8551100079167), 'PredictionErrorAggregateMean': 32670.254545454547, 'PredictionErrorAggregateSTD': 49427.99599167852, 'PredictionErrorAggregateMax': 195397.0, 'PredictionErrorAggregateNinetyPercentileValue': 97793.0, 'PredictionAvailable': True}, {'id': 6, 'PredictionByIndexList': [1, 2, 3, 4, 5, 6], '1': (18345.0, 0.0), '2': (64219.61538461538, 72607.3860234602), '3': (57604.230769230766, 77233.63881521478), '4': (33766.357142857145, 44077.05280302915), '5': (16995.5, 19738.65563069438), '6': (19039.714285714286, 27249.541077206555), 'PredictionErrorAggregateMean': 37380.82608695652, 'PredictionErrorAggregateSTD': 55805.31367794999, 'PredictionErrorAggregateMax': 263638.0, 'PredictionErrorAggregateNinetyPercentileValue': 137282.0, 'PredictionAvailable': True}, {'id': 7, 'PredictionByIndexList': [1, 2, 3, 4, 5, 6, 7], '1': (28962.0, 0.0), '2': (77553.61538461539, 77649.03158991793), '3': (79384.07692307692, 88470.03029662865), '4': (52124.07142857143, 53552.57920087815), '5': (35159.78571428572, 25049.065050070294), '6': (34852.71428571428, 31171.264377922937), '7': (5970.718122209822, 9771.6742278228), 'PredictionErrorAggregateMean': 46538.00064711973, 'PredictionErrorAggregateSTD': 59924.37896078157, 'PredictionErrorAggregateMax': 312856.0, 'PredictionErrorAggregateNinetyPercentileValue': 144440.0, 'PredictionAvailable': True}, {'id': 8, 'PredictionByIndexList': [1, 2, 3, 4, 5, 6, 7, 8], '1': (4605.0, 0.0), '2': (77987.0, 80722.64595038228), '3': (89947.30769230769, 101657.21154515352), '4': (55414.21428571428, 61538.268255473784), '5': (32664.571428571428, 32211.310351033724), '6': (33399.42857142857, 23900.43415539405), '7': (23179.785714285714, 30832.995561755342), '8': (5729.285714285715, 12677.838270150067), 'PredictionErrorAggregateMean': 44259.51546391752, 'PredictionErrorAggregateSTD': 63076.733730476495, 'PredictionErrorAggregateMax': 341786.0, 'PredictionErrorAggregateNinetyPercentileValue': 110985.0, 'PredictionAvailable': True}, {'id': 9, 'PredictionByIndexList': [1, 2, 3, 4, 5, 6, 7, 8, 9], '1': (30951.0, 0.0), '2': (84969.53846153847, 110527.37958784788), '3': (107254.61538461539, 139032.60689135452), '4': (58697.78571428572, 85479.09660109773), '5': (41636.0, 77863.17894963484), '6': (39089.13396344866, 81448.34115692912), '7': (42396.21428571428, 75251.38614402355), '8': (27642.35714285714, 72476.22546700317), '9': (20305.428571428572, 69585.38809950824), 'PredictionErrorAggregateMean': 51771.18806746199, 'PredictionErrorAggregateSTD': 94589.66505516005, 'PredictionErrorAggregateMax': 393423.0, 'PredictionErrorAggregateNinetyPercentileValue': 230406.0, 'PredictionAvailable': True}, {'id': 10, 'PredictionByIndexList': [1, 2, 3, 4, 5, 6, 7, 8, 9, 10], '1': (134833.0, 0.0), '2': (139519.6923076923, 129842.54114378137), '3': (164483.76923076922, 153266.4025721498), '4': (101205.92857142857, 99581.69035051738), '5': (75486.71428571429, 96062.68558708986), '6': (73354.07142857143, 95933.24916275623), '7': (93934.85714285714, 86183.50227099081), '8': (76020.21428571429, 80154.41622908566), '9': (62319.357142857145, 70784.79727678328), '10': (10442.714285714286, 26079.899598373162), 'PredictionErrorAggregateMean': 87884.576, 'PredictionErrorAggregateSTD': 106257.94792321288, 'PredictionErrorAggregateMax': 424922.0, 'PredictionErrorAggregateNinetyPercentileValue': 282340.0, 'PredictionAvailable': True}, {'id': 11, 'PredictionByIndexList': [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11], '1': (125948.0, 0.0), '2': (147879.23076923078, 136908.3907689618), '3': (172564.46153846153, 160394.3943738565), '4': (114298.71428571429, 101211.84655635396), '5': (90993.21428571429, 95177.66761106648), '6': (83113.28571428571, 99302.70068721953), '7': (103861.07142857143, 87669.77645400322), '8': (84084.85714285714, 86216.65795031984), '9': (72922.64285714286, 68527.68167224432), '10': (26273.32852608817, 42291.74374878493), '11': (7298.993739536831, 11368.252256776143), 'PredictionErrorAggregateMean': 89579.5792209982, 'PredictionErrorAggregateSTD': 107050.72979494999, 'PredictionErrorAggregateMax': 448975.0, 'PredictionErrorAggregateNinetyPercentileValue': 270921.0, 'PredictionAvailable': True}, {'id': 12, 'PredictionByIndexList': [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12], '1': (119957.0, 0.0), '2': (156550.76923076922, 143069.25185654988), '3': (177667.6923076923, 167744.46479937393), '4': (123312.57142857143, 105108.34604398474), '5': (100844.14285714286, 98553.11835383651), '6': (91802.42857142857, 103954.45888788738), '7': (108939.07142857143, 93417.51645738784), '8': (94714.42857142857, 85446.14611614757), '9': (83960.85714285714, 67799.86668956252), '10': (34646.57142857143, 49537.75189073234), '11': (15963.785714285714, 19396.174951257683), '12': (2568.9285714285716, 6171.704597415133), 'PredictionErrorAggregateMean': 89276.70588235294, 'PredictionErrorAggregateSTD': 108789.05472818512, 'PredictionErrorAggregateMax': 457206.0, 'PredictionErrorAggregateNinetyPercentileValue': 264898.0, 'PredictionAvailable': True}, {'id': 13, 'PredictionByIndexList': [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13], '1': (119606.0, 0.0), '2': (159088.53846153847, 151402.4957652311), '3': (186422.38461538462, 172343.793630209), '4': (133102.92857142858, 107375.35929989065), '5': (111292.71428571429, 101034.7271758072), '6': (100193.14285714286, 107501.91538483472), '7': (119081.28571428571, 98411.43136737475), '8': (102045.28571428571, 94347.99215020695), '9': (90575.57142857143, 74081.8176764373), '10': (41899.142857142855, 47094.1609329606), '11': (21460.85714285714, 19961.64506124233), '12': (4704.428571428572, 5889.503237774396), '13': (4712.0, 8056.447923424885), 'PredictionErrorAggregateMean': 88731.68263473053, 'PredictionErrorAggregateSTD': 111020.62507200327, 'PredictionErrorAggregateMax': 467438.0, 'PredictionErrorAggregateNinetyPercentileValue': 261691.0, 'PredictionAvailable': True}, {'id': 14, 'PredictionByIndexList': [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14], '1': (110010.0, 0.0), '2': (161649.23076923078, 158831.0803454915), '3': (189027.84615384616, 181512.1936797577), '4': (134157.0, 116572.92738024554), '5': (112829.07142857143, 108385.9098120259), '6': (103074.85714285714, 113433.01882536995), '7': (122783.5, 103635.16200715855), '8': (106963.85714285714, 97632.79400082825), '9': (92547.35714285714, 79021.73239740278), '10': (49304.78571428572, 47640.10438572373), '11': (27465.714285714286, 20780.9742121028), '12': (13361.857142857143, 11575.453621824952), '13': (13045.42857142857, 12893.40203755552), '14': (4575.285714285715, 6451.067646173788), 'PredictionErrorAggregateMean': 86134.44198895028, 'PredictionErrorAggregateSTD': 112683.48869515813, 'PredictionErrorAggregateMax': 484547.0, 'PredictionErrorAggregateNinetyPercentileValue': 268183.0, 'PredictionAvailable': True}]
[16]:
pprint.pprint(ErrorDictList)
[{'PredictionAvailable': False,
  'PredictionByIndexList': [],
  '_id': ObjectId('6340cc5d6c4c1752704be43f'),
  'id': 0},
 {'1': (64000.0, 0.0),
  'PredictionAvailable': True,
  'PredictionByIndexList': [1],
  'PredictionErrorAggregateMax': 64000.0,
  'PredictionErrorAggregateMean': 64000.0,
  'PredictionErrorAggregateNinetyPercentileValue': 64000.0,
  'PredictionErrorAggregateSTD': 0.0,
  '_id': ObjectId('6340cc5d6c4c1752704be440'),
  'id': 1},
 {'1': (19000.0, 0.0),
  '2': (28933.451603816105, 50660.85366764),
  'PredictionAvailable': True,
  'PredictionByIndexList': [1, 2],
  'PredictionErrorAggregateMax': 179950.0,
  'PredictionErrorAggregateMean': 28223.91934640067,
  'PredictionErrorAggregateNinetyPercentileValue': 79683.87084960938,
  'PredictionErrorAggregateSTD': 48885.00543021303,
  '_id': ObjectId('6340cc5d6c4c1752704be441'),
  'id': 2},
 {'1': (54740.0, 0.0),
  '2': (50172.0, 57097.60624725582),
  '3': (13361.384615384615, 19667.120529680855),
  'PredictionAvailable': True,
  'PredictionByIndexList': [1, 2, 3],
  'PredictionErrorAggregateMax': 162015.0,
  'PredictionErrorAggregateMean': 31942.384615384617,
  'PredictionErrorAggregateNinetyPercentileValue': 90996.0,
  'PredictionErrorAggregateSTD': 45211.399576856995,
  '_id': ObjectId('6340cc5d6c4c1752704be442'),
  'id': 3},
 {'1': (79218.0, 0.0),
  '2': (57217.153846153844, 56666.40619632677),
  '3': (36363.692307692305, 37899.54642794273),
  '4': (2566.0714285714284, 5285.712108590285),
  'PredictionAvailable': True,
  'PredictionByIndexList': [1, 2, 3, 4],
  'PredictionErrorAggregateMax': 190273.0,
  'PredictionErrorAggregateMean': 32480.341463414636,
  'PredictionErrorAggregateNinetyPercentileValue': 91767.0,
  'PredictionErrorAggregateSTD': 45174.852337205055,
  '_id': ObjectId('6340cc5d6c4c1752704be443'),
  'id': 4},
 {'1': (77610.0, 0.0),
  '2': (58775.846153846156, 60303.721150454025),
  '3': (57334.846153846156, 55866.960085609644),
  '4': (13148.785714285714, 25330.119045962914),
  '5': (1838.0, 2780.8551100079167),
  'PredictionAvailable': True,
  'PredictionByIndexList': [1, 2, 3, 4, 5],
  'PredictionErrorAggregateMax': 195397.0,
  'PredictionErrorAggregateMean': 32670.254545454547,
  'PredictionErrorAggregateNinetyPercentileValue': 97793.0,
  'PredictionErrorAggregateSTD': 49427.99599167852,
  '_id': ObjectId('6340cc5d6c4c1752704be444'),
  'id': 5},
 {'1': (18345.0, 0.0),
  '2': (64219.61538461538, 72607.3860234602),
  '3': (57604.230769230766, 77233.63881521478),
  '4': (33766.357142857145, 44077.05280302915),
  '5': (16995.5, 19738.65563069438),
  '6': (19039.714285714286, 27249.541077206555),
  'PredictionAvailable': True,
  'PredictionByIndexList': [1, 2, 3, 4, 5, 6],
  'PredictionErrorAggregateMax': 263638.0,
  'PredictionErrorAggregateMean': 37380.82608695652,
  'PredictionErrorAggregateNinetyPercentileValue': 137282.0,
  'PredictionErrorAggregateSTD': 55805.31367794999,
  '_id': ObjectId('6340cc5d6c4c1752704be445'),
  'id': 6},
 {'1': (28962.0, 0.0),
  '2': (77553.61538461539, 77649.03158991793),
  '3': (79384.07692307692, 88470.03029662865),
  '4': (52124.07142857143, 53552.57920087815),
  '5': (35159.78571428572, 25049.065050070294),
  '6': (34852.71428571428, 31171.264377922937),
  '7': (5970.718122209822, 9771.6742278228),
  'PredictionAvailable': True,
  'PredictionByIndexList': [1, 2, 3, 4, 5, 6, 7],
  'PredictionErrorAggregateMax': 312856.0,
  'PredictionErrorAggregateMean': 46538.00064711973,
  'PredictionErrorAggregateNinetyPercentileValue': 144440.0,
  'PredictionErrorAggregateSTD': 59924.37896078157,
  '_id': ObjectId('6340cc5d6c4c1752704be446'),
  'id': 7},
 {'1': (4605.0, 0.0),
  '2': (77987.0, 80722.64595038228),
  '3': (89947.30769230769, 101657.21154515352),
  '4': (55414.21428571428, 61538.268255473784),
  '5': (32664.571428571428, 32211.310351033724),
  '6': (33399.42857142857, 23900.43415539405),
  '7': (23179.785714285714, 30832.995561755342),
  '8': (5729.285714285715, 12677.838270150067),
  'PredictionAvailable': True,
  'PredictionByIndexList': [1, 2, 3, 4, 5, 6, 7, 8],
  'PredictionErrorAggregateMax': 341786.0,
  'PredictionErrorAggregateMean': 44259.51546391752,
  'PredictionErrorAggregateNinetyPercentileValue': 110985.0,
  'PredictionErrorAggregateSTD': 63076.733730476495,
  '_id': ObjectId('6340cc5d6c4c1752704be447'),
  'id': 8},
 {'1': (30951.0, 0.0),
  '2': (84969.53846153847, 110527.37958784788),
  '3': (107254.61538461539, 139032.60689135452),
  '4': (58697.78571428572, 85479.09660109773),
  '5': (41636.0, 77863.17894963484),
  '6': (39089.13396344866, 81448.34115692912),
  '7': (42396.21428571428, 75251.38614402355),
  '8': (27642.35714285714, 72476.22546700317),
  '9': (20305.428571428572, 69585.38809950824),
  'PredictionAvailable': True,
  'PredictionByIndexList': [1, 2, 3, 4, 5, 6, 7, 8, 9],
  'PredictionErrorAggregateMax': 393423.0,
  'PredictionErrorAggregateMean': 51771.18806746199,
  'PredictionErrorAggregateNinetyPercentileValue': 230406.0,
  'PredictionErrorAggregateSTD': 94589.66505516005,
  '_id': ObjectId('6340cc5d6c4c1752704be448'),
  'id': 9},
 {'1': (134833.0, 0.0),
  '10': (10442.714285714286, 26079.899598373162),
  '2': (139519.6923076923, 129842.54114378137),
  '3': (164483.76923076922, 153266.4025721498),
  '4': (101205.92857142857, 99581.69035051738),
  '5': (75486.71428571429, 96062.68558708986),
  '6': (73354.07142857143, 95933.24916275623),
  '7': (93934.85714285714, 86183.50227099081),
  '8': (76020.21428571429, 80154.41622908566),
  '9': (62319.357142857145, 70784.79727678328),
  'PredictionAvailable': True,
  'PredictionByIndexList': [1, 2, 3, 4, 5, 6, 7, 8, 9, 10],
  'PredictionErrorAggregateMax': 424922.0,
  'PredictionErrorAggregateMean': 87884.576,
  'PredictionErrorAggregateNinetyPercentileValue': 282340.0,
  'PredictionErrorAggregateSTD': 106257.94792321288,
  '_id': ObjectId('6340cc5d6c4c1752704be449'),
  'id': 10},
 {'1': (125948.0, 0.0),
  '10': (26273.32852608817, 42291.74374878493),
  '11': (7298.993739536831, 11368.252256776143),
  '2': (147879.23076923078, 136908.3907689618),
  '3': (172564.46153846153, 160394.3943738565),
  '4': (114298.71428571429, 101211.84655635396),
  '5': (90993.21428571429, 95177.66761106648),
  '6': (83113.28571428571, 99302.70068721953),
  '7': (103861.07142857143, 87669.77645400322),
  '8': (84084.85714285714, 86216.65795031984),
  '9': (72922.64285714286, 68527.68167224432),
  'PredictionAvailable': True,
  'PredictionByIndexList': [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11],
  'PredictionErrorAggregateMax': 448975.0,
  'PredictionErrorAggregateMean': 89579.5792209982,
  'PredictionErrorAggregateNinetyPercentileValue': 270921.0,
  'PredictionErrorAggregateSTD': 107050.72979494999,
  '_id': ObjectId('6340cc5d6c4c1752704be44a'),
  'id': 11},
 {'1': (119957.0, 0.0),
  '10': (34646.57142857143, 49537.75189073234),
  '11': (15963.785714285714, 19396.174951257683),
  '12': (2568.9285714285716, 6171.704597415133),
  '2': (156550.76923076922, 143069.25185654988),
  '3': (177667.6923076923, 167744.46479937393),
  '4': (123312.57142857143, 105108.34604398474),
  '5': (100844.14285714286, 98553.11835383651),
  '6': (91802.42857142857, 103954.45888788738),
  '7': (108939.07142857143, 93417.51645738784),
  '8': (94714.42857142857, 85446.14611614757),
  '9': (83960.85714285714, 67799.86668956252),
  'PredictionAvailable': True,
  'PredictionByIndexList': [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12],
  'PredictionErrorAggregateMax': 457206.0,
  'PredictionErrorAggregateMean': 89276.70588235294,
  'PredictionErrorAggregateNinetyPercentileValue': 264898.0,
  'PredictionErrorAggregateSTD': 108789.05472818512,
  '_id': ObjectId('6340cc5d6c4c1752704be44b'),
  'id': 12},
 {'1': (119606.0, 0.0),
  '10': (41899.142857142855, 47094.1609329606),
  '11': (21460.85714285714, 19961.64506124233),
  '12': (4704.428571428572, 5889.503237774396),
  '13': (4712.0, 8056.447923424885),
  '2': (159088.53846153847, 151402.4957652311),
  '3': (186422.38461538462, 172343.793630209),
  '4': (133102.92857142858, 107375.35929989065),
  '5': (111292.71428571429, 101034.7271758072),
  '6': (100193.14285714286, 107501.91538483472),
  '7': (119081.28571428571, 98411.43136737475),
  '8': (102045.28571428571, 94347.99215020695),
  '9': (90575.57142857143, 74081.8176764373),
  'PredictionAvailable': True,
  'PredictionByIndexList': [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13],
  'PredictionErrorAggregateMax': 467438.0,
  'PredictionErrorAggregateMean': 88731.68263473053,
  'PredictionErrorAggregateNinetyPercentileValue': 261691.0,
  'PredictionErrorAggregateSTD': 111020.62507200327,
  '_id': ObjectId('6340cc5d6c4c1752704be44c'),
  'id': 13},
 {'1': (110010.0, 0.0),
  '10': (49304.78571428572, 47640.10438572373),
  '11': (27465.714285714286, 20780.9742121028),
  '12': (13361.857142857143, 11575.453621824952),
  '13': (13045.42857142857, 12893.40203755552),
  '14': (4575.285714285715, 6451.067646173788),
  '2': (161649.23076923078, 158831.0803454915),
  '3': (189027.84615384616, 181512.1936797577),
  '4': (134157.0, 116572.92738024554),
  '5': (112829.07142857143, 108385.9098120259),
  '6': (103074.85714285714, 113433.01882536995),
  '7': (122783.5, 103635.16200715855),
  '8': (106963.85714285714, 97632.79400082825),
  '9': (92547.35714285714, 79021.73239740278),
  'PredictionAvailable': True,
  'PredictionByIndexList': [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14],
  'PredictionErrorAggregateMax': 484547.0,
  'PredictionErrorAggregateMean': 86134.44198895028,
  'PredictionErrorAggregateNinetyPercentileValue': 268183.0,
  'PredictionErrorAggregateSTD': 112683.48869515813,
  '_id': ObjectId('6340cc5d6c4c1752704be44d'),
  'id': 14}]
[17]:
#SingleTripsInfo=[Trip['SingleTripInfo'] for Trip in con[RouteName]['TripInfo'].find({'BusStopRecordExtracted':True,'Bound':'South','TripStartHour':'18'})]

SingleTripsInfo=[
 '22_12_2017__18_38_34',
 '20_12_2017__18_31_19',
 '08_01_2018__18_37_49',
 '14_02_2018__18_30_22',
 '15_02_2018__18_33_19',
 #'03_04_2018__18_32_45',

 '20_02_2018__18_31_07',
 '21_02_2018__18_28_29',
 '28_03_2018__18_30_02',
 '04_04_2018__18_34_54'
]
[18]:
if UseMongoDB==True:
    TripInfo = [rec for rec in con[RouteName]['TripInfo'].find({'SingleTripInfo':SingleTripsInfo[0]})]
    TripStartHour = TripInfo[0]['TripStartHour']
    Bound = TripInfo[0]['Bound']

    BusStopsList = [BusStop for BusStop in con[RouteName][f'BusStops.{Bound}Bound'].find().sort([('id',1)])]
else:
    TripsInfo = np.load(f'{NpPathDir}/{RouteName}/TripInfo.npy',allow_pickle=True)
    TripInfo = [rec for rec in TripsInfo if rec['SingleTripInfo']==SingleTripsInfo[0]]
    TripStartHour = TripInfo[0]['TripStartHour']
    Bound = TripInfo[0]['Bound']

    BusStopsList = np.load(f'{NpPathDir}/{RouteName}/BusStops.{Bound}Bound.npy',allow_pickle=True)

print('StartHour, Bound, BusStopsCount', TripStartHour, Bound, len (BusStopsList))
StartHour, Bound, BusStopsCount 18 South 15
[19]:
BusStopsCount = len (BusStopsList)
[20]:
ErrorDictList = GetErrorMatrixList(SingleTripsInfo, BusStopsCount, TripStartHour, Bound,
                                   RouteName, ResultPathDir, ResultPathDir_Np, UseMongoDB
                                  )
PredictionFor: 0
PredictionByIndex: 0
[21258.0, 30909.0, 254.0, 234.0, 293.0, 36698.0, 396.0, 417.0]
PredictionFor: 0
PredictionByIndex: 1
[75255.0, 483.0, 401.0, 268.0, 105755.0, 414.0, 266414.0, 152.0]
PredictionFor: 0
PredictionByIndex: 2
[66085.0, 16998.0, 55560.0, 95069.0, 57.0, 477.0, 396685.0, 396.0]
PredictionFor: 0
PredictionByIndex: 3
[75.0, 920.0, 15231.0, 207286.0, 110858.0, 229231.0, 642050.0, 133927.0]
PredictionFor: 0
PredictionByIndex: 4
[263146.0, 468332.0, 172391.0, 148202.0, 479.0, 112.0, 476583.0, 141861.0]
PredictionFor: 0
PredictionByIndex: 5
[273638.0, 440290.0, 152.0, 239712.0, 147997.0, 130372.0, 458989.0, 38508.0]
PredictionFor: 0
PredictionByIndex: 6
[361030.0, 565375.0, 63531.0, 41752.0, 119589.0, 224136.0, 459988.0, 202034.0]
PredictionFor: 0
PredictionByIndex: 7
[348657.0, 713138.0, 184077.0, 192146.0, 271371.0, 140991.0, 504399.0, 66202.0]
PredictionFor: 0
PredictionByIndex: 8
[325941.0, 639080.0, 280341.0, 216059.0, 276567.0, 157120.0, 438127.0, 186219.0]
PredictionFor: 0
PredictionByIndex: 9
[197288.0, 744992.0, 417025.0, 226181.0, 246930.0, 374685.0, 241507.0]
PredictionFor: 0
PredictionByIndex: 10
[266222.0, 664361.0, 300830.0, 361180.0, 440000.0, 142081.0, 287916.0]
PredictionFor: 0
PredictionByIndex: 11
[268109.0, 760038.0, 423003.0, 342643.0, 372505.0, 134380.0, 360469.0, 327313.0]
PredictionFor: 0
PredictionByIndex: 12
[250149.0, 754137.0, 403834.0, 290386.0, 425273.0, 68326.0, 337948.0, 334841.0]
PredictionFor: 0
PredictionByIndex: 13
[743243.0, 444842.0, 319398.0, 394671.0, 353350.0]
PredictionFor: 1
PredictionByIndex: 1
[1607.0, 5438.0, 4622.0, 1551.0, 12162.0, 34125.0, 24333.0, 142564.0, 419.0]
PredictionFor: 1
PredictionByIndex: 2
[193.0, 238.0, 48483.0, 79664.0, 98609.0, 18951.0, 34836.0, 233415.0, 398.0]
PredictionFor: 1
PredictionByIndex: 3
[2143.0, 272.0, 260797.0, 12904.0, 197828.0, 68519.0, 155024.0, 707913.0, 108638.0]
PredictionFor: 1
PredictionByIndex: 4
[341990.0, 398904.0, 96689.0, 165291.0, 140484.0, 27.0, 50178.0, 544616.0, 116321.0]
PredictionFor: 1
PredictionByIndex: 5
[352326.0, 371290.0, 408997.0, 2889.0, 230480.0, 106636.0, 222538.0, 527143.0, 14800.0]
PredictionFor: 1
PredictionByIndex: 6
[438796.0, 495046.0, 334177.0, 102054.0, 34884.0, 78622.0, 316222.0, 528138.0, 176265.0]
PredictionFor: 1
PredictionByIndex: 7
[426460.0, 642397.0, 483176.0, 223218.0, 184750.0, 349315.0, 232325.0, 572492.0, 40918.0]
PredictionFor: 1
PredictionByIndex: 8
[403787.0, 568474.0, 445414.0, 319287.0, 208607.0, 354643.0, 248423.0, 506274.0, 160649.0]
PredictionFor: 1
PredictionByIndex: 9
[275271.0, 674278.0, 659122.0, 455828.0, 218716.0, 339138.0, 442841.0, 215863.0]
PredictionFor: 1
PredictionByIndex: 10
[344166.0, 593693.0, 693083.0, 339696.0, 353622.0, 517965.0, 233349.0, 262240.0]
PredictionFor: 1
PredictionByIndex: 11
[346053.0, 689343.0, 778944.0, 461837.0, 335092.0, 450491.0, 225649.0, 428626.0, 301624.0]
PredictionFor: 1
PredictionByIndex: 12
[328095.0, 683443.0, 763723.0, 442670.0, 282843.0, 503251.0, 159597.0, 406107.0, 309151.0]
PredictionFor: 1
PredictionByIndex: 13
[672549.0, 483677.0, 311853.0, 472652.0, 421509.0]
PredictionFor: 2
PredictionByIndex: 2
[30.0, 463.0, 4427.0, 11121.0, 20855.0, 34005.0, 498.0, 118.0, 147.0]
PredictionFor: 2
PredictionByIndex: 3
[29476.0, 499.0, 172532.0, 69362.0, 98409.0, 40758.0, 172555.0, 738707.0, 88627.0]
PredictionFor: 2
PredictionByIndex: 4
[353620.0, 411783.0, 16266.0, 214533.0, 43965.0, 8862.0, 31794.0, 577957.0, 95932.0]
PredictionFor: 2
PredictionByIndex: 5
[363694.0, 384812.0, 320410.0, 52.0, 131439.0, 80387.0, 200762.0, 560682.0, 190.0]
PredictionFor: 2
PredictionByIndex: 6
[448619.0, 506572.0, 247014.0, 60381.0, 2216.0, 52982.0, 292809.0, 561669.0, 155528.0]
PredictionFor: 2
PredictionByIndex: 7
[436345.0, 653303.0, 395197.0, 179968.0, 88768.0, 392826.0, 209289.0, 605931.0, 20916.0]
PredictionFor: 2
PredictionByIndex: 8
[413746.0, 579583.0, 357570.0, 275742.0, 112533.0, 397358.0, 226339.0, 539802.0, 140213.0]
PredictionFor: 2
PredictionByIndex: 9
[285458.0, 685224.0, 570838.0, 412068.0, 122620.0, 315909.0, 476383.0, 195317.0]
PredictionFor: 2
PredictionByIndex: 10
[354288.0, 604708.0, 604763.0, 296028.0, 257372.0, 561508.0, 211211.0, 241644.0]
PredictionFor: 2
PredictionByIndex: 11
[356174.0, 700319.0, 690582.0, 418123.0, 238852.0, 494067.0, 203515.0, 462171.0, 281008.0]
PredictionFor: 2
PredictionByIndex: 12
[338220.0, 694419.0, 675364.0, 398959.0, 186616.0, 546815.0, 137464.0, 439653.0, 288533.0]
PredictionFor: 2
PredictionByIndex: 13
[683527.0, 439963.0, 215623.0, 516218.0, 455054.0]
PredictionFor: 3
PredictionByIndex: 3
[133.0, 8.0, 17.0, 233.0, 429.0, 480.0, 59.0, 620797.0, 129.0]
PredictionFor: 3
PredictionByIndex: 4
[190331.0, 247428.0, 474.0, 56077.0, 459.0, 149.0, 479.0, 461372.0, 101.0]
PredictionFor: 3
PredictionByIndex: 5
[199636.0, 222362.0, 125924.0, 16.0, 315.0, 8.0, 86786.0, 444282.0, 247.0]
PredictionFor: 3
PredictionByIndex: 6
[280043.0, 338212.0, 56668.0, 79.0, 351.0, 176.0, 181114.0, 445262.0, 292.0]
PredictionFor: 3
PredictionByIndex: 7
[267948.0, 483111.0, 202479.0, 31800.0, 197.0, 216559.0, 97677.0, 489438.0, 184.0]
PredictionFor: 3
PredictionByIndex: 8
[245564.0, 409993.0, 165244.0, 128703.0, 303.0, 221619.0, 114591.0, 423391.0, 250.0]
PredictionFor: 3
PredictionByIndex: 9
[117946.0, 515151.0, 377233.0, 265394.0, 328.0, 203745.0, 359986.0, 29039.0]
PredictionFor: 3
PredictionByIndex: 10
[186585.0, 434839.0, 411053.0, 148630.0, 56635.0, 385325.0, 99309.0, 75224.0]
PredictionFor: 3
PredictionByIndex: 11
[188468.0, 530331.0, 496748.0, 270584.0, 38145.0, 317968.0, 91622.0, 345776.0, 114530.0]
PredictionFor: 3
PredictionByIndex: 12
[170525.0, 524435.0, 481540.0, 251430.0, 53.0, 370687.0, 25577.0, 323261.0, 122051.0]
PredictionFor: 3
PredictionByIndex: 13
[513545.0, 292426.0, 14946.0, 340096.0, 338661.0]
PredictionFor: 4
PredictionByIndex: 4
[131549.0, 245146.0, 10462.0, 344.0, 64.0, 495.0, 66164.0, 290.0, 124.0]
PredictionFor: 4
PredictionByIndex: 5
[139672.0, 222756.0, 457.0, 468.0, 282.0, 351.0, 231809.0, 14983.0, 369.0]
PredictionFor: 4
PredictionByIndex: 6
[213122.0, 330304.0, 85.0, 33558.0, 262.0, 400.0, 321810.0, 14098.0, 91.0]
PredictionFor: 4
PredictionByIndex: 7
[201304.0, 472628.0, 77950.0, 152643.0, 286.0, 318068.0, 240055.0, 41.0, 32.0]
PredictionFor: 4
PredictionByIndex: 8
[179250.0, 400355.0, 41367.0, 249119.0, 204.0, 323996.0, 255758.0, 36011.0, 55.0]
PredictionFor: 4
PredictionByIndex: 9
[52663.0, 504834.0, 251232.0, 384771.0, 277.0, 345265.0, 99245.0, 322.0]
PredictionFor: 4
PredictionByIndex: 10
[121007.0, 424811.0, 284876.0, 269457.0, 18329.0, 486972.0, 240236.0, 272.0]
PredictionFor: 4
PredictionByIndex: 11
[122887.0, 520135.0, 370366.0, 391183.0, 115.0, 419755.0, 232563.0, 113422.0, 37482.0]
PredictionFor: 4
PredictionByIndex: 12
[104960.0, 514244.0, 355174.0, 372044.0, 253.0, 472424.0, 166526.0, 135913.0, 44994.0]
PredictionFor: 4
PredictionByIndex: 13
[503357.0, 413028.0, 266.0, 441844.0, 120519.0]
PredictionFor: 5
PredictionByIndex: 5
[202.0, 242.0, 97547.0, 51826.0, 261.0, 5506.0, 26370.0, 254.0, 3942.0]
PredictionFor: 5
PredictionByIndex: 6
[2993.0, 14335.0, 56197.0, 116122.0, 30313.0, 297.0, 90921.0, 320.0, 1744.0]
PredictionFor: 5
PredictionByIndex: 7
[196.0, 145194.0, 186015.0, 225479.0, 4522.0, 345900.0, 15008.0, 305.0, 19489.0]
PredictionFor: 5
PredictionByIndex: 8
[361.0, 76684.0, 151421.0, 316501.0, 26283.0, 354525.0, 29977.0, 266.0, 150.0]
PredictionFor: 5
PredictionByIndex: 9
[45424.0, 178141.0, 354797.0, 448908.0, 35900.0, 117238.0, 39403.0, 45786.0]
PredictionFor: 5
PredictionByIndex: 10
[164.0, 99399.0, 387907.0, 333999.0, 167292.0, 515233.0, 13622.0, 91000.0]
PredictionFor: 5
PredictionByIndex: 11
[299.0, 193981.0, 472770.0, 456011.0, 148996.0, 448447.0, 5999.0, 53472.0, 129913.0]
PredictionFor: 5
PredictionByIndex: 12
[165.0, 188110.0, 457628.0, 436921.0, 97047.0, 500963.0, 9.0, 75886.0, 137399.0]
PredictionFor: 5
PredictionByIndex: 13
[177238.0, 477865.0, 125994.0, 470417.0, 60512.0]
PredictionFor: 6
PredictionByIndex: 6
[284.0, 14574.0, 399.0, 2396.0, 35048.0, 483.0, 4289.0, 13.0, 22330.0]
PredictionFor: 6
PredictionByIndex: 7
[16.0, 133327.0, 72234.0, 103441.0, 41347.0, 381394.0, 12785.0, 10525.0, 38288.0]
PredictionFor: 6
PredictionByIndex: 8
[419.0, 68790.0, 39983.0, 188710.0, 61703.0, 392981.0, 324.0, 187.0, 18502.0]
PredictionFor: 6
PredictionByIndex: 9
[98401.0, 167056.0, 235718.0, 318654.0, 70989.0, 33957.0, 57264.0, 69388.0]
PredictionFor: 6
PredictionByIndex: 10
[31272.0, 89668.0, 268199.0, 205245.0, 200023.0, 551198.0, 16005.0, 113813.0]
PredictionFor: 6
PredictionByIndex: 11
[29422.0, 183464.0, 352324.0, 325496.0, 181885.0, 484886.0, 23570.0, 71221.0, 152406.0]
PredictionFor: 6
PredictionByIndex: 12
[47224.0, 177617.0, 337241.0, 306457.0, 130137.0, 537234.0, 89544.0, 93553.0, 159865.0]
PredictionFor: 6
PredictionByIndex: 13
[166760.0, 347359.0, 159042.0, 506725.0, 78200.0]
PredictionFor: 7
PredictionByIndex: 7
[154.0, 40632.0, 42855.0, 11865.0, 41163.0, 303320.0, 141.0, 191.0, 47414.0]
PredictionFor: 7
PredictionByIndex: 8
[425.0, 261.0, 14146.0, 97723.0, 59200.0, 316308.0, 372.0, 340.0, 36.85009765625]
PredictionFor: 7
PredictionByIndex: 9
[73086.0, 75772.0, 198325.0, 226810.0, 67941.0, 118.0, 13371.0, 314.0]
PredictionFor: 7
PredictionByIndex: 10
[6000.0, 824.0, 229853.0, 114371.0, 193087.0, 472825.0, 231.0, 35460.0]
PredictionFor: 7
PredictionByIndex: 11
[4176.0, 93205.0, 312862.0, 234114.0, 175208.0, 407217.0, 3225.0, 27128.0, 73534.0]
PredictionFor: 7
PredictionByIndex: 12
[21863.0, 87397.0, 297868.0, 215177.0, 123793.0, 459315.0, 69136.0, 49316.0, 80948.0]
PredictionFor: 7
PredictionByIndex: 13
[76569.0, 255996.0, 152627.0, 428861.0, 34000.0]
PredictionFor: 8
PredictionByIndex: 8
[242.0, 7667.0, 315.0, 16668.0, 159.0, 18352.0, 258.0, 4400.0, 22937.0]
PredictionFor: 8
PredictionByIndex: 9
[71563.0, 21858.0, 104230.0, 109866.0, 125.0, 44829.0, 60769.0, 57102.0]
PredictionFor: 8
PredictionByIndex: 10
[15279.0, 4646.0, 131370.0, 12806.0, 102737.0, 155862.0, 1106.0, 93989.0]
PredictionFor: 8
PredictionByIndex: 11
[13571.0, 44099.0, 209233.0, 124756.0, 86027.0, 92868.0, 8069.0, 73636.0, 129528.0]
PredictionFor: 8
PredictionByIndex: 12
[30764.0, 38480.0, 194649.0, 106278.0, 36112.0, 143684.0, 73695.0, 95182.0, 136723.0]
PredictionFor: 8
PredictionByIndex: 13
[27782.0, 146724.0, 64630.0, 113512.0, 80031.0]
PredictionFor: 9
PredictionByIndex: 9
[25306.0, 10158.0, 63899.0, 35320.0, 221.0, 8314.0, 18223.0, 108.0]
PredictionFor: 9
PredictionByIndex: 10
[292.0, 206.0, 87113.0, 411.0, 62202.0, 234.0, 21286.0]
PredictionFor: 9
PredictionByIndex: 11
[308.0, 36658.0, 160373.0, 54684.0, 46572.0, 4275.0, 30254.0, 54602.0]
PredictionFor: 9
PredictionByIndex: 12
[419.0, 31207.0, 146157.0, 36658.0, 41.0, 69638.0, 51195.0, 61605.0]
PredictionFor: 9
PredictionByIndex: 13
[20625.0, 76736.0, 26268.0, 36200.0]
PredictionFor: 10
PredictionByIndex: 10
[171.0, 3.0, 155.0, 15285.0, 24243.0, 46440.0, 10305.0, 213.0]
PredictionFor: 10
PredictionByIndex: 11
[177.0, 231.0, 41723.0, 2.0, 11065.0, 52.0, 15785.0, 11313.0]
PredictionFor: 10
PredictionByIndex: 12
[470.0, 309.0, 28359.0, 120.0, 320.0, 40394.0, 80551.0, 17865.0]
PredictionFor: 10
PredictionByIndex: 13
[367.0, 20263.0, 244.0, 11205.0]
PredictionFor: 11
PredictionByIndex: 11
[343.0, 19749.0, 16537.0, 37139.0, 216.0, 5396.0, 142.0, 263.0, 119.0]
PredictionFor: 11
PredictionByIndex: 12
[28.0, 15315.0, 4858.0, 21368.0, 20616.0, 6.0, 37523.0, 296.0, 165.0]
PredictionFor: 11
PredictionByIndex: 13
[5440.0, 58796.0, 314.0, 123.0, 308.0]
PredictionFor: 12
PredictionByIndex: 12
[411.0, 235.0, 115.0, 442.0, 15843.0, 16159.0, 47091.0, 422.0, 258.0]
PredictionFor: 12
PredictionByIndex: 13
[358.0, 9343.0, 154.0, 154.0, 7.0]
PredictionFor: 13
PredictionByIndex: 13
[19.0, 16879.0, 5671.0, 6671.0, 408.0]
ErrorDictList [{'id': 0, 'PredictionByIndexList': [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13], '0': (11307.375, 14712.639293626926), '1': (56142.75, 88464.99861491832), '2': (78915.875, 124658.95565144678), '3': (167447.25, 198082.2620388749), '4': (208888.25, 172643.02133140946), '5': (216207.25, 159406.72984126955), '6': (254679.375, 178123.36641492147), '7': (302622.625, 200190.54996736077), '8': (314931.75, 147599.9984576135), '9': (349801.14285714284, 178151.76465941983), '10': (351798.5714285714, 152852.1052276697), '11': (373557.5, 167109.23586385045), '12': (358111.75, 181866.63190628868), '13': (451100.8, 151968.02713386787), 'PredictionErrorAggregateMean': 242142.01869158878, 'PredictionErrorAggregateSTD': 201849.45645106016, 'PredictionErrorAggregateMax': 760038.0, 'PredictionErrorAggregateNinetyPercentileValue': 476583.0, 'PredictionAvailable': True}, {'id': 1, 'PredictionByIndexList': [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13], '1': (25202.333333333332, 42906.48583968525), '2': (57198.555555555555, 70735.1225553019), '3': (168226.44444444444, 209308.72134991366), '4': (206055.55555555556, 170949.03727466793), '5': (248566.55555555556, 171698.37397412365), '6': (278244.8888888889, 176482.15431812202), '7': (350561.22222222225, 185992.42371474154), '8': (357284.22222222225, 129443.38096186882), '9': (410132.125, 170490.21206761218), '10': (417226.75, 154358.17815048705), '11': (446406.55555555556, 170726.50336925243), '12': (430986.6666666667, 183016.3385578214), '13': (472448.0, 117091.48389528591), 'PredictionErrorAggregateMean': 289186.5585585586, 'PredictionErrorAggregateSTD': 212210.33776190388, 'PredictionErrorAggregateMax': 778944.0, 'PredictionErrorAggregateNinetyPercentileValue': 572492.0, 'PredictionAvailable': True}, {'id': 2, 'PredictionByIndexList': [2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13], '2': (7962.666666666667, 11374.475724181752), '3': (156769.44444444444, 213156.4589920387), '4': (194968.0, 195802.67910322372), '5': (226936.44444444444, 181941.0239574664), '6': (258643.33333333334, 196830.0882058206), '7': (331393.6666666667, 208422.3338810993), '8': (338098.44444444444, 154570.88355768195), '9': (382977.125, 177913.63300801144), '10': (391440.25, 159409.98647571457), '11': (427201.22222222225, 170511.4419098403), '12': (411782.55555555556, 187108.42194781738), '13': (462077.0, 150498.68838099553), 'PredictionErrorAggregateMean': 291073.7843137255, 'PredictionErrorAggregateSTD': 216803.38030356335, 'PredictionErrorAggregateMax': 738707.0, 'PredictionErrorAggregateNinetyPercentileValue': 604708.0, 'PredictionAvailable': True}, {'id': 3, 'PredictionByIndexList': [3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13], '3': (69142.77777777778, 195039.2862515298), '4': (106318.88888888889, 153377.7468455972), '5': (119952.88888888889, 141647.62664791688), '6': (144688.55555555556, 162846.37387571495), '7': (198821.44444444444, 178705.1820569977), '8': (189962.0, 144914.5719710601), '9': (233602.75, 168602.2987341439), '10': (224700.0, 149263.7976712706), '11': (266019.1111111111, 164479.43804854585), '12': (252173.22222222222, 177746.32789629517), '13': (299934.8, 161255.67047319608), 'PredictionErrorAggregateMean': 185911.8924731183, 'PredictionErrorAggregateSTD': 177848.03304104626, 'PredictionErrorAggregateMax': 620797.0, 'PredictionErrorAggregateNinetyPercentileValue': 461372.0, 'PredictionAvailable': True}, {'id': 4, 'PredictionByIndexList': [4, 5, 6, 7, 8, 9, 10, 11, 12, 13], '4': (50515.333333333336, 80913.60679006824), '5': (67905.22222222222, 95212.68578150915), '6': (101525.55555555556, 136072.52422481764), '7': (162556.33333333334, 154290.23924553505), '8': (165123.88888888888, 142390.50552808362), '9': (204826.125, 181047.2100699411), '10': (230745.0, 165118.72262859836), '11': (245323.11111111112, 175984.5824872448), '12': (240725.77777777778, 179474.82418110766), '13': (295802.8, 198098.42818498082), 'PredictionErrorAggregateMean': 169841.19047619047, 'PredictionErrorAggregateSTD': 170038.93574333386, 'PredictionErrorAggregateMax': 520135.0, 'PredictionErrorAggregateNinetyPercentileValue': 424811.0, 'PredictionAvailable': True}, {'id': 5, 'PredictionByIndexList': [5, 6, 7, 8, 9, 10, 11, 12, 13], '5': (20683.333333333332, 31785.065133731532), '6': (34804.666666666664, 41019.408585042605), '7': (104678.66666666667, 119339.6176725157), '8': (106240.88888888889, 131095.85791866994), '9': (158199.625, 149859.2678890244), '10': (201077.0, 176907.42556207188), '11': (212209.77777777778, 184651.76380947628), '12': (210458.66666666666, 189177.25680488715), '13': (262405.2, 176812.9893434303), 'PredictionErrorAggregateMean': 138505.64, 'PredictionErrorAggregateSTD': 162088.48456425604, 'PredictionErrorAggregateMax': 515233.0, 'PredictionErrorAggregateNinetyPercentileValue': 448908.0, 'PredictionAvailable': True}, {'id': 6, 'PredictionByIndexList': [6, 7, 8, 9, 10, 11, 12, 13], '6': (8868.444444444445, 11814.109127189227), '7': (88150.77777777778, 111887.8427789561), '8': (85733.22222222222, 122190.40971439959), '9': (131428.375, 94069.68517133655), '10': (184427.875, 161246.4604049012), '11': (200519.33333333334, 148990.9258258517), '12': (208763.55555555556, 147974.62625442175), '13': (251617.2, 154978.01082140653), 'PredictionErrorAggregateMean': 138079.60606060605, 'PredictionErrorAggregateSTD': 145822.9226997364, 'PredictionErrorAggregateMax': 551198.0, 'PredictionErrorAggregateNinetyPercentileValue': 352324.0, 'PredictionAvailable': True}, {'id': 7, 'PredictionByIndexList': [7, 8, 9, 10, 11, 12, 13], '7': (54192.77777777778, 90149.35548395694), '8': (54312.42778862847, 98181.93468492554), '9': (81967.125, 81320.76925736362), '10': (131581.375, 153925.3371792129), '11': (147852.11111111112, 136353.9074609765), '12': (156090.33333333334, 134958.59151771126), '13': (189610.6, 141427.4542408227), 'PredictionErrorAggregateMean': 111727.54122978344, 'PredictionErrorAggregateSTD': 129986.38920256708, 'PredictionErrorAggregateMax': 472825.0, 'PredictionErrorAggregateNinetyPercentileValue': 312862.0, 'PredictionAvailable': True}, {'id': 8, 'PredictionByIndexList': [8, 9, 10, 11, 12, 13], '8': (7888.666666666667, 8557.239066687598), '9': (58792.75, 35078.360493864304), '10': (64724.375, 58998.04605861431), '11': (86865.22222222222, 59489.75857289832), '12': (95063.0, 53135.60026322591), '13': (86535.8, 40803.23589324749), 'PredictionErrorAggregateMean': 65191.0, 'PredictionErrorAggregateSTD': 55594.08145207545, 'PredictionErrorAggregateMax': 209233.0, 'PredictionErrorAggregateNinetyPercentileValue': 143684.0, 'PredictionAvailable': True}, {'id': 9, 'PredictionByIndexList': [9, 10, 11, 12, 13], '9': (20193.625, 20041.095609631102), '10': (24534.85714285714, 33160.850930097724), '11': (48465.75, 46564.76827696558), '12': (49615.0, 43663.630457739084), '13': (39957.25, 21954.070435513775), 'PredictionErrorAggregateMean': 36507.65714285714, 'PredictionErrorAggregateSTD': 38223.21964830343, 'PredictionErrorAggregateMax': 160373.0, 'PredictionErrorAggregateNinetyPercentileValue': 76736.0, 'PredictionAvailable': True}, {'id': 10, 'PredictionByIndexList': [10, 11, 12, 13], '10': (12101.875, 15462.359598695633), '11': (10043.5, 13386.118780288782), '12': (21048.5, 26691.872138349532), '13': (8019.75, 8352.69206229345), 'PredictionErrorAggregateMean': 13486.785714285714, 'PredictionErrorAggregateSTD': 18909.63826683771, 'PredictionErrorAggregateMax': 80551.0, 'PredictionErrorAggregateNinetyPercentileValue': 41723.0, 'PredictionAvailable': True}, {'id': 11, 'PredictionByIndexList': [11, 12, 13], '11': (8878.222222222223, 12305.282684709737), '12': (11130.555555555555, 12617.659829788046), '13': (12996.2, 22988.108807816272), 'PredictionErrorAggregateMean': 10654.782608695652, 'PredictionErrorAggregateSTD': 15457.86354537792, 'PredictionErrorAggregateMax': 58796.0, 'PredictionErrorAggregateNinetyPercentileValue': 37139.0, 'PredictionAvailable': True}, {'id': 12, 'PredictionByIndexList': [12, 13], '12': (8997.333333333334, 14913.77264291113), '13': (2003.2, 3671.6002723608135), 'PredictionErrorAggregateMean': 6499.428571428572, 'PredictionErrorAggregateSTD': 12610.723564345011, 'PredictionErrorAggregateMax': 47091.0, 'PredictionErrorAggregateNinetyPercentileValue': 16159.0, 'PredictionAvailable': True}, {'id': 13, 'PredictionByIndexList': [13], '13': (5929.6, 6098.018812696465), 'PredictionErrorAggregateMean': 5929.6, 'PredictionErrorAggregateSTD': 6098.018812696465, 'PredictionErrorAggregateMax': 16879.0, 'PredictionErrorAggregateNinetyPercentileValue': 16879.0, 'PredictionAvailable': True}, {'id': 14, 'PredictionByIndexList': [], 'PredictionAvailable': False}]
[21]:
pprint.pprint(ErrorDictList)
[{'0': (11307.375, 14712.639293626926),
  '1': (56142.75, 88464.99861491832),
  '10': (351798.5714285714, 152852.1052276697),
  '11': (373557.5, 167109.23586385045),
  '12': (358111.75, 181866.63190628868),
  '13': (451100.8, 151968.02713386787),
  '2': (78915.875, 124658.95565144678),
  '3': (167447.25, 198082.2620388749),
  '4': (208888.25, 172643.02133140946),
  '5': (216207.25, 159406.72984126955),
  '6': (254679.375, 178123.36641492147),
  '7': (302622.625, 200190.54996736077),
  '8': (314931.75, 147599.9984576135),
  '9': (349801.14285714284, 178151.76465941983),
  'PredictionAvailable': True,
  'PredictionByIndexList': [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13],
  'PredictionErrorAggregateMax': 760038.0,
  'PredictionErrorAggregateMean': 242142.01869158878,
  'PredictionErrorAggregateNinetyPercentileValue': 476583.0,
  'PredictionErrorAggregateSTD': 201849.45645106016,
  '_id': ObjectId('6340cc616c4c1752704be44e'),
  'id': 0},
 {'1': (25202.333333333332, 42906.48583968525),
  '10': (417226.75, 154358.17815048705),
  '11': (446406.55555555556, 170726.50336925243),
  '12': (430986.6666666667, 183016.3385578214),
  '13': (472448.0, 117091.48389528591),
  '2': (57198.555555555555, 70735.1225553019),
  '3': (168226.44444444444, 209308.72134991366),
  '4': (206055.55555555556, 170949.03727466793),
  '5': (248566.55555555556, 171698.37397412365),
  '6': (278244.8888888889, 176482.15431812202),
  '7': (350561.22222222225, 185992.42371474154),
  '8': (357284.22222222225, 129443.38096186882),
  '9': (410132.125, 170490.21206761218),
  'PredictionAvailable': True,
  'PredictionByIndexList': [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13],
  'PredictionErrorAggregateMax': 778944.0,
  'PredictionErrorAggregateMean': 289186.5585585586,
  'PredictionErrorAggregateNinetyPercentileValue': 572492.0,
  'PredictionErrorAggregateSTD': 212210.33776190388,
  '_id': ObjectId('6340cc616c4c1752704be44f'),
  'id': 1},
 {'10': (391440.25, 159409.98647571457),
  '11': (427201.22222222225, 170511.4419098403),
  '12': (411782.55555555556, 187108.42194781738),
  '13': (462077.0, 150498.68838099553),
  '2': (7962.666666666667, 11374.475724181752),
  '3': (156769.44444444444, 213156.4589920387),
  '4': (194968.0, 195802.67910322372),
  '5': (226936.44444444444, 181941.0239574664),
  '6': (258643.33333333334, 196830.0882058206),
  '7': (331393.6666666667, 208422.3338810993),
  '8': (338098.44444444444, 154570.88355768195),
  '9': (382977.125, 177913.63300801144),
  'PredictionAvailable': True,
  'PredictionByIndexList': [2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13],
  'PredictionErrorAggregateMax': 738707.0,
  'PredictionErrorAggregateMean': 291073.7843137255,
  'PredictionErrorAggregateNinetyPercentileValue': 604708.0,
  'PredictionErrorAggregateSTD': 216803.38030356335,
  '_id': ObjectId('6340cc616c4c1752704be450'),
  'id': 2},
 {'10': (224700.0, 149263.7976712706),
  '11': (266019.1111111111, 164479.43804854585),
  '12': (252173.22222222222, 177746.32789629517),
  '13': (299934.8, 161255.67047319608),
  '3': (69142.77777777778, 195039.2862515298),
  '4': (106318.88888888889, 153377.7468455972),
  '5': (119952.88888888889, 141647.62664791688),
  '6': (144688.55555555556, 162846.37387571495),
  '7': (198821.44444444444, 178705.1820569977),
  '8': (189962.0, 144914.5719710601),
  '9': (233602.75, 168602.2987341439),
  'PredictionAvailable': True,
  'PredictionByIndexList': [3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13],
  'PredictionErrorAggregateMax': 620797.0,
  'PredictionErrorAggregateMean': 185911.8924731183,
  'PredictionErrorAggregateNinetyPercentileValue': 461372.0,
  'PredictionErrorAggregateSTD': 177848.03304104626,
  '_id': ObjectId('6340cc616c4c1752704be451'),
  'id': 3},
 {'10': (230745.0, 165118.72262859836),
  '11': (245323.11111111112, 175984.5824872448),
  '12': (240725.77777777778, 179474.82418110766),
  '13': (295802.8, 198098.42818498082),
  '4': (50515.333333333336, 80913.60679006824),
  '5': (67905.22222222222, 95212.68578150915),
  '6': (101525.55555555556, 136072.52422481764),
  '7': (162556.33333333334, 154290.23924553505),
  '8': (165123.88888888888, 142390.50552808362),
  '9': (204826.125, 181047.2100699411),
  'PredictionAvailable': True,
  'PredictionByIndexList': [4, 5, 6, 7, 8, 9, 10, 11, 12, 13],
  'PredictionErrorAggregateMax': 520135.0,
  'PredictionErrorAggregateMean': 169841.19047619047,
  'PredictionErrorAggregateNinetyPercentileValue': 424811.0,
  'PredictionErrorAggregateSTD': 170038.93574333386,
  '_id': ObjectId('6340cc616c4c1752704be452'),
  'id': 4},
 {'10': (201077.0, 176907.42556207188),
  '11': (212209.77777777778, 184651.76380947628),
  '12': (210458.66666666666, 189177.25680488715),
  '13': (262405.2, 176812.9893434303),
  '5': (20683.333333333332, 31785.065133731532),
  '6': (34804.666666666664, 41019.408585042605),
  '7': (104678.66666666667, 119339.6176725157),
  '8': (106240.88888888889, 131095.85791866994),
  '9': (158199.625, 149859.2678890244),
  'PredictionAvailable': True,
  'PredictionByIndexList': [5, 6, 7, 8, 9, 10, 11, 12, 13],
  'PredictionErrorAggregateMax': 515233.0,
  'PredictionErrorAggregateMean': 138505.64,
  'PredictionErrorAggregateNinetyPercentileValue': 448908.0,
  'PredictionErrorAggregateSTD': 162088.48456425604,
  '_id': ObjectId('6340cc616c4c1752704be453'),
  'id': 5},
 {'10': (184427.875, 161246.4604049012),
  '11': (200519.33333333334, 148990.9258258517),
  '12': (208763.55555555556, 147974.62625442175),
  '13': (251617.2, 154978.01082140653),
  '6': (8868.444444444445, 11814.109127189227),
  '7': (88150.77777777778, 111887.8427789561),
  '8': (85733.22222222222, 122190.40971439959),
  '9': (131428.375, 94069.68517133655),
  'PredictionAvailable': True,
  'PredictionByIndexList': [6, 7, 8, 9, 10, 11, 12, 13],
  'PredictionErrorAggregateMax': 551198.0,
  'PredictionErrorAggregateMean': 138079.60606060605,
  'PredictionErrorAggregateNinetyPercentileValue': 352324.0,
  'PredictionErrorAggregateSTD': 145822.9226997364,
  '_id': ObjectId('6340cc616c4c1752704be454'),
  'id': 6},
 {'10': (131581.375, 153925.3371792129),
  '11': (147852.11111111112, 136353.9074609765),
  '12': (156090.33333333334, 134958.59151771126),
  '13': (189610.6, 141427.4542408227),
  '7': (54192.77777777778, 90149.35548395694),
  '8': (54312.42778862847, 98181.93468492554),
  '9': (81967.125, 81320.76925736362),
  'PredictionAvailable': True,
  'PredictionByIndexList': [7, 8, 9, 10, 11, 12, 13],
  'PredictionErrorAggregateMax': 472825.0,
  'PredictionErrorAggregateMean': 111727.54122978344,
  'PredictionErrorAggregateNinetyPercentileValue': 312862.0,
  'PredictionErrorAggregateSTD': 129986.38920256708,
  '_id': ObjectId('6340cc616c4c1752704be455'),
  'id': 7},
 {'10': (64724.375, 58998.04605861431),
  '11': (86865.22222222222, 59489.75857289832),
  '12': (95063.0, 53135.60026322591),
  '13': (86535.8, 40803.23589324749),
  '8': (7888.666666666667, 8557.239066687598),
  '9': (58792.75, 35078.360493864304),
  'PredictionAvailable': True,
  'PredictionByIndexList': [8, 9, 10, 11, 12, 13],
  'PredictionErrorAggregateMax': 209233.0,
  'PredictionErrorAggregateMean': 65191.0,
  'PredictionErrorAggregateNinetyPercentileValue': 143684.0,
  'PredictionErrorAggregateSTD': 55594.08145207545,
  '_id': ObjectId('6340cc616c4c1752704be456'),
  'id': 8},
 {'10': (24534.85714285714, 33160.850930097724),
  '11': (48465.75, 46564.76827696558),
  '12': (49615.0, 43663.630457739084),
  '13': (39957.25, 21954.070435513775),
  '9': (20193.625, 20041.095609631102),
  'PredictionAvailable': True,
  'PredictionByIndexList': [9, 10, 11, 12, 13],
  'PredictionErrorAggregateMax': 160373.0,
  'PredictionErrorAggregateMean': 36507.65714285714,
  'PredictionErrorAggregateNinetyPercentileValue': 76736.0,
  'PredictionErrorAggregateSTD': 38223.21964830343,
  '_id': ObjectId('6340cc616c4c1752704be457'),
  'id': 9},
 {'10': (12101.875, 15462.359598695633),
  '11': (10043.5, 13386.118780288782),
  '12': (21048.5, 26691.872138349532),
  '13': (8019.75, 8352.69206229345),
  'PredictionAvailable': True,
  'PredictionByIndexList': [10, 11, 12, 13],
  'PredictionErrorAggregateMax': 80551.0,
  'PredictionErrorAggregateMean': 13486.785714285714,
  'PredictionErrorAggregateNinetyPercentileValue': 41723.0,
  'PredictionErrorAggregateSTD': 18909.63826683771,
  '_id': ObjectId('6340cc616c4c1752704be458'),
  'id': 10},
 {'11': (8878.222222222223, 12305.282684709737),
  '12': (11130.555555555555, 12617.659829788046),
  '13': (12996.2, 22988.108807816272),
  'PredictionAvailable': True,
  'PredictionByIndexList': [11, 12, 13],
  'PredictionErrorAggregateMax': 58796.0,
  'PredictionErrorAggregateMean': 10654.782608695652,
  'PredictionErrorAggregateNinetyPercentileValue': 37139.0,
  'PredictionErrorAggregateSTD': 15457.86354537792,
  '_id': ObjectId('6340cc616c4c1752704be459'),
  'id': 11},
 {'12': (8997.333333333334, 14913.77264291113),
  '13': (2003.2, 3671.6002723608135),
  'PredictionAvailable': True,
  'PredictionByIndexList': [12, 13],
  'PredictionErrorAggregateMax': 47091.0,
  'PredictionErrorAggregateMean': 6499.428571428572,
  'PredictionErrorAggregateNinetyPercentileValue': 16159.0,
  'PredictionErrorAggregateSTD': 12610.723564345011,
  '_id': ObjectId('6340cc616c4c1752704be45a'),
  'id': 12},
 {'13': (5929.6, 6098.018812696465),
  'PredictionAvailable': True,
  'PredictionByIndexList': [13],
  'PredictionErrorAggregateMax': 16879.0,
  'PredictionErrorAggregateMean': 5929.6,
  'PredictionErrorAggregateNinetyPercentileValue': 16879.0,
  'PredictionErrorAggregateSTD': 6098.018812696465,
  '_id': ObjectId('6340cc616c4c1752704be45b'),
  'id': 13},
 {'PredictionAvailable': False,
  'PredictionByIndexList': [],
  '_id': ObjectId('6340cc616c4c1752704be45c'),
  'id': 14}]