See Project Proposal.md
for project proposal details.
See Writeup.md
for post-project reflection writeup.
Click here for the presentation video.
Presumes running with cmake and make installed and ready to go; then, similarly to our in-class usage:
Setup: mkdir c++/build && cd c++/build && cmake .. && make
Run: ./main <filename>
. Provide the filename of a file produced by the Python section of the project (eg. ../../Python/demofile1.txt
).
Test: ./test
Or, manually:
- Make subdirectory of
c++/
for build output (eg.c++/build
). - In that directory, run
cmake ..
- Compile using
make
, execute using./main <filename>
(path relative tobuild
), and test using./test
Note that if the file is supplied incorrectly, a blank output may be returned.
Requires Python 3 and pip. A couple example files have been provided if you prefer not to use this step.
apt-get update && apt-get install -y pip
to install Python and pip if needed.cd Python && pip install -r requirements.txt
- Remain in the Python folder and run
python interactive_data_getter.py
orpython3 interactive_data_getter.py
depending on your install. Supply a filename of your choice and a Spotify playlist ID, or use the defaults (but that's boring).
Assumes test executable exists:
Testing BFS: ./test "BFS"
.
Input to BFS test is a starting index and a destination index, inputted in that order. Returns, if available, the shortest unweighted path between start and end.
Testing Dijkstra's: ./test "Dijkstra's"
.
Input to Dijkstra's test is a starting index. The output will show, if available, the shortest path available to all other vertices (songs).
Testing Betweenness Centrality: ./test "Betweenness Centrality"
.
Input to Betweenness Centrality is the index of the song of interest. Returns the "centrality" of the inputted song index. The test case displays centrality for all songs.