message
stringlengths
5
481
model_input
stringlengths
47
2.9k
input_ids
list
attention_mask
list
labels
list
Feature: update cli args with kwargs This lets a user run main() in a stand-alone script, e.g. with a debugger
MODIFY powergenome/run_powergenome_multiple_outputs_cli.py powergenome/run_powergenome_multiple_outputs_cli.py @@ -134,9 +134,10 @@ def parse_command_line(argv): return arguments -def main(): +def main(**kwargs): args = parse_command_line(sys.argv) + args.__dict__.update(kwargs) cwd = Path.cwd() out_folder = cwd / args...
[ 1, 6720, 12096, 203, 12238, 23220, 19, 2681, 67, 12238, 23220, 67, 9622, 67, 12295, 67, 4857, 18, 2074, 203, 12238, 23220, 19, 2681, 67, 12238, 23220, 67, 9622, 67, 12295, 67, 4857, 18, 2074, 203, 30989, 300, 25213, 16, 29, 397, 252...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ 1, 4595, 30, 1089, 4942, 833, 598, 1205, 203, 2503, 14557, 279, 729, 1086, 2774, 1435, 316, 279, 12842, 17, 12451, 2728, 16, 425, 18, 75, 18, 598, 279, 19977, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
Fix: properly align indices when filling op date
MODIFY powergenome/generators.py powergenome/generators.py @@ -968,20 +968,24 @@ def update_operating_date_860m( The original "df" dataframe with missing operating dates filled using the operating year from 860m. """ - no_op_date = df.loc[df["operating_date"].isna(), :] + _df = df.set_index(["plant_id_eia", "generator_...
[ 1, 6720, 12096, 203, 12238, 23220, 19, 25959, 18, 2074, 203, 12238, 23220, 19, 25959, 18, 2074, 203, 30989, 300, 29, 9470, 16, 3462, 397, 29, 9470, 16, 3247, 22175, 1652, 1089, 67, 4063, 1776, 67, 712, 67, 28, 4848, 81, 12, 203, 1...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ 1, 8585, 30, 8214, 5689, 4295, 1347, 25740, 1061, 1509, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -10...
Reset indices when removing gens
MODIFY powergenome/generators.py powergenome/generators.py @@ -880,7 +880,7 @@ def remove_canceled_860m(df, canceled_860m): if not canceled.empty: assert len(df) == len(canceled) + len(not_canceled_df) - return not_canceled_df + return not_canceled_df.reset_index(drop=True) def remove_retired_860m(df, retired_860m): @@...
[ 1, 6720, 12096, 203, 12238, 23220, 19, 25959, 18, 2074, 203, 12238, 23220, 19, 25959, 18, 2074, 203, 30989, 300, 28, 3672, 16, 27, 397, 28, 3672, 16, 27, 22175, 1652, 1206, 67, 10996, 329, 67, 28, 4848, 81, 12, 2180, 16, 17271, 67...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ 1, 7013, 4295, 1347, 9427, 314, 773, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
Bug fix: make copy of input df to avoid modifying In some cases the operating_860m df was being modified and would cause an error on subsequent calculations.
MODIFY powergenome/generators.py powergenome/generators.py @@ -1687,17 +1687,18 @@ def import_new_generators( pd.DataFrame Set of operating generators that were not already in the gens_860 dataframe """ - operating_860m["generator_id"] = operating_860m["generator_id"].apply( + _operating_860m = operating_860m.copy() + ...
[ 1, 6720, 12096, 203, 12238, 23220, 19, 25959, 18, 2074, 203, 12238, 23220, 19, 25959, 18, 2074, 203, 30989, 300, 2313, 11035, 16, 4033, 397, 2313, 11035, 16, 2643, 22175, 1652, 1930, 67, 2704, 67, 25959, 12, 203, 22353, 18, 25696, 203...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ 1, 19865, 2917, 30, 1221, 1610, 434, 810, 3013, 358, 4543, 21920, 203, 382, 2690, 6088, 326, 16929, 67, 28, 4848, 81, 3013, 1703, 3832, 4358, 471, 4102, 4620, 392, 203, 1636, 603, 10815, 20882, 18, 2, -100, -100, -100, -100, -100, -...
Bug fix: unpack kwargs for function using lru_cache
MODIFY powergenome/price_adjustment.py powergenome/price_adjustment.py @@ -207,7 +207,7 @@ def inflation_price_adjustment( if cpi_data["year"].max() < max(target_year, base_year): logger.info("Updating CPI data") kwargs.update({"end_year": target_year}) - cpi_data = load_cpi_data(reload_data=True, data_path=data_path, ...
[ 1, 6720, 12096, 203, 12238, 23220, 19, 8694, 67, 13362, 475, 18, 2074, 203, 12238, 23220, 19, 8694, 67, 13362, 475, 18, 2074, 203, 30989, 300, 3462, 27, 16, 27, 397, 3462, 27, 16, 27, 22175, 1652, 13947, 367, 67, 8694, 67, 13362, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ 1, 19865, 2917, 30, 6167, 1205, 364, 445, 1450, 23227, 67, 2493, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, ...