Git Product home page Git Product logo

cse6140_tsp's Introduction

CSE6140 Group Project

Getting Started

Download DATA.zip from Canvas and extract all files to the data/ directory.

Run the program using the following script

python run_tsp.py -inst <filename> -alg [BF | Approx | LS] -time <cutoff_in_seconds> -seed <random_seed>

For example, to run brute force:

  • python run_tsp.py -inst Atlanta.tsp -alg BF -time 600 -seed 0: run the brute force algorithm on the Atlanta graph in the data/ directory.

To run local search:

  • python run_tsp.py -inst Atlanta.tsp -alg LS -time 600 -seed 0

To run approximation:

  • python run_tsp.py -inst Atlanta.tsp -alg Approx -time 600 -seed 0

Alternatively, you can also use our provided exec file, which is just a bash script:

  • ./exec -inst Atlanta.tsp -alg BF -time 600 -seed 0
  • ./exec -inst Atlanta.tsp -alg LS -time 600 -seed 0
  • ./exec -inst Atlanta.tsp -alg Approx -time 600 -seed 0

Requirements

python >= 3.6

Notes

Generating an executable from our Python file

We will need PyInstaller.

  1. Install PyInstaller: PyInstaller can be installed using pip. Open your terminal and run:

  2. pip install pyinstaller
  3. Create the Executable: Navigate to the project directory CSE6140_TSP run the following command:

  4. Generate the executable

    pyinstaller --onefile run_tsp.py

    The --onefile option tells PyInstaller to package everything into a single executable file.

  5. Generate the executable

    pyinstaller --onefile run_tsp.py

cse6140_tsp's People

Contributors

tinaaa60 avatar ahren09 avatar edisonwhale avatar bwtang524 avatar wenhaomu avatar

Watchers

 avatar  avatar

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.