Skip to content

Codebase for the MLCost application developed for my thesis for the Telecommunications Enginnering bachelor, Universidad Rey Juan Carlos

License

Notifications You must be signed in to change notification settings

l-gonz/tfg-gitt-mlcost

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

76 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Machine learning model cost comparison dashboard

This python script runs a comparison of several machine learning models on a dataset and outputs the accuracy of the model, the time employed for training and the CO2 emissions generated by the process. CO2 emissions are calculated using CodeCarbon.

An example of the measures obtained for the included datasets can be seen on the output file.

Setup

The program has been tested on Ubuntu 20.04 with Python 3.8. Necessary system packages:

python3.8-tk (GUI for matplotlib graphs)
stress (simulated stress conditions for CPU tests)
  1. Clone repository and change directory to the created folder
  2. Create virtual environment for managing dependencies
python3 -m venv venv
  1. Activate the environment
source venv/bin/activate
  1. Install packages with PIP
pip install -r requirements.txt
  1. Install the MLCost package in editable mode (to make changes)
pip install -e .

Execution

Run the program without any options to use the default Iris dataset.

There are several larger datasets available for testing in the data folder:

  • To run the program with a specific dataset, use the -d option.
  • To specify a separate file with the test data, use the -t option.
  • If the dataset uses a different format from a standard comma-separated values, use the -s to specify the separator.

Examples

Adult dataset

mlcost measure -d data/adult/adult.data -t data/adult/adult.test -s ", "

Hepatitis dataset

mlcost measure -d data/hepatitis/hepatitis.data

About

Codebase for the MLCost application developed for my thesis for the Telecommunications Enginnering bachelor, Universidad Rey Juan Carlos

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published