Analyzing results
In this example, solution is returned in a pragmatic
format which model is described in details
here. However, analyzing VRP solution might be a difficult task. That's why
pragmatic
format supports output in geojson format which can be simply
visualized in numerous web based front ends, e.g. geojson.io or using open source tools such
as leaflet
:
{
"type": "FeatureCollection",
"features": [
{
"type": "Feature",
"properties": {
"marker-color": "#e6194b",
"tour_idx": "0",
"marker-symbol": "warehouse",
"jobs_ids": "departure",
"stop_idx": "0",
"marker-size": "medium"
},
"geometry": {
"type": "Point",
"coordinates": [
13.2812488,
52.4664257
]
}
},
{
"type": "Feature",
"properties": {
"jobs_ids": "job40",
"marker-color": "#e6194b",
"marker-size": "medium",
"marker-symbol": "marker",
"tour_idx": "0",
"stop_idx": "1"
},
"geometry": {
"type": "Point",
"coordinates": [
13.3157235,
52.4827319
]
}
},
{
"type": "Feature",
"properties": {
"stop_idx": "2",
"tour_idx": "0",
"marker-size": "medium",
"marker-symbol": "marker",
"marker-color": "#e6194b",
"jobs_ids": "job31"
},
"geometry": {
"type": "Point",
"coordinates": [
13.3353656,
52.4868236
]
}
},
{
"type": "Feature",
"properties": {
"jobs_ids": "job50",
"tour_idx": "0",
"marker-size": "medium",
"marker-symbol": "marker",
"marker-color": "#e6194b",
"stop_idx": "3"
},
"geometry": {
"type": "Point",
"coordinates": [
13.3539713,
52.4959052
]
}
},
{
"type": "Feature",
"properties": {
"marker-symbol": "marker",
"marker-size": "medium",
"marker-color": "#e6194b",
"tour_idx": "0",
"stop_idx": "4",
"jobs_ids": "job27"
},
"geometry": {
"type": "Point",
"coordinates": [
13.3788834,
52.4940454
]
}
},
{
"type": "Feature",
"properties": {
"jobs_ids": "job6",
"stop_idx": "5",
"marker-size": "medium",
"marker-color": "#e6194b",
"marker-symbol": "marker",
"tour_idx": "0"
},
"geometry": {
"type": "Point",
"coordinates": [
13.3915876,
52.4960479
]
}
},
{
"type": "Feature",
"properties": {
"tour_idx": "0",
"marker-color": "#e6194b",
"marker-symbol": "marker",
"marker-size": "medium",
"stop_idx": "6",
"jobs_ids": "job48"
},
"geometry": {
"type": "Point",
"coordinates": [
13.3832067,
52.4855438
]
}
},
{
"type": "Feature",
"properties": {
"stop_idx": "7",
"marker-size": "medium",
"marker-symbol": "marker",
"jobs_ids": "job14",
"marker-color": "#e6194b",
"tour_idx": "0"
},
"geometry": {
"type": "Point",
"coordinates": [
13.3628588,
52.4742821
]
}
},
{
"type": "Feature",
"properties": {
"marker-color": "#e6194b",
"tour_idx": "0",
"stop_idx": "8",
"marker-symbol": "marker",
"jobs_ids": "job36",
"marker-size": "medium"
},
"geometry": {
"type": "Point",
"coordinates": [
13.3598752,
52.4708241
]
}
},
{
"type": "Feature",
"properties": {
"tour_idx": "0",
"marker-color": "#e6194b",
"marker-size": "medium",
"marker-symbol": "marker",
"jobs_ids": "job41",
"stop_idx": "9"
},
"geometry": {
"type": "Point",
"coordinates": [
13.3321906,
52.4711004
]
}
},
{
"type": "Feature",
"properties": {
"marker-symbol": "marker",
"marker-color": "#e6194b",
"stop_idx": "10",
"marker-size": "medium",
"tour_idx": "0",
"jobs_ids": "job32"
},
"geometry": {
"type": "Point",
"coordinates": [
13.322692,
52.4661617
]
}
},
{
"type": "Feature",
"properties": {
"tour_idx": "0",
"marker-symbol": "warehouse",
"stop_idx": "11",
"jobs_ids": "arrival",
"marker-color": "#e6194b",
"marker-size": "medium"
},
"geometry": {
"type": "Point",
"coordinates": [
13.2812488,
52.4664257
]
}
},
{
"type": "Feature",
"properties": {
"stop_idx": "0",
"marker-size": "medium",
"jobs_ids": "departure",
"marker-color": "#808080",
"marker-symbol": "warehouse",
"tour_idx": "1"
},
"geometry": {
"type": "Point",
"coordinates": [
13.2812488,
52.4664257
]
}
},
{
"type": "Feature",
"properties": {
"marker-symbol": "marker",
"stop_idx": "1",
"tour_idx": "1",
"marker-color": "#808080",
"jobs_ids": "job37",
"marker-size": "medium"
},
"geometry": {
"type": "Point",
"coordinates": [
13.38667,
52.4737341
]
}
},
{
"type": "Feature",
"properties": {
"jobs_ids": "job22",
"tour_idx": "1",
"marker-size": "medium",
"marker-symbol": "marker",
"marker-color": "#808080",
"stop_idx": "2"
},
"geometry": {
"type": "Point",
"coordinates": [
13.4363713,
52.4828453
]
}
},
{
"type": "Feature",
"properties": {
"marker-size": "medium",
"tour_idx": "1",
"stop_idx": "3",
"marker-symbol": "marker",
"marker-color": "#808080",
"jobs_ids": "job10"
},
"geometry": {
"type": "Point",
"coordinates": [
13.4698049,
52.4945572
]
}
},
{
"type": "Feature",
"properties": {
"stop_idx": "4",
"marker-color": "#808080",
"marker-symbol": "marker",
"tour_idx": "1",
"jobs_ids": "job11",
"marker-size": "medium"
},
"geometry": {
"type": "Point",
"coordinates": [
13.4740528,
52.4989511
]
}
},
{
"type": "Feature",
"properties": {
"marker-size": "medium",
"stop_idx": "5",
"marker-color": "#808080",
"marker-symbol": "marker",
"tour_idx": "1",
"jobs_ids": "job17"
},
"geometry": {
"type": "Point",
"coordinates": [
13.475099,
52.5058684
]
}
},
{
"type": "Feature",
"properties": {
"jobs_ids": "job26",
"marker-color": "#808080",
"tour_idx": "1",
"marker-symbol": "marker",
"stop_idx": "6",
"marker-size": "medium"
},
"geometry": {
"type": "Point",
"coordinates": [
13.4368189,
52.5090143
]
}
},
{
"type": "Feature",
"properties": {
"jobs_ids": "job21",
"tour_idx": "1",
"marker-size": "medium",
"marker-color": "#808080",
"marker-symbol": "marker",
"stop_idx": "7"
},
"geometry": {
"type": "Point",
"coordinates": [
13.4418623,
52.5228904
]
}
},
{
"type": "Feature",
"properties": {
"marker-symbol": "marker",
"marker-color": "#808080",
"jobs_ids": "job4",
"tour_idx": "1",
"stop_idx": "8",
"marker-size": "medium"
},
"geometry": {
"type": "Point",
"coordinates": [
13.4619776,
52.5243421
]
}
},
{
"type": "Feature",
"properties": {
"jobs_ids": "job49",
"marker-symbol": "marker",
"tour_idx": "1",
"marker-size": "medium",
"marker-color": "#808080",
"stop_idx": "9"
},
"geometry": {
"type": "Point",
"coordinates": [
13.4995315,
52.5279215
]
}
},
{
"type": "Feature",
"properties": {
"stop_idx": "10",
"jobs_ids": "job24",
"marker-symbol": "marker",
"tour_idx": "1",
"marker-size": "medium",
"marker-color": "#808080"
},
"geometry": {
"type": "Point",
"coordinates": [
13.5062954,
52.5261554
]
}
},
{
"type": "Feature",
"properties": {
"jobs_ids": "job35",
"marker-size": "medium",
"marker-symbol": "marker",
"marker-color": "#808080",
"tour_idx": "1",
"stop_idx": "11"
},
"geometry": {
"type": "Point",
"coordinates": [
13.5161692,
52.5426716
]
}
},
{
"type": "Feature",
"properties": {
"tour_idx": "1",
"marker-color": "#808080",
"stop_idx": "12",
"marker-symbol": "marker",
"marker-size": "medium",
"jobs_ids": "job3"
},
"geometry": {
"type": "Point",
"coordinates": [
13.5189513,
52.5421315
]
}
},
{
"type": "Feature",
"properties": {
"marker-size": "medium",
"marker-color": "#808080",
"tour_idx": "1",
"marker-symbol": "marker",
"stop_idx": "13",
"jobs_ids": "job44"
},
"geometry": {
"type": "Point",
"coordinates": [
13.527639,
52.5414557
]
}
},
{
"type": "Feature",
"properties": {
"marker-color": "#808080",
"stop_idx": "14",
"marker-size": "medium",
"marker-symbol": "marker",
"jobs_ids": "job19",
"tour_idx": "1"
},
"geometry": {
"type": "Point",
"coordinates": [
13.546564,
52.5276784
]
}
},
{
"type": "Feature",
"properties": {
"jobs_ids": "job2",
"marker-size": "medium",
"marker-color": "#808080",
"stop_idx": "15",
"marker-symbol": "marker",
"tour_idx": "1"
},
"geometry": {
"type": "Point",
"coordinates": [
13.5152641,
52.5060419
]
}
},
{
"type": "Feature",
"properties": {
"jobs_ids": "job33",
"marker-size": "medium",
"marker-symbol": "marker",
"stop_idx": "16",
"tour_idx": "1",
"marker-color": "#808080"
},
"geometry": {
"type": "Point",
"coordinates": [
13.5251532,
52.4917198
]
}
},
{
"type": "Feature",
"properties": {
"jobs_ids": "job42",
"marker-color": "#808080",
"stop_idx": "17",
"marker-size": "medium",
"tour_idx": "1",
"marker-symbol": "marker"
},
"geometry": {
"type": "Point",
"coordinates": [
13.5423247,
52.4871049
]
}
},
{
"type": "Feature",
"properties": {
"marker-color": "#808080",
"marker-size": "medium",
"stop_idx": "18",
"jobs_ids": "job30",
"tour_idx": "1",
"marker-symbol": "marker"
},
"geometry": {
"type": "Point",
"coordinates": [
13.4914662,
52.4695374
]
}
},
{
"type": "Feature",
"properties": {
"marker-color": "#808080",
"marker-symbol": "marker",
"tour_idx": "1",
"stop_idx": "19",
"jobs_ids": "job5",
"marker-size": "medium"
},
"geometry": {
"type": "Point",
"coordinates": [
13.4757055,
52.4629002
]
}
},
{
"type": "Feature",
"properties": {
"jobs_ids": "job12",
"marker-symbol": "marker",
"tour_idx": "1",
"stop_idx": "20",
"marker-size": "medium",
"marker-color": "#808080"
},
"geometry": {
"type": "Point",
"coordinates": [
13.4461224,
52.4658835
]
}
},
{
"type": "Feature",
"properties": {
"marker-symbol": "warehouse",
"tour_idx": "1",
"marker-color": "#808080",
"marker-size": "medium",
"stop_idx": "21",
"jobs_ids": "arrival"
},
"geometry": {
"type": "Point",
"coordinates": [
13.2812488,
52.4664257
]
}
},
{
"type": "Feature",
"properties": {
"marker-color": "#000075",
"marker-symbol": "warehouse",
"tour_idx": "2",
"jobs_ids": "departure",
"stop_idx": "0",
"marker-size": "medium"
},
"geometry": {
"type": "Point",
"coordinates": [
13.2812488,
52.4664257
]
}
},
{
"type": "Feature",
"properties": {
"stop_idx": "1",
"jobs_ids": "job28",
"marker-color": "#000075",
"marker-size": "medium",
"marker-symbol": "marker",
"tour_idx": "2"
},
"geometry": {
"type": "Point",
"coordinates": [
13.3689955,
52.5065998
]
}
},
{
"type": "Feature",
"properties": {
"jobs_ids": "job25",
"marker-symbol": "marker",
"tour_idx": "2",
"stop_idx": "2",
"marker-size": "medium",
"marker-color": "#000075"
},
"geometry": {
"type": "Point",
"coordinates": [
13.3890068,
52.5189653
]
}
},
{
"type": "Feature",
"properties": {
"marker-color": "#000075",
"tour_idx": "2",
"stop_idx": "3",
"marker-size": "medium",
"marker-symbol": "marker",
"jobs_ids": "job23"
},
"geometry": {
"type": "Point",
"coordinates": [
13.3668934,
52.5291335
]
}
},
{
"type": "Feature",
"properties": {
"tour_idx": "2",
"marker-size": "medium",
"marker-symbol": "marker",
"jobs_ids": "job38",
"stop_idx": "4",
"marker-color": "#000075"
},
"geometry": {
"type": "Point",
"coordinates": [
13.3914127,
52.5404107
]
}
},
{
"type": "Feature",
"properties": {
"tour_idx": "2",
"jobs_ids": "job7",
"marker-symbol": "marker",
"marker-size": "medium",
"stop_idx": "5",
"marker-color": "#000075"
},
"geometry": {
"type": "Point",
"coordinates": [
13.3996298,
52.5372914
]
}
},
{
"type": "Feature",
"properties": {
"jobs_ids": "job8",
"marker-size": "medium",
"marker-symbol": "marker",
"tour_idx": "2",
"stop_idx": "6",
"marker-color": "#000075"
},
"geometry": {
"type": "Point",
"coordinates": [
13.3989552,
52.5429597
]
}
},
{
"type": "Feature",
"properties": {
"marker-color": "#000075",
"marker-size": "medium",
"marker-symbol": "marker",
"tour_idx": "2",
"stop_idx": "7",
"jobs_ids": "job45"
},
"geometry": {
"type": "Point",
"coordinates": [
13.4139155,
52.5425207
]
}
},
{
"type": "Feature",
"properties": {
"marker-symbol": "marker",
"jobs_ids": "job34",
"stop_idx": "8",
"marker-color": "#000075",
"marker-size": "medium",
"tour_idx": "2"
},
"geometry": {
"type": "Point",
"coordinates": [
13.4416407,
52.5431264
]
}
},
{
"type": "Feature",
"properties": {
"marker-symbol": "marker",
"stop_idx": "9",
"marker-size": "medium",
"tour_idx": "2",
"jobs_ids": "job16",
"marker-color": "#000075"
},
"geometry": {
"type": "Point",
"coordinates": [
13.4286263,
52.5496702
]
}
},
{
"type": "Feature",
"properties": {
"stop_idx": "10",
"tour_idx": "2",
"jobs_ids": "job43",
"marker-symbol": "marker",
"marker-size": "medium",
"marker-color": "#000075"
},
"geometry": {
"type": "Point",
"coordinates": [
13.4194712,
52.5614441
]
}
},
{
"type": "Feature",
"properties": {
"tour_idx": "2",
"marker-size": "medium",
"marker-symbol": "marker",
"stop_idx": "11",
"jobs_ids": "job9",
"marker-color": "#000075"
},
"geometry": {
"type": "Point",
"coordinates": [
13.4231417,
52.5678751
]
}
},
{
"type": "Feature",
"properties": {
"stop_idx": "12",
"marker-symbol": "marker",
"marker-size": "medium",
"tour_idx": "2",
"jobs_ids": "job1",
"marker-color": "#000075"
},
"geometry": {
"type": "Point",
"coordinates": [
13.3848221,
52.5697304
]
}
},
{
"type": "Feature",
"properties": {
"jobs_ids": "job13",
"marker-color": "#000075",
"marker-size": "medium",
"tour_idx": "2",
"marker-symbol": "marker",
"stop_idx": "13"
},
"geometry": {
"type": "Point",
"coordinates": [
13.369072,
52.5685168
]
}
},
{
"type": "Feature",
"properties": {
"marker-symbol": "marker",
"tour_idx": "2",
"stop_idx": "14",
"jobs_ids": "job29",
"marker-color": "#000075",
"marker-size": "medium"
},
"geometry": {
"type": "Point",
"coordinates": [
13.3733163,
52.547349
]
}
},
{
"type": "Feature",
"properties": {
"tour_idx": "2",
"stop_idx": "15",
"marker-size": "medium",
"marker-color": "#000075",
"marker-symbol": "marker",
"jobs_ids": "job39"
},
"geometry": {
"type": "Point",
"coordinates": [
13.369356,
52.5492619
]
}
},
{
"type": "Feature",
"properties": {
"marker-size": "medium",
"marker-color": "#000075",
"tour_idx": "2",
"stop_idx": "16",
"marker-symbol": "marker",
"jobs_ids": "job18"
},
"geometry": {
"type": "Point",
"coordinates": [
13.3327894,
52.5473416
]
}
},
{
"type": "Feature",
"properties": {
"marker-color": "#000075",
"marker-size": "medium",
"marker-symbol": "marker",
"stop_idx": "17",
"tour_idx": "2",
"jobs_ids": "job15"
},
"geometry": {
"type": "Point",
"coordinates": [
13.3027992,
52.5650163
]
}
},
{
"type": "Feature",
"properties": {
"jobs_ids": "job46",
"tour_idx": "2",
"marker-color": "#000075",
"marker-size": "medium",
"marker-symbol": "marker",
"stop_idx": "18"
},
"geometry": {
"type": "Point",
"coordinates": [
13.2940051,
52.5632095
]
}
},
{
"type": "Feature",
"properties": {
"marker-size": "medium",
"stop_idx": "19",
"jobs_ids": "job20",
"marker-color": "#000075",
"marker-symbol": "marker",
"tour_idx": "2"
},
"geometry": {
"type": "Point",
"coordinates": [
13.304444,
52.5192039
]
}
},
{
"type": "Feature",
"properties": {
"stop_idx": "20",
"marker-color": "#000075",
"marker-size": "medium",
"marker-symbol": "marker",
"tour_idx": "2",
"jobs_ids": "job47"
},
"geometry": {
"type": "Point",
"coordinates": [
13.2852959,
52.5146285
]
}
},
{
"type": "Feature",
"properties": {
"marker-color": "#000075",
"marker-symbol": "warehouse",
"stop_idx": "21",
"jobs_ids": "arrival",
"marker-size": "medium",
"tour_idx": "2"
},
"geometry": {
"type": "Point",
"coordinates": [
13.2812488,
52.4664257
]
}
},
{
"type": "Feature",
"properties": {
"tour_idx": "0",
"stroke": "#e6194b",
"shift_idx": "0",
"vehicle_id": "vehicle_1",
"distance": "17708",
"activities": "12",
"stroke-width": "4"
},
"geometry": {
"type": "LineString",
"coordinates": [
[
13.2812488,
52.4664257
],
[
13.3157235,
52.4827319
],
[
13.3353656,
52.4868236
],
[
13.3539713,
52.4959052
],
[
13.3788834,
52.4940454
],
[
13.3915876,
52.4960479
],
[
13.3832067,
52.4855438
],
[
13.3628588,
52.4742821
],
[
13.3598752,
52.4708241
],
[
13.3321906,
52.4711004
],
[
13.322692,
52.4661617
],
[
13.2812488,
52.4664257
]
]
}
},
{
"type": "Feature",
"properties": {
"shift_idx": "0",
"vehicle_id": "vehicle_4",
"distance": "52748",
"stroke-width": "4",
"activities": "22",
"stroke": "#3cb44b",
"tour_idx": "1"
},
"geometry": {
"type": "LineString",
"coordinates": [
[
13.2812488,
52.4664257
],
[
13.38667,
52.4737341
],
[
13.4363713,
52.4828453
],
[
13.4698049,
52.4945572
],
[
13.4740528,
52.4989511
],
[
13.475099,
52.5058684
],
[
13.4368189,
52.5090143
],
[
13.4418623,
52.5228904
],
[
13.4619776,
52.5243421
],
[
13.4995315,
52.5279215
],
[
13.5062954,
52.5261554
],
[
13.5161692,
52.5426716
],
[
13.5189513,
52.5421315
],
[
13.527639,
52.5414557
],
[
13.546564,
52.5276784
],
[
13.5152641,
52.5060419
],
[
13.5251532,
52.4917198
],
[
13.5423247,
52.4871049
],
[
13.4914662,
52.4695374
],
[
13.4757055,
52.4629002
],
[
13.4461224,
52.4658835
],
[
13.2812488,
52.4664257
]
]
}
},
{
"type": "Feature",
"properties": {
"activities": "22",
"stroke-width": "4",
"stroke": "#4363d8",
"distance": "44910",
"tour_idx": "2",
"vehicle_id": "vehicle_5",
"shift_idx": "0"
},
"geometry": {
"type": "LineString",
"coordinates": [
[
13.2812488,
52.4664257
],
[
13.3689955,
52.5065998
],
[
13.3890068,
52.5189653
],
[
13.3668934,
52.5291335
],
[
13.3914127,
52.5404107
],
[
13.3996298,
52.5372914
],
[
13.3989552,
52.5429597
],
[
13.4139155,
52.5425207
],
[
13.4416407,
52.5431264
],
[
13.4286263,
52.5496702
],
[
13.4194712,
52.5614441
],
[
13.4231417,
52.5678751
],
[
13.3848221,
52.5697304
],
[
13.369072,
52.5685168
],
[
13.3733163,
52.547349
],
[
13.369356,
52.5492619
],
[
13.3327894,
52.5473416
],
[
13.3027992,
52.5650163
],
[
13.2940051,
52.5632095
],
[
13.304444,
52.5192039
],
[
13.2852959,
52.5146285
],
[
13.2812488,
52.4664257
]
]
}
}
]
}
To return solution in geojson
format, use extra -g
or --geo-json
option.
Jupyter notebooks
You might want to look at this project. It provides some scripts and jupyter notebooks in order to perform deeper analysis of algorithm behaviour.