# ---
# jupyter:
#   jupytext:
#     text_representation:
#       extension: .py
#       format_name: light
#       format_version: '1.5'
#       jupytext_version: 1.14.4
#   kernelspec:
#     display_name: Python 3
#     name: python3
# ---

# + colab={"base_uri": "https://localhost:8080/", "height": 842} id="NfYoUtAogAGk" outputId="3e55f985-3315-4df9-c876-c164347ba773"

import numpy as np
import pandas as pd
import matplotlib.pyplot as plt
 
data_mAP_total ={
    '0.0':[0.5431, 0.5505, 0.5363, 0.5746, 0.5641, 0.5642, 0.5275, 0.577, 0.5317, 0.5718, 0.5589, 0.5861, 0.5504, 0.5719, 0.5585, 0.548, 0.5464, 0.5443, 0.5516, 0.5509],
    '0.1':[0.5861, 0.5752, 0.544, 0.5701, 0.5561, 0.5648, 0.5659, 0.5472, 0.5479, 0.5339, 0.5657, 0.5381, 0.5623, 0.5581, 0.5689, 0.5375, 0.5594, 0.5603, 0.5674, 0.5843],
    '0.167':[0.5702, 0.5633, 0.5505, 0.5607, 0.5892, 0.577, 0.5519, 0.5399, 0.5611, 0.5505, 0.5585, 0.5453, 0.5784, 0.5556, 0.5549, 0.5799, 0.5582, 0.5504, 0.5736, 0.5808],
    '0.25':[0.5653, 0.5495, 0.5647, 0.5356, 0.571, 0.5715, 0.5661, 0.5676, 0.5469, 0.5675, 0.5589, 0.5622, 0.5535, 0.5644, 0.5673, 0.5529, 0.581, 0.5666, 0.569, 0.5903],
    '0.5':[0.5531, 0.5562, 0.5765, 0.5714, 0.5858, 0.5576, 0.5578, 0.5657, 0.5545, 0.5552, 0.5599, 0.5701, 0.5834, 0.5533, 0.555, 0.5837, 0.5503, 0.5612, 0.5787, 0.5599],
    '0.8':[0.5368, 0.5598, 0.5461, 0.562, 0.5524, 0.5672, 0.5485, 0.5733, 0.5638, 0.5572, 0.5368, 0.5598, 0.5461, 0.562, 0.5524, 0.5672, 0.5485, 0.5733, 0.5638, 0.5572], 
    '1.0':[0.5732, 0.5643, 0.5668, 0.5449, 0.5577, 0.5447, 0.5658, 0.5823, 0.5458, 0.5675, 0.5774, 0.5509, 0.5569, 0.561, 0.5472, 0.5792, 0.5729, 0.5751, 0.5613, 0.5485]
                 
 } 
df = pd.DataFrame(data_mAP_total)
df.plot.box(title="The total mAP")
plt.grid(linestyle="--", alpha=0.3)
plt.show()

x = [0.0, 0.1, 0.167, 0.25, 0.5, 0.8, 1]
y_totalmAP = [np.mean(data_mAP_total['0.0']), np.mean(data_mAP_total['0.1']), np.mean(data_mAP_total['0.167']), np.mean(data_mAP_total['0.25']), np.mean(data_mAP_total['0.5']), np.mean(data_mAP_total['0.8']), np.mean(data_mAP_total['1.0'])]

l1 = plt.plot(x, y_totalmAP, 'b.-', label='mean mAP')
plt.title('The mean total mAP')
plt.xlabel('')
plt.ylabel('mAP')
plt.legend()
plt.show()
print(y_totalmAP)

y_totalstd = [np.std(data_mAP_total['0.0']), np.std(data_mAP_total['0.1']), np.std(data_mAP_total['0.167']), np.std(data_mAP_total['0.25']), np.std(data_mAP_total['0.5']), np.std(data_mAP_total['0.8']), np.std(data_mAP_total['1.0'])]
l1_std = plt.plot(x, y_totalstd, 'b.-', label='std mAP')
plt.title('The std of total mAP')
plt.xlabel('')
plt.ylabel('std')
plt.legend()
plt.show()
print(y_totalstd)

# + colab={"base_uri": "https://localhost:8080/", "height": 842} id="umfptZGR7NIq" outputId="7382fe3d-1927-4647-ca5d-c4a6012e2845"
data_human ={
    '0.0':[0.5226,	0.5295,	0.5174,	0.522,	0.5323,	0.5004,	0.4931,	0.5076,	0.5022,	0.4825],
    '0.1':[0.5203,	0.5107,	0.52,	0.5252,	0.5012,	0.4892,	0.5219,	0.5179,	0.5193,	0.5335],
    '0.167':[0.5082,	0.508,	0.5156,	0.4963,	0.4993,	0.529,	0.5178,	0.4973,	0.5271,	0.5331],
    '0.25':[0.5178,	0.5066,	0.5169,	0.5112,	0.5324,	0.5093,	0.5226,	0.5078,	0.5362,	0.5602],
    '0.5':[0.5247,	0.5261,	0.5362,	0.4909,	0.4942,	0.5309,	0.5061,	0.5104,	0.5195,	0.5323],
    '0.8':[0.5002,	0.5092,	0.5127,	0.5177,	0.5033,	0.5256,	0.5122,	0.5394,	0.5108,	0.5167], 
    '1.0':[0.5309,	0.4964,	0.5181,	0.5218,	0.5096,	0.5391,	0.5424,	0.5304,	0.5338,	0.5014]
                 
 } 
df = pd.DataFrame(data_human)
df.plot.box(title="The human class mAP")
plt.grid(linestyle="--", alpha=0.3)
plt.show()

x = [0.0, 0.1, 0.167, 0.25, 0.5, 0.8, 1]
y_humanmAP = [np.mean(data_human['0.0']), np.mean(data_human['0.1']), np.mean(data_human['0.167']), np.mean(data_human['0.25']), np.mean(data_human['0.5']), np.mean(data_human['0.8']), np.mean(data_human['1.0'])]

l2 = plt.plot(x, y_humanmAP, 'b.-', label='human mAP')
plt.title('The mean human mAP')
plt.xlabel('')
plt.ylabel('mAP')
plt.legend()
plt.show()
print(y_humanmAP)

y_humanstd = [np.std(data_human['0.0']), np.std(data_human['0.1']), np.std(data_human['0.167']), np.std(data_human['0.25']), np.std(data_human['0.5']), np.std(data_human['0.8']), np.std(data_human['1.0'])]
l2_std = plt.plot(x, y_humanstd, 'b.-', label='std human mAP')
plt.title('The std of human mAP')
plt.xlabel('')
plt.ylabel('std')
plt.legend()
plt.show()
print(y_humanstd)

# + colab={"base_uri": "https://localhost:8080/", "height": 842} id="p8u7TpSz73z7" outputId="3e86fde9-16eb-4f98-affd-1a263c084d31"
data_bicycle ={
    '0.0':[0.5951,	0.6431,	0.5778,	0.6744,	0.6081,	0.5832,	0.6087,	0.5414,	0.5738,	0.6254],
    '0.1':[0.6129,	0.5835,	0.6093,	0.5954,	0.6744,	0.5728,	0.6047,	0.6246,	0.6013,	0.695],
    '0.167':[0.5966,	0.5803,	0.6385,	0.6373,	0.6069,	0.6803,	0.5643,	0.5864,	0.6159,	0.5653],
    '0.25':[0.6214,	0.6233,	0.6082,	0.6375,	0.5723,	0.6048,	0.639,	0.6664,	0.5389,	0.5792],
    '0.5':[0.5832,	0.6052,	0.6371,	0.5603,	0.5798,	0.6012,	0.6283,	0.6321,	0.6577,	0.6054],
    '0.8':[0.5743,	0.6905,	0.5869,	0.6326,	0.5915,	0.658,	0.6351,	0.5874,	0.6693,	0.5337], 
    '1.0':[0.6237,	0.602,	0.6155,	0.6871,	0.5657,	0.5908,	0.5456,	0.5906,	0.6494,	0.5822]
                 
 } 
df = pd.DataFrame(data_bicycle)
df.plot.box(title="The bicycle class mAP")
plt.grid(linestyle="--", alpha=0.3)
plt.show()

x = [0.0, 0.1, 0.167, 0.25, 0.5, 0.8, 1]
y_bicyclemAP = [np.mean(data_bicycle['0.0']), np.mean(data_bicycle['0.1']), np.mean(data_bicycle['0.167']), np.mean(data_bicycle['0.25']), np.mean(data_bicycle['0.5']), np.mean(data_bicycle['0.8']), np.mean(data_bicycle['1.0'])]

l3 = plt.plot(x, y_bicyclemAP, 'b.-', label='bicycle mAP')
plt.title('The mean bicycle mAP')
plt.xlabel('')
plt.ylabel('mAP')
plt.legend()
plt.show()
print(y_bicyclemAP)

y_bicyclestd = [np.std(data_bicycle['0.0']), np.std(data_bicycle['0.1']), np.std(data_bicycle['0.167']), np.std(data_bicycle['0.25']), np.std(data_bicycle['0.5']), np.std(data_bicycle['0.8']), np.std(data_bicycle['1.0'])]
l3_std = plt.plot(x, y_bicyclestd, 'b.-', label='std bicycle mAP')
plt.title('The std of bicycle mAP')
plt.xlabel('')
plt.ylabel('std')
plt.legend()
plt.show()
print(y_bicyclestd)

# + colab={"base_uri": "https://localhost:8080/", "height": 842} id="w7jOqnh70Cis" outputId="bb3c1f4d-8c00-42ca-89cf-e8503e61ca22"
data_bus ={
    '0.0':[0.1875,	0.1667,	0,	0.125,	0.0625,	0.2083,	0.0417,	0.125,	0.125,	0.25],
    '0.1':[0,	0.0625,	0.1667,	0.0625,	0.0625,	0,	0.0625,	0.125,	0.0625,	0.2083],
    '0.167':[0.255,	0.0625,	0.125,	0,	0.125,	0,	0.25,	0,	0.125,	0.25],
    '0.25':[0.1667,	0.125,	0.25,	0.25,	0.0625,	0.0625,	0.1667,	0.2083,	0.0625,	0],
    '0.5':[0,	0.0625,	0.1667,	0.25,	0.125,	0.0625,	0.25,	0.2833,	0.125,	0],
    '0.8':[0.125,	0,	0.125,	0.1667,	0.2083,	0.0625,	0.2812,	0,	0.2083,	0.0208], 
    '1.0':[0,	0.1875,	0,	0.2083,	0.0625,	0.125,	0.2083,	0,	0,	0]
                 
 } 
df = pd.DataFrame(data_bus)
df.plot.box(title="The bus class mAP")
plt.grid(linestyle="--", alpha=0.3)
plt.show()

x = [0.0, 0.1, 0.167, 0.25, 0.5, 0.8, 1]
y_busmAP = [np.mean(data_bus['0.0']), np.mean(data_bus['0.1']), np.mean(data_bus['0.167']), np.mean(data_bus['0.25']), np.mean(data_bus['0.5']), np.mean(data_bus['0.8']), np.mean(data_bus['1.0'])]

l4 = plt.plot(x, y_busmAP, 'b.-', label='bus mAP')
plt.title('The mean bus mAP')
plt.xlabel('')
plt.ylabel('mAP')
plt.legend()
plt.show()
print(y_busmAP)

y_busstd = [np.std(data_bus['0.0']), np.std(data_bus['0.1']), np.std(data_bus['0.167']), np.std(data_bus['0.25']), np.std(data_bus['0.5']), np.std(data_bus['0.8']), np.std(data_bus['1.0'])]
l4_std = plt.plot(x, y_busstd, 'b.-', label='std bus mAP')
plt.title('The std of bus mAP')
plt.xlabel('')
plt.ylabel('std')
plt.legend()
plt.show()
print(y_busstd)

# + colab={"base_uri": "https://localhost:8080/", "height": 842} id="6iY5P_im1Mrj" outputId="0a5e367a-0922-43ac-a66b-d7476c8abe49"
data_car ={
    '0.0':[0.6355,	0.689,	0.6538,	0.7099,	0.6471,	0.6441,	0.6616,	0.6547,	0.6708,	0.6723],
    '0.1':[0.6732,	0.6221,	0.6671,	0.6473,	0.69,	0.6461,	0.638,	0.6751,	0.6819,	0.6633],
    '0.167':[0.6511,	0.6292,	0.7055,	0.6795,	0.6623,	0.69984,	0.6388,	0.6624,	0.6745,	0.7018],
    '0.25':[0.6517,	0.6763,	0.6362,	0.6531,	0.6547,	0.6615,	0.6939,	0.6722,	0.6633,	0.6786],
    '0.5':[0.6603,	0.6667,	0.6899,	0.6754,	0.6766,	0.7122,	0.6386,	0.6462,	0.6939,	0.6584],
    '0.8':[0.6505,	0.663,	0.6283,	0.6683,	0.667,	0.6515,	0.6239,	0.6742,	0.6392,	0.6521], 
    '1.0':[0.6891,	0.7083,	0.6516,	0.6382,	0.6595,	0.678,	0.6571,	0.6744,	0.677,	0.6439]
                 
 } 
df = pd.DataFrame(data_car)
df.plot.box(title="The car class mAP")
plt.grid(linestyle="--", alpha=0.3)
plt.show()

x = [0.0, 0.1, 0.167, 0.25, 0.5, 0.8, 1]
y_carmAP = [np.mean(data_car['0.0']), np.mean(data_car['0.1']), np.mean(data_car['0.167']), np.mean(data_car['0.25']), np.mean(data_car['0.5']), np.mean(data_car['0.8']), np.mean(data_car['1.0'])]

l5 = plt.plot(x, y_carmAP, 'b.-', label='car mAP')
plt.title('The mean car mAP')
plt.xlabel('')
plt.ylabel('mAP')
plt.legend()
plt.show()
print(y_carmAP)

y_carstd = [np.std(data_car['0.0']), np.std(data_car['0.1']), np.std(data_car['0.167']), np.std(data_car['0.25']), np.std(data_car['0.5']), np.std(data_car['0.8']), np.std(data_car['1.0'])]
l5_std = plt.plot(x, y_carstd, 'b.-', label='std car mAP')
plt.title('The std of car mAP')
plt.xlabel('')
plt.ylabel('std')
plt.legend()
plt.show()
print(y_carstd)

# + colab={"base_uri": "https://localhost:8080/", "height": 842} id="NcCdYqoB14dP" outputId="5432e7bc-b20c-42e2-afc5-85c879b8bc0d"
data_moto ={
    '0.0':[0.0333,	0.5556,	0,	0.1833,	0.0167,	0.2222,	0.0556,	0.1333,	0.0088,	0.5],
    '0.1':[0.5278,	0.0333,	0.0417,	0.4048,	0.2889,	0.1667,	0.25,	0.1738,	0.1875,	0.0556],
    '0.167':[0.3788,	0.1667,	0.4583,	0.1667,	0.2222,	0.4333,	0.3778,	0.1667,	0.1667,	0.4056],
    '0.25':[0.25,	0.3958,	0.3056,	0.1667,	0.1667,	0.1111,	0.25,	0.525,	0.5536,	0.5119],
    '0.5':[0.0833,	0.3333,	0.1333,	0.3333,	0.4333,	0.6667,	0.0556,	0.1111,	0.3333,	0.1667],
    '0.8':[0.2083,	0.2222,	0.1667,	0.1667,	0, 0.2143,	0.1667,	0.0833,	0.4167,	0.125], 
    '1.0':[0.2222,	0.0592,	0.1667,	0.0952,	0.2143,	0.3606,	0.2222,	0.25,	0.3121,	0.0185]
                 
 } 
df = pd.DataFrame(data_moto)
df.plot.box(title="The motorcycle class mAP")
plt.grid(linestyle="--", alpha=0.3)
plt.show()

x = [0.0, 0.1, 0.167, 0.25, 0.5, 0.8, 1]
y_motomAP = [np.mean(data_moto['0.0']), np.mean(data_moto['0.1']), np.mean(data_moto['0.167']), np.mean(data_moto['0.25']), np.mean(data_moto['0.5']), np.mean(data_moto['0.8']), np.mean(data_moto['1.0'])]

l6 = plt.plot(x, y_motomAP, 'b.-', label='motorcycle mAP')
plt.title('The mean motorcycle mAP')
plt.xlabel('')
plt.ylabel('mAP')
plt.legend()
plt.show()
print(y_motomAP)

y_motostd = [np.std(data_moto['0.0']), np.std(data_moto['0.1']), np.std(data_moto['0.167']), np.std(data_moto['0.25']), np.std(data_moto['0.5']), np.std(data_moto['0.8']), np.std(data_moto['1.0'])]
l6_std = plt.plot(x, y_motostd, 'b.-', label='std motorcycle mAP')
plt.title('The std of motorcycle mAP')
plt.xlabel('')
plt.ylabel('std')
plt.legend()
plt.show()
print(y_motostd)

# + colab={"base_uri": "https://localhost:8080/", "height": 842} id="5fhSTFoe2ZJe" outputId="c466edd8-7a4d-423c-ea32-5058b4aaed7a"
data_truck ={
    '0.0':[0.6194,	0.6222,	0.5692,	0.5116,	0.5584,	0.5918,	0.5919,	0.5529,	0.5928,	0.5725],
    '0.1':[0.5696,	0.5505,	0.5826,	0.5568,	0.6164,	0.5864,	0.6103,	0.5407,	0.5996,	0.6549],
    '0.167':[0.6025,	0.5952,	0.6003,	0.5924,	0.6094,	0.5613,	0.6059,	0.6138,	0.6187,	0.5878],
    '0.25':[0.5703,	0.5812,	0.5554,	0.6278,	0.6224,	0.5718,	0.6295,	0.572,	0.5866,	0.614],
    '0.5':[0.5907,	0.6101,	0.6127,	0.5898,	0.5978,	0.5747,	0.581, 0.6243,	0.6094,	0.5414],
    '0.8':[0.5036,	0.5705,	0.5717,	0.5615,	0.5812,	0.5997,	0.5537,	0.6062,	0.6168,	0.6446], 
    '1.0':[0.6083,	0.4997,	0.585,	0.5687,	0.5424,	0.6048,	0.6146,	0.6414,	0.5301,	0.6378]
                 
 } 
df = pd.DataFrame(data_truck)
df.plot.box(title="The truck class mAP")
plt.grid(linestyle="--", alpha=0.3)
plt.show()

x = [0.0, 0.1, 0.167, 0.25, 0.5, 0.8, 1]
y_truckmAP = [np.mean(data_truck['0.0']), np.mean(data_truck['0.1']), np.mean(data_truck['0.167']), np.mean(data_truck['0.25']), np.mean(data_truck['0.5']), np.mean(data_truck['0.8']), np.mean(data_truck['1.0'])]

l7 = plt.plot(x, y_truckmAP, 'b.-', label='truck mAP')
plt.title('The mean truck mAP')
plt.xlabel('')
plt.ylabel('mAP')
plt.legend()
plt.show()
print(y_truckmAP)

y_truckstd = [np.std(data_truck['0.0']), np.std(data_truck['0.1']), np.std(data_truck['0.167']), np.std(data_truck['0.25']), np.std(data_truck['0.5']), np.std(data_truck['0.8']), np.std(data_truck['1.0'])]
l7_std = plt.plot(x, y_truckstd, 'b.-', label='std truck mAP')
plt.title('The std of truck mAP')
plt.xlabel('')
plt.ylabel('std')
plt.legend()
plt.show()
print(y_truckstd)

StarcoderdataJupyterScriptsDedupFiltered