Swarm Intelligence Heuristics for Graph Coloring Problem

24
Swarm Intelligence Heuristics for Graph Coloring Problem Piero Consoli 1 Alessio Collerà 2 Mario Pavone 2 1 School of Computer Science, University of Birmingham Edgbaston, Birmingham, B15 2TT, UK 2 Department of Mathematics and Computer Science, University of Catania Viale A. Doria 6, 95125 Catania, Italy IEEE Congress on Evolutionary Computation – CEC 2013 Mario Pavone ([email protected]) http://www.dmi.unict.it/mpavone/ University of Catania 1 / 24

description

In this research work we present two novel swarm heuristics based respectively on the ants and bees artificial colonies, called AS-GCP and ABC-GCP. The first is based mainly on the combination of Greedy Partitioning Crossover (GPX), and a local search approach that interact with the pheromone trails system; the last, instead, has as strengths three evolutionary operators, such as a mutation operator; an improved version of GPX and a Temperature mechanism. The aim of this work is to evaluate the efficiency and robustness of both developed swarm heuristics, in order to solve the classical Graph Coloring Problem (GCP). Many experiments have been performed in order to study what is the real contribution of variants and novelty designed both in AS-GCP and ABC-GCP. A first study has been conducted with the purpose for setting the best parameters tuning, and analyze the running time for both algorithms. Once done that, both swarm heuristics have been compared with 15 different algorithms using the classical DIMACS benchmark. Inspecting all the experiments done is possible to say that AS-GCP and ABC-GCP are very competitive with all compared algorithms, demonstrating thus the goodness of the variants and novelty designed. Moreover, focusing only on the comparison among AS-GCP and ABC-GCP is possible to claim that, albeit both seem to be suitable to solve the GCP, they show different features: AS-GCP presents a quickly convergence towards good solutions, reaching often the best coloring; ABC-GCP, instead, shows performances more robust, mainly in graphs with a more dense, and complex topology. Finally, ABC-GCP in the overall has showed to be more competitive with all compared algorithms than AS-GCP as average of the best colors found.

Transcript of Swarm Intelligence Heuristics for Graph Coloring Problem

Page 1: Swarm Intelligence Heuristics for Graph Coloring Problem

Swarm Intelligence Heuristics forGraph Coloring Problem

Piero Consoli 1 Alessio Collerà 2 Mario Pavone 2

1School of Computer Science,University of Birmingham

Edgbaston, Birmingham, B15 2TT, UK

2Department of Mathematics and Computer Science,University of Catania

Viale A. Doria 6, 95125 Catania, Italy

IEEE Congress on Evolutionary Computation – CEC 2013

Mario Pavone ([email protected]) http://www.dmi.unict.it/mpavone/ University of Catania 1 / 24

Page 2: Swarm Intelligence Heuristics for Graph Coloring Problem

Outline

1 Introduction & Aims

2 Graph Coloring Problem

3 Swarm Intelligence HeuristicsAS-GCP: an Ant Colony SystemABC-GCP: an Artificial Bee Colony

4 ResultsParameters TuningRunning Time – ttt-plotsExperimental Comparisons

5 Conclusions

Mario Pavone ([email protected]) http://www.dmi.unict.it/mpavone/ University of Catania 2 / 24

Page 3: Swarm Intelligence Heuristics for Graph Coloring Problem

Introduction & Aims

Introduction & Aims

Two novel Swarm Heuristics: AS-GCP and ABC-GCPAnt Systems: most efficient and robust of the familyArtificial Bee Colony: competitive in optimization tasks[Karaboga et al., J. of Global Optimization, 39(3), 2007]

Graph Coloring Problem used for evaluate and compareAims:

1 evaluate performances of AS-GCP and ABC-GCP2 quality of solutions: minimal colors number found; average colors

number found; success rate; and average evaluations number tosolution

3 impact factor of variants and novelties designed4 search capabilities5 efficiency and robustness6 Which of the two is more suitable for coloring a graph

Mario Pavone ([email protected]) http://www.dmi.unict.it/mpavone/ University of Catania 3 / 24

Page 4: Swarm Intelligence Heuristics for Graph Coloring Problem

Graph Coloring Problem

Graph Coloring Problem – GCP

Classical combinatorial optimization problem that findsapplicability in many real-world problemsGiven G = (V ,E) assign one color C such that C(u) 6= C(v) forany (u, v) ∈ EPartitioning V into groups: every group is an independent setChromatic Number (χ): minimal number of colorsif |C| = k then G is said k-colorableif k = χ G is said k-chromatic.Computing χ is NP–complete problem [Garey and Johnson,1979]

Mario Pavone ([email protected]) http://www.dmi.unict.it/mpavone/ University of Catania 4 / 24

Page 5: Swarm Intelligence Heuristics for Graph Coloring Problem

Swarm Intelligence Heuristics AS-GCP: an Ant Colony System

an Ant Colony System – AS-GCP

Mario Pavone ([email protected]) http://www.dmi.unict.it/mpavone/ University of Catania 5 / 24

Page 6: Swarm Intelligence Heuristics for Graph Coloring Problem

Swarm Intelligence Heuristics AS-GCP: an Ant Colony System

AS-GCP

AS-GCP is based on ANTCOL [Costa et al., J. of Oper. Research Society, 49:295–305, 1997]

Randomized ANT_RLF: combines the good heuristic of RLF with thepheromone trails

Pi,k =ταik η

βik∑

j∈W ταij ηβij

Fitness function: takes account the number of colors, and length of eachcolor class

f (~x) =1

||V | − |Ck || ·√

c(~x)

Pheromone trail:

τv ,k =

{1, if Ck is empty∑

u∈CkMu,v

|Ck | , otherwise.

Evaporation mechanism: Mr ,s = (1− ρ) Mr ,s

Mario Pavone ([email protected]) http://www.dmi.unict.it/mpavone/ University of Catania 6 / 24

Page 7: Swarm Intelligence Heuristics for Graph Coloring Problem

Swarm Intelligence Heuristics AS-GCP: an Ant Colony System

AS-GCP

Any ant undergoes to Crossover Operator and Local SearchGreedy Partitioning Crossover (GPX): most important the set ofthe vertices that belong to the same class [Jin-Kao Hao et al., J. of

Combinatorial Optimization, 3(4): 379–397, 1997]

Local Search: recursively tries to decrease the number of colorsof each solutionDepends on the parameters: minRec and maxRecIntegration among GPX and Local Search: avoid fragmentation ofthe colorclassesrefinement via LS if the cardinality is below to partLim

Mario Pavone ([email protected]) http://www.dmi.unict.it/mpavone/ University of Catania 7 / 24

Page 8: Swarm Intelligence Heuristics for Graph Coloring Problem

Swarm Intelligence Heuristics AS-GCP: an Ant Colony System

AS-GCP vs. ANTCOL

ANTCOL AS-GCPinstance k bf SR ± AES bf SR ± AESQueen6_6 7 7 100%± 956 7 100%± 96Queen7_7 7 7 61%± 1991 7 100%±700Queen8_8 9 9 48%± 1294 9 100%±203Queen8_12 12 12 87%± 6625 12 100%±162Queen9_9 10 10 60%± 2614 10 100%±1022School1.nsh 14 14 100%± 2966 14 100%± 1417School1 14 14 100%± 3120 14 100%± 922DSJC125.1 5 5 40%± 9310 5 100%±160DSJC125.5 12 18 30%± 9751 17 100%± 4590DSJC125.9 30 44 40%± 10112 44 100%± 1128DSJC250.1 8 9 100%± 2561 8 100%± 21773DSJC250.5 13 31 100%± 19238 29 30%± 24156DSJC250.9 35 75 40%± 9274 73 40%± 7554le450_15a 15 16 100%± 7913 16 100%± 1600le450_15b 15 16 100%± 3872 16 100%± 1052le450_15c 15 15 100%± 12422 15 100%± 4300le450_15d 15 15 100%± 12755 15 100%± 8604flat300_20 20 20 100%± 8188 20 100%± 6394flat300_26 26 34 60%± 21548 32 60%± 10780flat300_28 28 34 70%± 19120 32 60%± 9186

Table: Improvements produced by novelties introduced.

Mario Pavone ([email protected]) http://www.dmi.unict.it/mpavone/ University of Catania 8 / 24

Page 9: Swarm Intelligence Heuristics for Graph Coloring Problem

Swarm Intelligence Heuristics ABC-GCP: an Artificial Bee Colony

an Artificial Bee Colony – ABC-GCP

Mario Pavone ([email protected]) http://www.dmi.unict.it/mpavone/ University of Catania 9 / 24

Page 10: Swarm Intelligence Heuristics for Graph Coloring Problem

Swarm Intelligence Heuristics ABC-GCP: an Artificial Bee Colony

ABC-GCP

Three different types of bees each with different taskEmployed Bees: search for food, and store information on foodsources

tries to improve each solution using perturbation operatorsOnlooker Bees: exploits the information in order to select goodfood sources

choose the solution to exploit with a roulette wheel selectionScout Bees: discover new food sources

all solutions without improvements are replaced by new ones

Initialization phase: RLF + random orderStrengths via three operators: mutation, crossover andtemperature mechanism

Mario Pavone ([email protected]) http://www.dmi.unict.it/mpavone/ University of Catania 10 / 24

Page 11: Swarm Intelligence Heuristics for Graph Coloring Problem

Swarm Intelligence Heuristics ABC-GCP: an Artificial Bee Colony

ABC-GCP

SmartSwap mutation operator: tries to reduce the number ofcolorclasses handling the troublesome nodes

partLimit : maximum number of constraints unsatisfied allowedoptimized GPX: the cardinality of the color classes that can becopied are handled by a parameter

generated conflicts are eliminatedTemperature mechanism: dynamically handles some parametersduring the evolutionary cycle

number of parents involved in GPXnumber of the improvement trails needed to replace a solutionnumber of scout beespercentage of solutions generated by RLF during the scout beesphase

if we inhibit one of them the outcome will be negatively affected

Mario Pavone ([email protected]) http://www.dmi.unict.it/mpavone/ University of Catania 11 / 24

Page 12: Swarm Intelligence Heuristics for Graph Coloring Problem

Swarm Intelligence Heuristics ABC-GCP: an Artificial Bee Colony

Impact Factor of ABC-GCP Operators����������������� ��������������������������������������� ��� ������ ������������ ����������������� ��������������������������������������� ��� ������ ������������ ����������������� ��������������������������������������� ��� ������ ����������������������������� ������ ������ ��������������������������� ��� ������ ������������ ����������������� ������ ������ ��������������������������� ��� ������ ������������ ����������������� ��������������������������������������� ��� ������ ������������Mario Pavone ([email protected]) http://www.dmi.unict.it/mpavone/ University of Catania 12 / 24

Page 13: Swarm Intelligence Heuristics for Graph Coloring Problem

Results

Results & Comparisons

Mario Pavone ([email protected]) http://www.dmi.unict.it/mpavone/ University of Catania 13 / 24

Page 14: Swarm Intelligence Heuristics for Graph Coloring Problem

Results

Experimental Protocolo & Aims

The challenging DIMACS Benchmark http://mat.gsia.cmu.edu/COLOR/instances.html

10 indenpendent runsStop Criterion: maximum fitness function evaluations allowed

AS-GCP ABC-GCPle450_15c DSJC250.5

α ∈ {0, 1, 2, 3, 4} popSize ∈ {200, 500, 1000, 1500, 2000}β ∈ {0, 1, 2, 3, 4} percEmp ∈ {10%, 20%, 50%, 70%, 90%}

ρ ∈ {0.01, 0.1, 0.3, 0.6, 0.9, 0.99} partLimit ∈ {5, 10, 15, 18}minRec ∈ {1, 5, 10, 30}maxRec ∈ {5, 10, 30}partLim ∈ {1, 3, 5, 8}

Mario Pavone ([email protected]) http://www.dmi.unict.it/mpavone/ University of Catania 14 / 24

Page 15: Swarm Intelligence Heuristics for Graph Coloring Problem

Results Parameters Tuning

Analysis of the Convergence Speed: AS-GCP

15

20

25

30

35

0 5 10 15 20

k

generations

Ant Colony Optimization - alpha parameter

2,4,0.99,5,10,5

0,4,0.99,5,10,5

1,4,0.99,5,10,5

3,4,0.99,5,10,5

4,4,0.99,5,10,5

15

20

25

30

35

0 25 50 75 100

k

generations

Ant Colony Optimization - beta parameter

2,4,0.99,5,10,5

2,0,0.99,5,10,5

2,1,0.99,5,10,5

2,2,0.99,5,10,5

2,3,0.99,5,10,5

15

20

25

30

35

0 25 50 75 100

k

generations

Ant Colony Optimization - rho parameter

2,4,0.99,5,10,5

2,4,0.01,5,10,5

2,4,0.1,5,10,5

2,4,0.3,5,10,5

2,4,0.6,5,10,5

2,4,0.9,5,10,5

15

20

25

30

35

0 5 10 15 20

k

generations

Ant Colony Optimization - maxRec parameter

2,4,0.99,5,10,5

2,4,0.99,5,5,5

2,4,0.99,5,30,5

15

20

25

30

35

0 5 10 15 20

k

generations

Ant Colony Optimization - minRec parameter

2,4,0.99,5,10,5

2,4,0.99,1,10,5

2,4,0.99,10,10,5

15

20

25

30

35

0 5 10 15 20

k

generations

Ant Colony Optimization - partLim parameter

2,4,0.99,5,10,5

2,4,0.99,5,10,1

2,4,0.99,5,10,3

2,4,0.99,5,10,8

Mario Pavone ([email protected]) http://www.dmi.unict.it/mpavone/ University of Catania 15 / 24

Page 16: Swarm Intelligence Heuristics for Graph Coloring Problem

Results Parameters Tuning

Analysis of the Convergence Speed: ABC-GCP

29

30

31

32

33

34

35

36

37

38

39

0 500 1000 1500 2000

k

generations

Artificial Bee Colony - popSize parameter

200,10%,5

500,10%,5

1000,10%,5

1500,10%,5

2000,10%,5

29

30

31

32

33

34

35

36

37

38

39

0 500 1000 1500 2000

k

generations

Artificial Bee Colony - percEmp parameter

200,10%,5

200,20%,5

200,50%,5

200,70%,5

200,90%,5

29

30

31

32

33

34

35

36

37

38

39

0 500 1000 1500 2000

k

generations

Artificial Bee Colony - partLimit parameter

200,10%,5

200,10%,10

200,10%,15

200,10%,18

Mario Pavone ([email protected]) http://www.dmi.unict.it/mpavone/ University of Catania 16 / 24

Page 17: Swarm Intelligence Heuristics for Graph Coloring Problem

Results Running Time – ttt-plots

Time-To-Target plots

Standard graphical methodology for data analysis[Chambers et la., Chapman & Hall, 1983]

A way to characterize the running time of stochastic algorithms

display the probability that an algorithm will find a solution as good as atarget within a given running time

a Perl program – tttplots.pl – to create time-to-target plots[Resende et al., Optimization Letters, 2007] – [http://www2.research.att.com/˜mgcr/tttplots/]

Both swarm heuristics are run where the obtained mean is equal to theoptimal solution

Analysis conducted on: le450_15b and DSJC250.1 & 200 runs

termination criterion: until finding the target solution

larger is the number of runs closer is the empirical distribution to thetheoretical distribution

Mario Pavone ([email protected]) http://www.dmi.unict.it/mpavone/ University of Catania 17 / 24

Page 18: Swarm Intelligence Heuristics for Graph Coloring Problem

Results Running Time – ttt-plots

ttt-plots

0

0.2

0.4

0.6

0.8

1

400 450 500 550 600 650 700 750 800

cum

ula

tive p

robabilit

y

time to target solution

Ant Colony System

empirical

theoretical

0

0.2

0.4

0.6

0.8

1

0 30 60 90

cum

ula

tive p

robabilit

y

time to target solution

Artificial Bee Colony

empirical

theoretical

500

550

600

650

700

750

0 0.5 1 1.5 2 2.5 3 3.5 4 4.5 5

measure

d t

imes

exponential quantiles

Ant Colony System

empirical

estimated

+1 std dev range

-1 std dev range

46

48

50

52

54

56

58

60

62

64

66

0 0.5 1 1.5 2 2.5 3 3.5 4 4.5 5

measure

d t

imes

exponential quantiles

Artificial Bee Colony

empirical

estimated

+1 std dev range

-1 std dev range

Mario Pavone ([email protected]) http://www.dmi.unict.it/mpavone/ University of Catania 18 / 24

Page 19: Swarm Intelligence Heuristics for Graph Coloring Problem

Results Experimental Comparisons

AS-GCP vs. ABC-GCP

ABC-GCP AS-GCPinstance |V | |E| k bf SR AES bf SR AESQueen6_6 36 580 7 7 100% 1.7K 7 100% 96Queen7_7 49 952 7 7 100% 6.6K 7 100% 700Queen8_8 64 1,456 9 9 100% 22.1K 9 100% 203Queen8_12 96 2,736 12 12 100% 1.2M 12 100% 162Queen9_9 81 1,056 10 10 100% 31.2K 10 100% 1KSchool1.nsh 352 14,612 14 14 100% 1.7K 14 100% 1.4KSchool1 385 19,095 14 14 100% 821,5 14 100% 922DSJC125.1 125 736 5 5 50% 528K 5 100% 160DSJC125.5 125 3,891 12 17 10% 464K 17 100% 4.5KDSJC125.9 125 6,961 30 44 100% 29K 44 100% 1.1KDSJC250.1 250 3,218 8 9 100% 252K 8 100% 21.7KDSJC250.5 250 15,668 13 29 100% 471K 29 30% 24.5KDSJC250.9 250 27,897 35 73 90% 24.4M 73 40% 7.5Kle450_15a 450 8,168 15 16 100% 17.6M 16 100% 1.6Kle450_15b 450 8,169 15 16 100% 6.1M 16 100% 1Kle450_15c 450 16,680 15 15 100% 5.9M 15 100% 4.3Kle450_15d 450 16,750 15 15 80% 18.6M 15 100% 8.6Kflat300_20 300 21,375 20 20 100% 4800 20 100% 6.3Kflat300_26 300 21,633 26 26 100% 72.9K 32 60% 10.7Kflat300_28 300 21,695 28 31 20% 5.6M 32 60% 9.1K

Table: ABC-GCP versus AS-GCP on several DIMACS instances.

Mario Pavone ([email protected]) http://www.dmi.unict.it/mpavone/ University of Catania 19 / 24

Page 20: Swarm Intelligence Heuristics for Graph Coloring Problem

Results Experimental Comparisons

AS-GCP & ABC-GCP vs. Other Algorithms

instance I_Greedy T_B&B DIST PAR T_GEN_1 ABC-GCP AS-GCPDSJC125.5 18.9 20.0 17.0 17.0 17.0 17.9 17.0DSJC250.5 32.8 35.0 28.0 29.2 29.0 29.0 29.7flat300_20 20.0 39.0 20.0 20.0 20.0 20.0 20.0flat300_26 37.1 41.0 26.0 32.4 26.0 26.0 32.6flat300_28 37.0 41.0 31.0 33.0 33.0 31.8 32.6le450_15a 17.9 16.0 15.0 15.0 15.0 16.0 16.0le450_15b 17.9 15.0 15.0 15.0 15.0 16.0 16.0le450_15c 25.6 23.0 15 16.6 16.0 15.0 15.0le450_15d 25.8 23.0 15.0 16.8 16.0 15.2 15.0mulsol.i.1 49.0 49.0 49.0 49.0 49.0 49.0 49.0school1.nsh 14.1 26.0 20.0 14.0 14.0 14.0 14.0

I_Greedy: [Culberson et al., 2nd DIMACS Implementation Challenge, 14(1):254–284, 1996]

T_B&B: [Glover et al., 2nd DIMACS Implementation Challenge, 14(1):285–307, 1996]

DIST: [Morgenstern, 2nd DIMACS Implementation Challenge, 14(1):335–357, 1996]

PAR: [Lewandowski et al., 2nd DIMACS Implementation Challenge, 14(1):309–334, 1996]

T_GEN_1: [Fleurent et al., 2nd DIMACS Implementation Challenge, 14(1):619–652, 1996]

Mario Pavone ([email protected]) http://www.dmi.unict.it/mpavone/ University of Catania 20 / 24

Page 21: Swarm Intelligence Heuristics for Graph Coloring Problem

Results Experimental Comparisons

AS-GCP & ABC-GCP vs. Other Algorithms

instance IMMALG ANTCOL EVOLVE_AO HCA MACOL ABC-GCP AS-GCPDSJC125.5 18.0 18.7 17.2 - 17.0 17.9 17.0DSJC250.5 28.0 31.0 29.1 28.1 28.0 29.0 29.7flat300_20 20.0 20.0 26.0 - 20.0 20.0 20.0flat300_26 27.0 34.4 31.0 - 26.0 26.0 32.6flat300_28 32.0 34.3 33.0 31.4 29.0 31.8 32.6le450_15a 15.0 16.0 15.0 - 15.0 16.0 16.0le450_15b 15.0 16.0 15.0 - 15.0 16.0 16.0le450_15c 15.0 15.0 16.0 15.6 15.0 15.0 15.0le450_15d 16.0 15.0 19.0 - 15.0 15.2 15.0mulsol.i.1 49.0 - - - - 49.0 49.0school1.nsh 15.0 - - - 14.0 14.0 14.0

IMMALG: [Cutello et al., Journal of Combinatorial Optimization, 14(1):9–33, 2007] and [Pavone et al., Journal of GlobalOptimization, 53(4):769–808, 2012]

ANTCOL: [Costa et al., Journal of Operational Research Society, 49:295–305, 1997]

EVOLVE_AO: [Barbosa et al., Journal of Combinatorial Optimization, 8(1):41–63, 2004]

HCA: [Hao et al., Journal of Combinatorial Optimization, 3(4):379–397, 1999]

MACOL: [Hao et al., European Journal of Operational Research, 203(1):241–250, 2010]

Mario Pavone ([email protected]) http://www.dmi.unict.it/mpavone/ University of Catania 21 / 24

Page 22: Swarm Intelligence Heuristics for Graph Coloring Problem

Results Experimental Comparisons

AS-GCP & ABC-GCP vs. Other Algorithms

instance HPSO GPB VNS VSS HANTCOL ABC-GCP AS-GCPDSJC250.5 28 28 - - 28 29 29flat300_26 26 - 31 - - 26 32flat300_28 31 31 31 29 31 31 32le450_15c 15 15 15 15 15 15 15le450_15d 15 - 15 15 - 15 15

The results have been taken from [Qin et al., Journal of Computers, 6(6):1175–1182, 2011]

HPSO: [Qin et al., Journal of Computers, 6(6):1175–1182, 2011]

GPB: [Glass et al., Journal of Combinatorial Optimization, 7(3):229–236, 2003]

VNS: [Hertz et al., European Journal of Operational Research, 151(2):379–388, 2003]

VSS: [Hertz et al., Discrete Applied Mathematics, 156(13):2551–2560, 2008]

HANTCOL: [Thompson et al., Discrete Applied Mathematics, 156(3):313–324, 2008]

Mario Pavone ([email protected]) http://www.dmi.unict.it/mpavone/ University of Catania 22 / 24

Page 23: Swarm Intelligence Heuristics for Graph Coloring Problem

Conclusions

Conclusions (1/2)

A comparative study is presented between two swarm intelligenceheuristicsAS-GCP: based on the combination of GPX and LSABC-GCP: based on SmartSwap mutation operator; optimizedGPX; and Temperature mechanismGCP has been tackled in order to evaluate the performancesMany experiments have been performed in order to:

find the best tuning of the parametersanalyze the running time via Time-To-Target plotsperformed experimental comparisons

Mario Pavone ([email protected]) http://www.dmi.unict.it/mpavone/ University of Catania 23 / 24

Page 24: Swarm Intelligence Heuristics for Graph Coloring Problem

Conclusions

Conclusions (2/2)

Inspecting ttt-plots: ABC-GCP produces good approximations ofthe theoretical distributions than AS-GCPAnalyzing experiments: both swarm heuristics are competitivewith all tested algorithmsThe efficiency and robustness showed proves us the goodness ofthe variants, and novelties designedAS-GCP vs. ABC-GCP:

AS-GCP shows a quickly learning that helps in reaching the bestcoloring in a few generationsABC-GCP presents a behavior more robust and competitive thanAS-GCPABC-GCP seems to be more suitable on graphs with more dense,and complex topology

Mario Pavone ([email protected]) http://www.dmi.unict.it/mpavone/ University of Catania 24 / 24