GithubHelp home page GithubHelp logo

jkomyno / algorithms-hw3 Goto Github PK

View Code? Open in Web Editor NEW
1.0 3.0 1.0 1.09 MB

License: MIT License

C++ 19.66% Makefile 1.19% Python 27.50% Shell 0.94% TeX 50.70%
randomized-algorithms minimum-cut karger karger-stein

algorithms-hw3's People

Contributors

jkomyno avatar lparolari avatar

Stargazers

 avatar

Watchers

 avatar  avatar  avatar

Forkers

lparolari

algorithms-hw3's Issues

Plot graphs using a Python3 script

Generale

  • variazione dei tempi di calcolo al variare del numero di vertici nel grafo senza timeout
  • variazione dei tempi di calcolo al variare del numero di vertici nel grafo con timeout
  • confronto tra discovery time e tempo di esecuzione complessivo per ognuno dei grafi nel dataset

Confronto tra implementazioni

  • variazione dei tempi di calcolo per 4 grafi di grandi dimensioni tra KargerMinCut (senza timeout) e KargerSteinMinCut
  • variazione dei tempi di calcolo per 4 grafi di grandi dimensioni tra KargerMinCut (con timeout) e KargerSteinMinCut

Dataset di input da usare:

  • input_random_25_125.txt
  • input_random_29_150.txt
  • input_random_35_175.txt
  • input_random_40_200.txt

Add timeout on KargerMinCut

In KargerMinCut, the average complete execution of the algorithm takes 146 seconds (2.5 minutes), but the longest execution takes 918 seconds (15 minutes).
The longest discovery time, however, takes 45 seconds.

We can thus set a maximum execution time to 120 seconds.

We can re-use the same timeout class used for homework 2.

Add discussion about program execution statistics in MinCutKarger

In MinCutKarger, we have the following statistics:

  • the longest discovery time takes is seconds, corresponding to the graph input_random_38_200.txt;
  • the longest full_contraction execution takes 9 milliseconds, corresponding to the graph input_random_40_200.txt;
  • the average running time is 176 seconds;
  • the average discovery_time / program_time ratio is 0,142401742 when no timeout is used;
  • the maximum discovery_time / program_time ratio is 0,897164825 when no timeout is used, corresponding to the graph input_random_1_6.txt.
  • the second-highest discovery_time / program_time ratio is 0.833009709 when no timeout is used, corresponding to the graph input_random_4_6.txt

Complete TODOs in section "Performance Analysis"

  • fix unità di misura nel grafico "Confronto del running time rispetto al numero di nodi per Karger e Karger con Timeout"
  • il grafico "Confronto tra il tempo di esecuzione per discovery time e runtime rispetto al numero di nodi" deve avere la scala in secondi
  • mostrare il confronto tra iterazione del discovery time e numero di iterazioni k stimate
  • mostrare la tabella dei tempi di esecuzione sia di KargerMinCut che di KargerMinCutTimeout, con colonne istanza, nodi, discovery time, program time. Le righe devono essere ordinate per numero crescente di nodi e istanza
  • rinominare KargerTimeout in KargerMinCutTimeout
  • mostrare la tabella di KargerMinCutTimeout, con colonne istanza, nodi, soluzione attesa, min-cut. Le righe devono essere ordinate per numero crescente di nodi istanza
  • rinominare legenda del grafico "Confronto discovery iteration stimata vs ottenuta rispetto al numero di nodi per
    KargerMinCut" da Estimated a K (o upper bound) e non calcolarla a mano, utilizzare la k del benchmark
  • rinominare program time in runtime nel report
  • sul grafico "Confronto tra il tempo di esecuzione di full_contraction e la sua complessità asintotica
    rispetto al numero di nodi" scrivere n^2 nella legenda dove c'è asintotico e mettere limite inferiore al logaritmo (linea blu)
  • statistiche full contraction tabella in appendice

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.