/InternetSpeedTest

Tool to benchmark internet speeds and provide detailed analysis results

Primary LanguagePython

InternetSpeedTest

This repository consists of a few python scripts to automate the process of testing your internet connection and generating a linear regression model for the same. Models ping, download speed, upload speed vs distance, size. Makes use of Speedtest-cli by sivel as backbone for generating model for ping, downlaod speed, upload sped vs distance. This model generated is very rich and detailed. While makes use of TELE2 for making multi variable linear model incorporating ping,downlaod speed, upload speed vs distance, file size. This model is not as rich as the previous one since it is dependent highly on TELE2 as a service which doesn't provide a very good spread on distance

Repository Contents

  • src
    • speedTestMultiServer.py: This script will run commands with the speedtest-cli. It extracts list of servers on speedtest.net and then hits each of the servers to perform tests. The results are then saved in results.csv
    • processData.py: This script extracts data from results.csv and generates a linear regression model from the data. By default model is made for downloadSpeed vs distance, file can be changed to model other aspects.
    • sizeTest.py: This runs tests on TELE2 and generates sizeResults.csv which contains server_name, size, upload/download operation performed, speed and time taken.
    • processSizes.py: This script takes sizeResults.csv as input and processes the data to make a multivariable linear model.

Dependencies

  • Requires Python 2.7
  • Requires following python packages
    • subprocess
    • os
    • pyplot
    • numpy
    • statsmodel
    • seaborn
    • pandas

Use

  1. Clone speedtest-cli
  2. Move src folder inside speedtest-cli/
  3. Run in following order
  4. speedtestMultiServer.py
  5. processData.py (options can be changed by uncommenting lines for different results)
  6. sizeTest.py
  7. processSizes.py (options can be changed by uncommenting lines for different results)