Breakthrough-Energy / PreREISE

Generate input data for scenario framework
https://breakthrough-energy.github.io/docs/
MIT License
20 stars 28 forks source link

refactor: move to common data columns #311

Closed dmuldrew closed 1 year ago

dmuldrew commented 1 year ago

Pull Request doc

Purpose

Help merge the existing LDV and HDV implementations into a common implementation.

This PR also makes charging_efficiency a parameter in the get_constraints and calculate_optimization functions, which is part of one of the other work items: https://github.com/Breakthrough-Energy/PreREISE/issues/308

What the code is doing

  1. Move LDV/HDV list constants into const.py
  2. Defines dataset column name transformations for LDV and HDV datasets
  3. Transforms the LDV dataset to use the standardized data columns
  4. Changes immediate.py and smart_charging.py to use these standardized data columns, which will also work for the HDV case

The plan for the next PR is to have the immediate.py and smart_charging.py code to handle the HDV case and eliminate the extra HDV files. I'll also update with HDV-specific integration tests.

Testing

existing integration tests pass

Where to look

Look at ldv_columns_transform and hdv_columns_transform in const.py. The LDV columns are transformed in data_helper.py.

Time estimate

~10-20min