This project calculates energy savings from EMS data using CSV files and generates a summary in an Excel file. It processes monthly data to compute savings and aggregates yearly totals.
scripts/: Directory containing the scripts used for calculating savings from the data.genset_fuel_savings.py: Script for calculating genset fuel savings.power_factor_savings.py: Script for calculating power factor savings.frequency_savings.py: Script for calculating frequency savings.voltage_stability_savings.py: Script for calculating voltage stability savings.harmonics_savings.py: Script for calculating harmonics savings.
config/savings_config.json: Configuration file containing year, site, and cost details.data/: Directory containing the CSV data files.genset_savings_data/: Directory containing genset savings data.power_factor_savings_data/: Directory containing power factor savings data.frequency_data/: Directory containing frequency data.voltage_data/: Directory containing voltage data.harmonics_data/: Directory containing harmonics data.yield_data/: Directory containing yield data.
- Python 3.x
- A
requirements.txtfile is included in the repository, listing all the necessary Python libraries and dependencies needed to run the scripts.
- Clone the repository:
git clone https://github.com/tinegachris/genset_savings_calculator.git
cd genset_savings_calculator- Install the required libraries:
pip install -r requirements.txtEnsure your Python environment is properly set up and activated before installing the dependencies.
If you add new dependencies, update the requirements.txt file by running:
pip freeze > requirements.txt- Update the configuration file
config/savings_config.jsonwith the appropriate details. - Place the monthly savings CSV files in the
data/[savings_data]/directory. - Run the main script:
python scripts/genset_fuel_savings.pyThe output will be an Excel file saved in the results/ directory, containing a summary of the savings calculated.
If you have an idea for an improvement or have found a bug, please open an issue or submit a pull request. For major changes, please open an issue first to discuss what you would like to change.
- Fork the repository.
- Create a new branch (
git checkout -b feature-branch). - Make your changes.
- Commit your changes (
git commit -am 'Add new feature'). - Push to the branch (
git push origin feature-branch). - Open a pull request.
This project is licensed under the BSD 2-Clause License. See the LICENSE file for details.
