When you supply information via a REST or command line submission EMHASS does not process what is in the UI, and is uses the data submitted instead. So it doesn’t matter if you choose csv or hc_pc as that won’t be used.
When I look at the output from your dev.tools template it doesn’t look like valid JSON. I believe this is your output? Is this what you are outputting?
{
"load_cost_forecast": [32.895, 34.81, 31.705, 16.837, 5.526, 5.02, 4.664, 4.787, 6.756, 10.846, 76.198, 105.782, 94.239, 84.391, 69.4, 50.32, 41.115]
"prod_price_forecast": [32.895, 34.81, 31.705, 16.837, 5.526, 5.02, 4.664, 4.787, 6.756, 10.846, 76.198, 105.782, 94.239, 84.391, 69.4, 50.32, 41.115]
"prediction_horizon": 24
}
Valid JSON requiures a comma at the end of each line except that last line.
When I past this output into a JSON validator it comes back with this:
Parse error on line 2:
..., 50.32, 41.115]
"prod_price_forecast...
---------------------^
Expecting 'EOF', '}', ',', ']', got 'STRING'
Add some commas and I get this valid JSON:
{
"load_cost_forecast": [
32.895,
34.81,
31.705,
16.837,
5.526,
5.02,
4.664,
4.787,
6.756,
10.846,
76.198,
105.782,
94.239,
84.391,
69.4,
50.32,
41.115
],
"prod_price_forecast": [
32.895,
34.81,
31.705,
16.837,
5.526,
5.02,
4.664,
4.787,
6.756,
10.846,
76.198,
105.782,
94.239,
84.391,
69.4,
50.32,
41.115
],
"prediction_horizon": 24
}
See the extra commas?
I can’t test you Jinja2 template but I suspect if you change it to this:
rest_command:
trigger_nordpool_forecast:
url: "http://192.168.10.3:5000/action/dayahead-optim"
method: POST
headers:
Content-Type: "application/json"
payload: >
{
"load_cost_forecast": {{ (
(state_attr('sensor.nordpool_kwh_se3_sek_3_10_025', 'raw_today') | map(attribute='value') | list
+ state_attr('sensor.nordpool_kwh_se3_sek_3_10_025', 'raw_tomorrow') | map(attribute='value') | list
)[0:24] | tojson }},
"prod_price_forecast": {{ (
(state_attr('sensor.nordpool_kwh_se3_sek_3_10_025', 'raw_today') | map(attribute='value') | list
+ state_attr('sensor.nordpool_kwh_se3_sek_3_10_025', 'raw_tomorrow') | map(attribute='value') | list
)[0:24] | tojson }},
"prediction_horizon": 24
}
Note the commas at the end of the “prod_price_forecast” and “load_cost_forecast” lines. Does this solve the 500 error?
Take the output from your dev template output and test it in a JSON validator or POST it to your server from a Mac terminal session:
curl -X POST http://192.168.10.3:5000/action/dayahead-optim \
-H "Content-Type: application/json" \
-d '{
"load_cost_forecast": [32.895, 34.81, 31.705, 16.837, 5.526, 5.02, 4.664, 4.787, 6.756, 10.846, 76.198, 105.782, 94.239, 84.391, 69.4, 50.32, 41.115],
"prod_price_forecast": [32.895, 34.81, 31.705, 16.837, 5.526, 5.02, 4.664, 4.787, 6.756, 10.846, 76.198, 105.782, 94.239, 84.391, 69.4, 50.32, 41.115],
"prediction_horizon": 24
}'
I think this is correct but don’t take my word for it. I can’t test it.
Using curl from a terminal session is just another way to test.
As for the CSV input, I’ve never used CSV files in EMHASS for anything. I know you can provide some of this data using CSV files rather than restful api but I’ve never looked into it.
I think thats is what this CSV setting is that you refer to. My system us set to hp_hc not CSV.
The commas are back in the template, and the dev.tools return this when running the whole template:
the commas are present at end of each array. But right now i only get 12 datapoints, probably because the Nordpool only updates once a day in afternoon (13.30 i think)
When i now post the json output from the dev.tool in the validator it looks legit?
I understand from @altonius that the GUI selection dont matter once posting a REST.
I will try to post in my terminal once back on my home network again tomorrow. I can access home assistant over https using duckdns and nginx, but guess i cant run the command from the homeassistant terminal over this online route? Right now enjoying the ruins of swedish railway, with 2 hours delay on a 350km trip. But the networkconnection is at least good ![]()
Is a countdown timer required for the thermal load model, just like normal deferrables? I want to use thermal model in a rolling window mpc setup.
You need to dynamically modify the prediction horizon to match your data. I think I posted my code on how I do that above. here it is for only the data dictionaries you are passing:
{#-- Calculate prediction horizon as the shortest data length --#}
"prediction_horizon": {{
[prod_price_forecast | length,
load_cost_forecast | length] | min -1
}},
This just checks each line length and selects the minimum.
Change your code to this and see if it works:
rest_command:
trigger_nordpool_forecast:
url: "http://192.168.10.3:5000/action/dayahead-optim"
method: POST
headers:
Content-Type: "application/json"
payload: >
{
"load_cost_forecast": {{ (
(state_attr('sensor.nordpool_kwh_se3_sek_3_10_025', 'raw_today') | map(attribute='value') | list
+ state_attr('sensor.nordpool_kwh_se3_sek_3_10_025', 'raw_tomorrow') | map(attribute='value') | list
)[0:24] | tojson }},
"prod_price_forecast": {{ (
(state_attr('sensor.nordpool_kwh_se3_sek_3_10_025', 'raw_today') | map(attribute='value') | list
+ state_attr('sensor.nordpool_kwh_se3_sek_3_10_025', 'raw_tomorrow') | map(attribute='value') | list
)[0:24] | tojson }},
"prediction_horizon": {{ [prod_price_forecast | length, load_cost_forecast | length] | min -1 }}
}
Nope. Had to modify your code, original gave syntax error. Duck.ai came up with the following;
rest_command:
trigger_nordpool_forecast:
url: "http://192.168.10.3:5000/action/dayahead-optim"
method: POST
headers:
Content-Type: "application/json"
payload: >
{
"load_cost_forecast": {{ (
(state_attr('sensor.nordpool_kwh_se3_sek_3_10_025', 'raw_today') | map(attribute='value') | list
+ state_attr('sensor.nordpool_kwh_se3_sek_3_10_025', 'raw_tomorrow') | map(attribute='value') | list
)[0:24] | tojson) }},
"prod_price_forecast": {{ (
(state_attr('sensor.nordpool_kwh_se3_sek_3_10_025', 'raw_today') | map(attribute='value') | list
+ state_attr('sensor.nordpool_kwh_se3_sek_3_10_025', 'raw_tomorrow') | map(attribute='value') | list
)[0:24] | tojson) }},
"prediction_horizon": {{ [(
(state_attr('sensor.nordpool_kwh_se3_sek_3_10_025', 'raw_today') | map(attribute='value') | list
+ state_attr('sensor.nordpool_kwh_se3_sek_3_10_025', 'raw_tomorrow') | map(attribute='value') | list
)[0:24] | length), (
(state_attr('sensor.nordpool_kwh_se3_sek_3_10_025', 'raw_today') | map(attribute='value') | list
+ state_attr('sensor.nordpool_kwh_se3_sek_3_10_025', 'raw_tomorrow') | map(attribute='value') | list
)[0:24] | length)] | min - 1 }}
}
Validated with dev.tools and jsonformatter.org
Still get same error 500 when running.
It looks like in the logs, that;
a) the nordpool data is not overwriting the “hp_hc periods”. Supported by the error 500 when running rest_command from dev.tools.
b) The day-ahead optimization does not give any result what so ever, even with the “hp_hc” prices shown in the log. Must be something else thats wrong in my setup too???
Closed down battery and PV to narrow down the problem. This is how setup now looks;
the sensor solar_panel_production_w is working;
as well as the solcast_pv_forecast_power_now:
and solar_house_consumption_w:
The config:
Could it be an error in automations.yaml like described here:
https://community.home-assistant.io/t/response-error-500/291887/11
Here’s another example of dynamic prediction horison template from Johan71 in this forum above:
"prediction_horizon":{{min(24, (((state_attr("sensor.nordpool_kwh_se3_sek_3_10_025", "raw_today")|map(attribute="value")|list + state_attr("sensor.nordpool_kwh_se3_sek_3_10_025", "raw_tomorrow") | map(attribute="value")| list)[now().hour:][:48]|list|length)))}},
However I think this is for a time slice of 30 minutes. Not sure what you are working with now? Has Nordpool moved to 15 minutes?
Anyway, looking at your configuration. This is my config:
{
"adjusted_pv_regression_model": "LassoRegression",
"adjusted_pv_solar_elevation_threshold": 10,
"battery_charge_efficiency": 0.95,
"battery_charge_power_max": 3300,
"battery_discharge_efficiency": 0.9,
"battery_discharge_power_max": 3300,
"battery_dynamic_max": 0.9,
"battery_dynamic_min": -0.9,
"battery_maximum_state_of_charge": 1,
"battery_minimum_state_of_charge": 0,
"battery_nominal_energy_capacity": 13950,
"battery_target_state_of_charge": 0,
"compute_curtailment": false,
"continual_publish": false,
"costfun": "profit",
"delta_forecast_daily": 1,
"end_timesteps_of_each_deferrable_load": [
0,
0
],
"historic_days_to_retrieve": 2,
"inverter_is_hybrid": false,
"load_cost_forecast_method": "hp_hc_periods",
"load_forecast_method": "naive",
"load_negative": false,
"load_offpeak_hours_cost": 0.1419,
"load_peak_hour_periods": {
"period_hp_1": [
{
"start": "02:54"
},
{
"end": "15:24"
}
],
"period_hp_2": [
{
"start": "17:24"
},
{
"end": "20:24"
}
]
},
"load_peak_hours_cost": 0.1907,
"logging_level": "INFO",
"lp_solver": "COIN_CMD",
"lp_solver_path": "empty",
"lp_solver_timeout": 45,
"maximum_power_from_grid": 14490,
"maximum_power_to_grid": 9000,
"method_ts_round": "first",
"minimum_power_of_deferrable_loads": [
0,
0
],
"modules_per_string": [
17
],
"nominal_power_of_deferrable_loads": [
1300,
7300
],
"num_threads": 0,
"number_of_deferrable_loads": 2,
"open_meteo_cache_max_age": 30,
"operating_hours_of_each_deferrable_load": [
2,
1
],
"optimization_time_step": 30,
"photovoltaic_production_sell_price": 0.1419,
"production_price_forecast_method": "constant",
"pv_inverter_model": [
"Fronius_International_GmbH__Fronius_Primo_6_0_1_208_240__240V_"
],
"pv_module_model": [
"CSUN_Eurasia_Energy_Systems_Industry_and_Trade_CSUN295_60M"
],
"sensor_linear_interp": [
"sensor.house_power_consumption_less_deferrables"
],
"sensor_power_load_no_var_loads": "sensor.house_power_consumption_less_deferrables",
"sensor_power_photovoltaics": "sensor.sonnenbatterie_84324_production_w",
"sensor_power_photovoltaics_forecast": "sensor.p_pv_forecast",
"sensor_replace_zero": [
"sensor.sonnenbatterie_84324_production_w"
],
"set_battery_dynamic": true,
"set_deferrable_load_single_constant": [
false,
false
],
"set_deferrable_startup_penalty": [
0,
0
],
"set_nocharge_from_grid": false,
"set_nodischarge_to_grid": false,
"set_total_pv_sell": false,
"set_use_adjusted_pv": false,
"set_use_battery": true,
"set_use_pv": true,
"set_zero_min": true,
"start_timesteps_of_each_deferrable_load": [
0,
0
],
"strings_per_inverter": [
1
],
"surface_azimuth": [
10
],
"surface_tilt": [
21
],
"treat_deferrable_load_as_semi_cont": [
true,
false
],
"weather_forecast_method": "open-meteo",
"weight_battery_charge": 0,
"weight_battery_discharge": 0
}
Maybe. Went through all the automations. Still no go.
Yes! Finally some progress ![]()
Reinstalled EMHASS, and applied your config. Just changed the ```
“sensor_power_load_no_var_loads”, “sensor_power_photovoltaics”, and
“sensor_power_photovoltaics_forecast”
The error 500 is gone, and finally i actually can run the dayahead optimization and get a graph again!
Not that it imports the Nordpool-data, but atleast a graph!
Nordpool still runs on 1h, will move to 15min 1/10.
I am now down to trying to post just a fixed list of numbers with the rest_command. Nu success.
method: POST
headers:
Content-Type: "application/json"
payload: >
{
"pv_power_forecast": [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24],
"prediction_horizon": 24,
"prod_price_forecast": [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24],
"load_cost_forecast": [25, 26, 27, 28, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44]
}
But there is absolutely none of these values posted in the “table” after running the day-ahead optimization. The unit_load_cost is still showing the hc_lc values. aso.
The timestep is set to 60, and as you see i only try to pass arrays with 24 values in each.
Why cant i get these values into emhass??
Your load_cost_forecast is missing three values. If you have a prediction_horizon of 24 you need 24 values for each data dictionary and you have only 21 load_cost_forecast? You could reduce the prediction_horizon to 21 and it will probably work.
Hi, using the thermal model for my waterpumpboiler. P_deferrable3 = DHW
Results of the optimization doesn’t make sense to me:
Heating up will price is high, battery is empty and 1h later there is plenty of PV power available.
This was more than usually stupid by me…Thnx for pointing out the wrong numbers!
So, added up to 24 in each row. Still not working.
Notice in the output that it keeps publishing in 30min. timesteps despite the timestep set to 60 in config.
Changed the rows to 48numbers, and NOW they go through and into the publish!
SO, there seem to be a problem with the change of timestep in the config file, that is not updated in EMHASS, that keep running on 30min. timestep!
This is now the rest_command array:
payload: >
{
"pv_power_forecast": [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24],
"prediction_horizon": 24,
"prod_price_forecast": [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24],
"load_cost_forecast": [25, 26, 27, 28, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 25, 26, 27, 28, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47]
}
From /share/config.json
{
"logging_level": "INFO",
"costfun": "profit",
"optimization_time_step": 60,
"historic_days_to_retrieve": 2,
"method_ts_round": "first",
"continual_publish": false,
"data_path": "default",
"set_total_pv_sell": false,
"lp_solver": "COIN_CMD",
From GUI:
From publish, picture of middle of the table (to save space in thread that i already occupy quite alot) as seen it publish 30min timesteps, and the “numbers” start over from 24 to 1:
Can you post your complete configuration in JSON format (select the <> symbol at the top of the configuration UI) and your logfile.
{
"adjusted_pv_regression_model": "LassoRegression",
"adjusted_pv_solar_elevation_threshold": 10,
"battery_charge_efficiency": 0.95,
"battery_charge_power_max": 3300,
"battery_discharge_efficiency": 0.9,
"battery_discharge_power_max": 3300,
"battery_dynamic_max": 0.9,
"battery_dynamic_min": -0.9,
"battery_maximum_state_of_charge": 1,
"battery_minimum_state_of_charge": 0,
"battery_nominal_energy_capacity": 5000,
"battery_target_state_of_charge": 0,
"compute_curtailment": false,
"continual_publish": false,
"costfun": "profit",
"delta_forecast_daily": 2,
"end_timesteps_of_each_deferrable_load": [
0,
0
],
"historic_days_to_retrieve": 2,
"inverter_ac_input_max": 1000,
"inverter_ac_output_max": 1000,
"inverter_efficiency_ac_dc": 1,
"inverter_efficiency_dc_ac": 1,
"inverter_is_hybrid": false,
"load_cost_forecast_method": "hp_hc_periods",
"load_forecast_method": "naive",
"load_negative": false,
"load_offpeak_hours_cost": 0.1419,
"load_peak_hour_periods": {
"period_hp_1": [
{
"start": "02:54"
},
{
"end": "15:24"
}
],
"period_hp_2": [
{
"start": "17:24"
},
{
"end": "20:24"
}
]
},
"load_peak_hours_cost": 0.1907,
"logging_level": "INFO",
"lp_solver": "COIN_CMD",
"lp_solver_path": "empty",
"lp_solver_timeout": 45,
"maximum_power_from_grid": 14490,
"maximum_power_to_grid": 9000,
"method_ts_round": "first",
"minimum_power_of_deferrable_loads": [
0,
0
],
"modules_per_string": [
17
],
"nominal_power_of_deferrable_loads": [
1300,
7300
],
"num_threads": 0,
"number_of_deferrable_loads": 2,
"open_meteo_cache_max_age": 30,
"operating_hours_of_each_deferrable_load": [
2,
1
],
"optimization_time_step": 60,
"photovoltaic_production_sell_price": 0.1419,
"production_price_forecast_method": "constant",
"pv_inverter_model": [
"Fronius_International_GmbH__Fronius_Primo_6_0_1_208_240__240V_"
],
"pv_module_model": [
"CSUN_Eurasia_Energy_Systems_Industry_and_Trade_CSUN295_60M"
],
"sensor_linear_interp": [
"sensor.power_myhouse_load_no_var_loads"
],
"sensor_power_load_no_var_loads": "sensor.power_myhouse_load_no_var_loads",
"sensor_power_photovoltaics": "sensor.solar_panel_production_w",
"sensor_power_photovoltaics_forecast": "sensor.p_pv_forecast",
"sensor_replace_zero": [
"sensor.solar_battery_out_to_grid_and_house_w"
],
"set_battery_dynamic": true,
"set_deferrable_load_single_constant": [
false,
false
],
"set_deferrable_startup_penalty": [
0,
0
],
"set_nocharge_from_grid": false,
"set_nodischarge_to_grid": false,
"set_total_pv_sell": false,
"set_use_adjusted_pv": false,
"set_use_battery": true,
"set_use_pv": true,
"set_zero_min": true,
"start_timesteps_of_each_deferrable_load": [
0,
0
],
"strings_per_inverter": [
1
],
"surface_azimuth": [
10
],
"surface_tilt": [
21
],
"treat_deferrable_load_as_semi_cont": [
true,
false
],
"weather_forecast_method": "open-meteo",
"weight_battery_charge": 0,
"weight_battery_discharge": 0
}
[2025-09-19 10:57:11 +0200] [23] [INFO] >> Obtaining params:
[2025-09-19 10:57:11 +0200] [23] [INFO] Passed runtime parameters: {'pv_power_forecast': [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24], 'prediction_horizon': 24, 'prod_price_forecast': [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24], 'load_cost_forecast': [25, 26, 27, 28, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 25, 26, 27, 28, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47]}
[2025-09-19 10:57:11 +0200] [23] [INFO] >> Setting input data dict
[2025-09-19 10:57:11 +0200] [23] [INFO] Setting up needed data
[2025-09-19 10:57:11 +0200] [23] [DEBUG] setting`passed_data:days_to_retrieve` to 9 for fit/predict/tune
[2025-09-19 10:57:11 +0200] [23] [WARNING] lp_solver=COIN_CMD but lp_solver_path=empty, attempting to use lp_solver_path=/usr/bin/cbc
[2025-09-19 10:57:11 +0200] [23] [DEBUG] Initialized Optimization with retrieve_hass_conf: {'optimization_time_step': Timedelta('0 days 00:30:00'), 'historic_days_to_retrieve': 2, 'sensor_power_photovoltaics': 'sensor.solar_panel_production_w', 'sensor_power_photovoltaics_forecast': '', 'sensor_power_load_no_var_loads': 'sensor.power_myhouse_load_no_var_loads', 'load_negative': False, 'set_zero_min': True, 'sensor_replace_zero': ['sensor.solar_battery_out_to_grid_and_house_w'], 'sensor_linear_interp': ['sensor.power_myhouse_load_no_var_loads'], 'method_ts_round': 'first', 'continual_publish': False, 'hass_url': 'http://supervisor/core/api', 'long_lived_token': '0ada82ed9790c72e5da7263eec5930234008b6ac5c2fb0b63403966ef5ed53649a4c7544131d8eb7c73e168cba0fd6e700685df7356bc9eb', 'time_zone': <DstTzInfo 'Europe/Stockholm' LMT+0:53:00 STD>, 'Latitude': 57.85885, 'Longitude': 14.305337, 'Altitude': 16}
[2025-09-19 10:57:11 +0200] [23] [DEBUG] Optimization configuration: {'costfun': 'profit', 'logging_level': 'INFO', 'set_use_pv': True, 'set_use_adjusted_pv': False, 'adjusted_pv_regression_model': 'LassoRegression', 'adjusted_pv_solar_elevation_threshold': 10, 'set_use_battery': True, 'number_of_deferrable_loads': 2, 'nominal_power_of_deferrable_loads': [1300, 7300], 'minimum_power_of_deferrable_loads': [0, 0], 'operating_hours_of_each_deferrable_load': [2, 1], 'treat_deferrable_load_as_semi_cont': [True, False], 'set_deferrable_load_single_constant': [False, False], 'set_deferrable_startup_penalty': [0, 0], 'delta_forecast_daily': Timedelta('1 days 00:00:00'), 'load_forecast_method': 'naive', 'load_cost_forecast_method': 'list', 'load_peak_hours_cost': 0.1907, 'load_offpeak_hours_cost': 0.1419, 'production_price_forecast_method': 'list', 'photovoltaic_production_sell_price': 0.1419, 'set_total_pv_sell': False, 'lp_solver': 'COIN_CMD', 'lp_solver_path': 'empty', 'lp_solver_timeout': 45, 'num_threads': 0, 'set_nocharge_from_grid': False, 'set_nodischarge_to_grid': False, 'set_battery_dynamic': True, 'battery_dynamic_max': 0.9, 'battery_dynamic_min': -0.9, 'weight_battery_discharge': 0, 'weight_battery_charge': 0, 'weather_forecast_method': 'list', 'open_meteo_cache_max_age': 30, 'start_timesteps_of_each_deferrable_load': [0, 0], 'end_timesteps_of_each_deferrable_load': [0, 0], 'load_peak_hour_periods': {'period_hp_1': [{'start': '02:54'}, {'end': '15:24'}], 'period_hp_2': [{'start': '17:24'}, {'end': '20:24'}]}}
[2025-09-19 10:57:11 +0200] [23] [DEBUG] Plant configuration: {'maximum_power_from_grid': 14490, 'maximum_power_to_grid': 9000, 'pv_module_model': ['CSUN_Eurasia_Energy_Systems_Industry_and_Trade_CSUN295_60M'], 'pv_inverter_model': ['Fronius_International_GmbH__Fronius_Primo_6_0_1_208_240__240V_'], 'surface_tilt': [21], 'surface_azimuth': [10], 'modules_per_string': [17], 'strings_per_inverter': [1], 'inverter_is_hybrid': False, 'inverter_ac_output_max': 1000, 'inverter_ac_input_max': 1000, 'inverter_efficiency_dc_ac': 1, 'inverter_efficiency_ac_dc': 1, 'compute_curtailment': False, 'battery_discharge_power_max': 3300, 'battery_charge_power_max': 3300, 'battery_discharge_efficiency': 0.9, 'battery_charge_efficiency': 0.95, 'battery_nominal_energy_capacity': 5000, 'battery_minimum_state_of_charge': 0, 'battery_maximum_state_of_charge': 1, 'battery_target_state_of_charge': 0}
[2025-09-19 10:57:11 +0200] [23] [DEBUG] Solver configuration: lp_solver=COIN_CMD, lp_solver_path=/usr/bin/cbc
[2025-09-19 10:57:11 +0200] [23] [DEBUG] Number of threads: 4
[2025-09-19 10:57:11 +0200] [23] [INFO] Retrieving weather forecast data using method = list
[2025-09-19 10:57:11 +0200] [23] [DEBUG] get_weather_forecast returning:
yhat
ts
2025-09-19 10:30:00+02:00 1
2025-09-19 11:00:00+02:00 2
2025-09-19 11:30:00+02:00 3
2025-09-19 12:00:00+02:00 4
2025-09-19 12:30:00+02:00 5
2025-09-19 13:00:00+02:00 6
2025-09-19 13:30:00+02:00 7
2025-09-19 14:00:00+02:00 8
2025-09-19 14:30:00+02:00 9
2025-09-19 15:00:00+02:00 10
2025-09-19 15:30:00+02:00 11
2025-09-19 16:00:00+02:00 12
2025-09-19 16:30:00+02:00 13
2025-09-19 17:00:00+02:00 14
2025-09-19 17:30:00+02:00 15
2025-09-19 18:00:00+02:00 16
2025-09-19 18:30:00+02:00 17
2025-09-19 19:00:00+02:00 18
2025-09-19 19:30:00+02:00 19
2025-09-19 20:00:00+02:00 20
2025-09-19 20:30:00+02:00 21
2025-09-19 21:00:00+02:00 22
2025-09-19 21:30:00+02:00 23
2025-09-19 22:00:00+02:00 24
2025-09-19 22:30:00+02:00 1
2025-09-19 23:00:00+02:00 2
2025-09-19 23:30:00+02:00 3
2025-09-20 00:00:00+02:00 4
2025-09-20 00:30:00+02:00 5
2025-09-20 01:00:00+02:00 6
2025-09-20 01:30:00+02:00 7
2025-09-20 02:00:00+02:00 8
2025-09-20 02:30:00+02:00 9
2025-09-20 03:00:00+02:00 10
2025-09-20 03:30:00+02:00 11
2025-09-20 04:00:00+02:00 12
2025-09-20 04:30:00+02:00 13
2025-09-20 05:00:00+02:00 14
2025-09-20 05:30:00+02:00 15
2025-09-20 06:00:00+02:00 16
2025-09-20 06:30:00+02:00 17
2025-09-20 07:00:00+02:00 18
2025-09-20 07:30:00+02:00 19
2025-09-20 08:00:00+02:00 20
2025-09-20 08:30:00+02:00 21
2025-09-20 09:00:00+02:00 22
2025-09-20 09:30:00+02:00 23
2025-09-20 10:00:00+02:00 24
[2025-09-19 10:57:11 +0200] [23] [DEBUG] get_power_from_weather returning:
ts
2025-09-19 10:30:00+02:00 1
2025-09-19 11:00:00+02:00 2
2025-09-19 11:30:00+02:00 3
2025-09-19 12:00:00+02:00 4
2025-09-19 12:30:00+02:00 5
2025-09-19 13:00:00+02:00 6
2025-09-19 13:30:00+02:00 7
2025-09-19 14:00:00+02:00 8
2025-09-19 14:30:00+02:00 9
2025-09-19 15:00:00+02:00 10
2025-09-19 15:30:00+02:00 11
2025-09-19 16:00:00+02:00 12
2025-09-19 16:30:00+02:00 13
2025-09-19 17:00:00+02:00 14
2025-09-19 17:30:00+02:00 15
2025-09-19 18:00:00+02:00 16
2025-09-19 18:30:00+02:00 17
2025-09-19 19:00:00+02:00 18
2025-09-19 19:30:00+02:00 19
2025-09-19 20:00:00+02:00 20
2025-09-19 20:30:00+02:00 21
2025-09-19 21:00:00+02:00 22
2025-09-19 21:30:00+02:00 23
2025-09-19 22:00:00+02:00 24
2025-09-19 22:30:00+02:00 1
2025-09-19 23:00:00+02:00 2
2025-09-19 23:30:00+02:00 3
2025-09-20 00:00:00+02:00 4
2025-09-20 00:30:00+02:00 5
2025-09-20 01:00:00+02:00 6
2025-09-20 01:30:00+02:00 7
2025-09-20 02:00:00+02:00 8
2025-09-20 02:30:00+02:00 9
2025-09-20 03:00:00+02:00 10
2025-09-20 03:30:00+02:00 11
2025-09-20 04:00:00+02:00 12
2025-09-20 04:30:00+02:00 13
2025-09-20 05:00:00+02:00 14
2025-09-20 05:30:00+02:00 15
2025-09-20 06:00:00+02:00 16
2025-09-20 06:30:00+02:00 17
2025-09-20 07:00:00+02:00 18
2025-09-20 07:30:00+02:00 19
2025-09-20 08:00:00+02:00 20
2025-09-20 08:30:00+02:00 21
2025-09-20 09:00:00+02:00 22
2025-09-20 09:30:00+02:00 23
2025-09-20 10:00:00+02:00 24
dtype: int64
[2025-09-19 10:57:11 +0200] [23] [INFO] Retrieving data from hass for load forecast using method = naive
[2025-09-19 10:57:11 +0200] [23] [INFO] Retrieve hass get data method initiated...
[2025-09-19 10:57:11 +0200] [23] [DEBUG] prepare_data self.var_list=['sensor.power_myhouse_load_no_var_loads']
[2025-09-19 10:57:11 +0200] [23] [DEBUG] prepare_data var_load=sensor.power_myhouse_load_no_var_loads
[2025-09-19 10:57:11 +0200] [23] [DEBUG] prepare_data load_negative=False
[2025-09-19 10:57:11 +0200] [23] [DEBUG] prepare_data set_zero_min=True
[2025-09-19 10:57:11 +0200] [23] [DEBUG] prepare_data var_replace_zero=None
[2025-09-19 10:57:11 +0200] [23] [DEBUG] prepare_data var_interp=['sensor.power_myhouse_load_no_var_loads']
[2025-09-19 10:57:11 +0200] [23] [DEBUG] get_load_forecast returning:
2025-09-19 10:30:00+02:00 408.569000
2025-09-19 11:00:00+02:00 586.899667
2025-09-19 11:30:00+02:00 949.437889
2025-09-19 12:00:00+02:00 297.230650
2025-09-19 12:30:00+02:00 241.633500
2025-09-19 13:00:00+02:00 299.583333
2025-09-19 13:30:00+02:00 306.805000
2025-09-19 14:00:00+02:00 300.133333
2025-09-19 14:30:00+02:00 366.095000
2025-09-19 15:00:00+02:00 343.933333
2025-09-19 15:30:00+02:00 285.572444
2025-09-19 16:00:00+02:00 327.244867
2025-09-19 16:30:00+02:00 377.756667
2025-09-19 17:00:00+02:00 1265.798333
2025-09-19 17:30:00+02:00 1041.040444
2025-09-19 18:00:00+02:00 617.779500
2025-09-19 18:30:00+02:00 417.269550
2025-09-19 19:00:00+02:00 337.203683
2025-09-19 19:30:00+02:00 3838.144254
2025-09-19 20:00:00+02:00 490.172500
2025-09-19 20:30:00+02:00 374.927710
2025-09-19 21:00:00+02:00 173.575000
2025-09-19 21:30:00+02:00 34.343987
2025-09-19 22:00:00+02:00 1.368162
2025-09-19 22:30:00+02:00 70.970756
2025-09-19 23:00:00+02:00 78.355745
2025-09-19 23:30:00+02:00 100.685644
2025-09-20 00:00:00+02:00 1.192500
2025-09-20 00:30:00+02:00 5802.166667
2025-09-20 01:00:00+02:00 7009.000000
2025-09-20 01:30:00+02:00 6987.500000
2025-09-20 02:00:00+02:00 7004.285714
2025-09-20 02:30:00+02:00 6970.000000
2025-09-20 03:00:00+02:00 6962.857143
2025-09-20 03:30:00+02:00 9020.000000
2025-09-20 04:00:00+02:00 10411.285714
2025-09-20 04:30:00+02:00 9105.181818
2025-09-20 05:00:00+02:00 9000.714286
2025-09-20 05:30:00+02:00 8172.304167
2025-09-20 06:00:00+02:00 420.465000
2025-09-20 06:30:00+02:00 423.874856
2025-09-20 07:00:00+02:00 854.498067
2025-09-20 07:30:00+02:00 389.255333
2025-09-20 08:00:00+02:00 278.366683
2025-09-20 08:30:00+02:00 289.961367
2025-09-20 09:00:00+02:00 245.988800
2025-09-20 09:30:00+02:00 261.865636
2025-09-20 10:00:00+02:00 249.903667
Name: yhat, dtype: float64
[2025-09-19 10:57:11 +0200] [23] [INFO] >> Performing dayahead optimization...
[2025-09-19 10:57:11 +0200] [23] [INFO] Performing day-ahead forecast optimization
[2025-09-19 10:57:11 +0200] [23] [DEBUG] get_load_cost_forecast returning:
P_PV_forecast P_load_forecast unit_load_cost
ts
2025-09-19 10:30:00+02:00 1.0 408.569000 25
2025-09-19 11:00:00+02:00 2.0 586.899667 26
2025-09-19 11:30:00+02:00 3.0 949.437889 27
2025-09-19 12:00:00+02:00 4.0 297.230650 28
2025-09-19 12:30:00+02:00 5.0 241.633500 28
2025-09-19 13:00:00+02:00 6.0 299.583333 29
2025-09-19 13:30:00+02:00 7.0 306.805000 30
2025-09-19 14:00:00+02:00 8.0 300.133333 31
2025-09-19 14:30:00+02:00 9.0 366.095000 32
2025-09-19 15:00:00+02:00 10.0 343.933333 33
2025-09-19 15:30:00+02:00 11.0 285.572444 34
2025-09-19 16:00:00+02:00 12.0 327.244867 35
2025-09-19 16:30:00+02:00 13.0 377.756667 36
2025-09-19 17:00:00+02:00 14.0 1265.798333 37
2025-09-19 17:30:00+02:00 15.0 1041.040444 38
2025-09-19 18:00:00+02:00 16.0 617.779500 39
2025-09-19 18:30:00+02:00 17.0 417.269550 40
2025-09-19 19:00:00+02:00 18.0 337.203683 41
2025-09-19 19:30:00+02:00 19.0 3838.144254 42
2025-09-19 20:00:00+02:00 20.0 490.172500 43
2025-09-19 20:30:00+02:00 21.0 374.927710 44
2025-09-19 21:00:00+02:00 22.0 173.575000 45
2025-09-19 21:30:00+02:00 23.0 34.343987 46
2025-09-19 22:00:00+02:00 24.0 1.368162 47
2025-09-19 22:30:00+02:00 1.0 70.970756 25
2025-09-19 23:00:00+02:00 2.0 78.355745 26
2025-09-19 23:30:00+02:00 3.0 100.685644 27
2025-09-20 00:00:00+02:00 4.0 1.192500 28
2025-09-20 00:30:00+02:00 5.0 5802.166667 28
2025-09-20 01:00:00+02:00 6.0 7009.000000 29
2025-09-20 01:30:00+02:00 7.0 6987.500000 30
2025-09-20 02:00:00+02:00 8.0 7004.285714 31
2025-09-20 02:30:00+02:00 9.0 6970.000000 32
2025-09-20 03:00:00+02:00 10.0 6962.857143 33
2025-09-20 03:30:00+02:00 11.0 9020.000000 34
2025-09-20 04:00:00+02:00 12.0 10411.285714 35
2025-09-20 04:30:00+02:00 13.0 9105.181818 36
2025-09-20 05:00:00+02:00 14.0 9000.714286 37
2025-09-20 05:30:00+02:00 15.0 8172.304167 38
2025-09-20 06:00:00+02:00 16.0 420.465000 39
2025-09-20 06:30:00+02:00 17.0 423.874856 40
2025-09-20 07:00:00+02:00 18.0 854.498067 41
2025-09-20 07:30:00+02:00 19.0 389.255333 42
2025-09-20 08:00:00+02:00 20.0 278.366683 43
2025-09-20 08:30:00+02:00 21.0 289.961367 44
2025-09-20 09:00:00+02:00 22.0 245.988800 45
2025-09-20 09:30:00+02:00 23.0 261.865636 46
2025-09-20 10:00:00+02:00 24.0 249.903667 47
[2025-09-19 10:57:11 +0200] [23] [DEBUG] get_prod_price_forecast returning:
P_PV_forecast ... unit_prod_price
ts ...
2025-09-19 10:30:00+02:00 1.0 ... 1
2025-09-19 11:00:00+02:00 2.0 ... 2
2025-09-19 11:30:00+02:00 3.0 ... 3
2025-09-19 12:00:00+02:00 4.0 ... 4
2025-09-19 12:30:00+02:00 5.0 ... 5
2025-09-19 13:00:00+02:00 6.0 ... 6
2025-09-19 13:30:00+02:00 7.0 ... 7
2025-09-19 14:00:00+02:00 8.0 ... 8
2025-09-19 14:30:00+02:00 9.0 ... 9
2025-09-19 15:00:00+02:00 10.0 ... 10
2025-09-19 15:30:00+02:00 11.0 ... 11
2025-09-19 16:00:00+02:00 12.0 ... 12
2025-09-19 16:30:00+02:00 13.0 ... 13
2025-09-19 17:00:00+02:00 14.0 ... 14
2025-09-19 17:30:00+02:00 15.0 ... 15
2025-09-19 18:00:00+02:00 16.0 ... 16
2025-09-19 18:30:00+02:00 17.0 ... 17
2025-09-19 19:00:00+02:00 18.0 ... 18
2025-09-19 19:30:00+02:00 19.0 ... 19
2025-09-19 20:00:00+02:00 20.0 ... 20
2025-09-19 20:30:00+02:00 21.0 ... 21
2025-09-19 21:00:00+02:00 22.0 ... 22
2025-09-19 21:30:00+02:00 23.0 ... 23
2025-09-19 22:00:00+02:00 24.0 ... 24
2025-09-19 22:30:00+02:00 1.0 ... 1
2025-09-19 23:00:00+02:00 2.0 ... 2
2025-09-19 23:30:00+02:00 3.0 ... 3
2025-09-20 00:00:00+02:00 4.0 ... 4
2025-09-20 00:30:00+02:00 5.0 ... 5
2025-09-20 01:00:00+02:00 6.0 ... 6
2025-09-20 01:30:00+02:00 7.0 ... 7
2025-09-20 02:00:00+02:00 8.0 ... 8
2025-09-20 02:30:00+02:00 9.0 ... 9
2025-09-20 03:00:00+02:00 10.0 ... 10
2025-09-20 03:30:00+02:00 11.0 ... 11
2025-09-20 04:00:00+02:00 12.0 ... 12
2025-09-20 04:30:00+02:00 13.0 ... 13
2025-09-20 05:00:00+02:00 14.0 ... 14
2025-09-20 05:30:00+02:00 15.0 ... 15
2025-09-20 06:00:00+02:00 16.0 ... 16
2025-09-20 06:30:00+02:00 17.0 ... 17
2025-09-20 07:00:00+02:00 18.0 ... 18
2025-09-20 07:30:00+02:00 19.0 ... 19
2025-09-20 08:00:00+02:00 20.0 ... 20
2025-09-20 08:30:00+02:00 21.0 ... 21
2025-09-20 09:00:00+02:00 22.0 ... 22
2025-09-20 09:30:00+02:00 23.0 ... 23
2025-09-20 10:00:00+02:00 24.0 ... 24
[48 rows x 4 columns]
[2025-09-19 10:57:11 +0200] [23] [INFO] Perform optimization for the day-ahead
[2025-09-19 10:57:11 +0200] [23] [DEBUG] Battery usage enabled. Initial SOC: 0, Final SOC: 0
[2025-09-19 10:57:11 +0200] [23] [DEBUG] Processing deferrable load 0
[2025-09-19 10:57:11 +0200] [23] [DEBUG] Load 0 is standard/non-thermal.
[2025-09-19 10:57:11 +0200] [23] [DEBUG] Load 0: Using total hours constraint: 2
[2025-09-19 10:57:11 +0200] [23] [DEBUG] Load 0: Standard load constraints set.
[2025-09-19 10:57:11 +0200] [23] [DEBUG] Deferrable load 0: Proposed optimization window: 0 --> 0
[2025-09-19 10:57:11 +0200] [23] [DEBUG] Deferrable load 0: Validated optimization window: 0 --> 0
[2025-09-19 10:57:11 +0200] [23] [DEBUG] Processing deferrable load 1
[2025-09-19 10:57:11 +0200] [23] [DEBUG] Load 1 is standard/non-thermal.
[2025-09-19 10:57:11 +0200] [23] [DEBUG] Load 1: Using total hours constraint: 1
[2025-09-19 10:57:11 +0200] [23] [DEBUG] Load 1: Standard load constraints set.
[2025-09-19 10:57:11 +0200] [23] [DEBUG] Deferrable load 1: Proposed optimization window: 0 --> 0
[2025-09-19 10:57:11 +0200] [23] [DEBUG] Deferrable load 1: Validated optimization window: 0 --> 0
[2025-09-19 10:57:13 +0200] [23] [INFO] Status: Optimal
[2025-09-19 10:57:13 +0200] [23] [INFO] Total value of the Cost function = -1937.40
[2025-09-19 10:57:13 +0200] [23] [DEBUG] Battery usage enabled. Initial SOC: 0, Final SOC: 0
[2025-09-19 10:57:13 +0200] [23] [DEBUG] Deferrable load operating hours: [2, 1]
[2025-09-19 10:57:13 +0200] [23] [DEBUG] Deferrable load timesteps: None
[2025-09-19 10:57:13 +0200] [23] [DEBUG] Deferrable load start timesteps: [0, 0]
[2025-09-19 10:57:13 +0200] [23] [DEBUG] Deferrable load end timesteps: [0, 0]
[2025-09-19 10:57:13 +0200] [23] [DEBUG] Selected cost function type: profit
[2025-09-19 10:57:13 +0200] [23] [DEBUG] Solver selected: COIN_CMD
[2025-09-19 10:57:13 +0200] [23] [INFO] Optimization status: Optimal
Key issues in the config vs. logs
- Mismatched time step
- Config:
"optimization_time_step": 60(minutes, so 1-hour resolution). - Logs:
optimization_time_step': Timedelta('0 days 00:30:00')→ EMHASS is interpreting it as 30 minutes. - This mismatch usually happens if
prediction_horizonlength (24) and the number of points passed (48) don’t align with the optimization time step. - Your runtime data (
pv_power_forecastetc.) has 48 values → EMHASS assumes half-hour steps, not 1-hour.
Fix: Either:
- set
optimization_time_step: 30in config,
OR - pass only 24 values (not 48) if you really want 60-minute resolution.
- Forecast methods overridden by lists
- Config has
"load_cost_forecast_method": "hp_hc_periods"and"production_price_forecast_method": "constant". - But logs show
load_cost_forecast_method: listandproduction_price_forecast_method: list. - That’s because you passed explicit arrays (
prod_price_forecast,load_cost_forecast) in runtime parameters. - This is fine, just know that your config methods are ignored when you supply lists.
- Inverter AC limits
- Config has
"inverter_ac_output_max": 1000and"inverter_ac_input_max": 1000. - That caps PV → grid and grid → load to just 1 kW!
- But your PV model is Primo 6.0-1 (6 kW inverter).
- So your optimization will think you can only export/import 1 kW total, which is wrong.
Fix:
"inverter_ac_output_max": 6000"inverter_ac_input_max": 6000(or higher if allowed).
- Battery target SOC = 0
"battery_target_state_of_charge": 0→ optimizer has no incentive to preserve charge for later periods.- This often results in battery discharging fully as soon as it’s profitable.
- You many waht to set something like 0.2 or 0.3 (20–30%) to preserve minimum energy. But you don’t have to.
- Deferrable loads config
- You’ve got 2 loads:
[1300, 7300]W. "operating_hours_of_each_deferrable_load": [2, 1]→ they must run 2h and 1h per horizon.- But start and end times are both
[0, 0]→ means EMHASS can schedule them anywhere. - That’s OK, just be aware EMHASS is free to place them wherever costs are lowest. If you want them locked into windows, you need real start/end step numbers.
Thnx again for all help!
Reverted back to the 24 number arrays.
payload: >
{
"pv_power_forecast": [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24],
"prediction_horizon": 24,
"prod_price_forecast": [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24],
"load_cost_forecast": [25, 26, 27, 28, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47]
}
Ran the rest_command.
Again, the array is not added in EMHASS. The computation is based on the hc_lc prices, and the timestep still is 30 min.
SO, still believe that by some reason, the change of timestep doesnt seem to have effect. And i can only import 48 number arrays in timestep of 30min!!
see log:
[2025-09-20 00:37:37 +0200] [23] [INFO] >> Obtaining params:
[2025-09-20 00:37:37 +0200] [23] [INFO] Passed runtime parameters: {'pv_power_forecast': [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24], 'prediction_horizon': 24, 'prod_price_forecast': [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24], 'load_cost_forecast': [25, 26, 27, 28, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47]}
[2025-09-20 00:37:37 +0200] [23] [INFO] >> Setting input data dict
[2025-09-20 00:37:37 +0200] [23] [INFO] Setting up needed data
[2025-09-20 00:37:37 +0200] [23] [ERROR] ERROR: The passed data is either the wrong type or the length is not correct, length should be 48
[2025-09-20 00:37:37 +0200] [23] [ERROR] Passed type is <class 'list'> and length is 24
[2025-09-20 00:37:37 +0200] [23] [ERROR] ERROR: The passed data is either the wrong type or the length is not correct, length should be 48
[2025-09-20 00:37:37 +0200] [23] [ERROR] Passed type is <class 'list'> and length is 24
[2025-09-20 00:37:37 +0200] [23] [ERROR] ERROR: The passed data is either the wrong type or the length is not correct, length should be 48
[2025-09-20 00:37:37 +0200] [23] [ERROR] Passed type is <class 'list'> and length is 24
[2025-09-20 00:37:37 +0200] [23] [DEBUG] setting`passed_data:days_to_retrieve` to 9 for fit/predict/tune
[2025-09-20 00:37:37 +0200] [23] [WARNING] lp_solver=COIN_CMD but lp_solver_path=empty, attempting to use lp_solver_path=/usr/bin/cbc
[2025-09-20 00:37:37 +0200] [23] [DEBUG] Initialized Optimization with retrieve_hass_conf: {'optimization_time_step': Timedelta('0 days 00:30:00'), 'historic_days_to_retrieve': 2, 'sensor_power_photovoltaics': 'sensor.solar_panel_production_w', 'sensor_power_photovoltaics_forecast': '', 'sensor_power_load_no_var_loads': 'sensor.power_myhouse_load_no_var_loads', 'load_negative': False, 'set_zero_min': True, 'sensor_replace_zero': ['sensor.solar_battery_out_to_grid_and_house_w'], 'sensor_linear_interp': ['sensor.power_myhouse_load_no_var_loads'], 'method_ts_round': 'first', 'continual_publish': False, 'hass_url': 'http://supervisor/core/api', 'long_lived_token': '0ada82ed9790c72e5da7263eec5930234008b6ac5c2fb0b63403966ef5ed53649a4c7544131d8eb7c73e168cba0fd6e700685df7356bc9eb', 'time_zone': <DstTzInfo 'Europe/Stockholm' LMT+0:53:00 STD>, 'Latitude': 57.85885, 'Longitude': 14.305337, 'Altitude': 16}
[2025-09-20 00:37:37 +0200] [23] [DEBUG] Optimization configuration: {'costfun': 'profit', 'logging_level': 'INFO', 'set_use_pv': True, 'set_use_adjusted_pv': False, 'adjusted_pv_regression_model': 'LassoRegression', 'adjusted_pv_solar_elevation_threshold': 10, 'set_use_battery': True, 'number_of_deferrable_loads': 2, 'nominal_power_of_deferrable_loads': [1300, 7300], 'minimum_power_of_deferrable_loads': [0, 0], 'operating_hours_of_each_deferrable_load': [2, 1], 'treat_deferrable_load_as_semi_cont': [True, False], 'set_deferrable_load_single_constant': [False, False], 'set_deferrable_startup_penalty': [0, 0], 'delta_forecast_daily': Timedelta('1 days 00:00:00'), 'load_forecast_method': 'naive', 'load_cost_forecast_method': 'hp_hc_periods', 'load_peak_hours_cost': 0.1907, 'load_offpeak_hours_cost': 0.1419, 'production_price_forecast_method': 'constant', 'photovoltaic_production_sell_price': 0.1419, 'set_total_pv_sell': False, 'lp_solver': 'COIN_CMD', 'lp_solver_path': 'empty', 'lp_solver_timeout': 45, 'num_threads': 0, 'set_nocharge_from_grid': False, 'set_nodischarge_to_grid': False, 'set_battery_dynamic': True, 'battery_dynamic_max': 0.9, 'battery_dynamic_min': -0.9, 'weight_battery_discharge': 0, 'weight_battery_charge': 0, 'weather_forecast_method': 'open-meteo', 'open_meteo_cache_max_age': 30, 'start_timesteps_of_each_deferrable_load': [0, 0], 'end_timesteps_of_each_deferrable_load': [0, 0], 'load_peak_hour_periods': {'period_hp_1': [{'start': '02:54'}, {'end': '15:24'}], 'period_hp_2': [{'start': '17:24'}, {'end': '20:24'}]}}
[2025-09-20 00:37:37 +0200] [23] [DEBUG] Plant configuration: {'maximum_power_from_grid': 14490, 'maximum_power_to_grid': 9000, 'pv_module_model': ['CSUN_Eurasia_Energy_Systems_Industry_and_Trade_CSUN295_60M'], 'pv_inverter_model': ['Fronius_International_GmbH__Fronius_Primo_6_0_1_208_240__240V_'], 'surface_tilt': [21], 'surface_azimuth': [10], 'modules_per_string': [17], 'strings_per_inverter': [1], 'inverter_is_hybrid': False, 'inverter_ac_output_max': 1000, 'inverter_ac_input_max': 1000, 'inverter_efficiency_dc_ac': 1, 'inverter_efficiency_ac_dc': 1, 'compute_curtailment': False, 'battery_discharge_power_max': 3300, 'battery_charge_power_max': 3300, 'battery_discharge_efficiency': 0.9, 'battery_charge_efficiency': 0.95, 'battery_nominal_energy_capacity': 5000, 'battery_minimum_state_of_charge': 0, 'battery_maximum_state_of_charge': 1, 'battery_target_state_of_charge': 0}
[2025-09-20 00:37:37 +0200] [23] [DEBUG] Solver configuration: lp_solver=COIN_CMD, lp_solver_path=/usr/bin/cbc
[2025-09-20 00:37:37 +0200] [23] [DEBUG] Number of threads: 4
[2025-09-20 00:37:37 +0200] [23] [INFO] Retrieving weather forecast data using method = open-meteo
[2025-09-20 00:37:37 +0200] [23] [INFO] Retrieved forecast data from the previously saved cache.
[2025-09-20 00:37:37 +0200] [23] [DEBUG] get_weather_forecast returning:
temp_air relative_humidity ... dhi dni
2025-09-20 00:30:00+02:00 16.6 87 ... 0.0 0.0
2025-09-20 01:00:00+02:00 16.5 86 ... 0.0 0.0
2025-09-20 01:30:00+02:00 16.4 85 ... 0.0 0.0
2025-09-20 02:00:00+02:00 16.1 85 ... 0.0 0.0
2025-09-20 02:30:00+02:00 16.0 85 ... 0.0 0.0
2025-09-20 03:00:00+02:00 15.9 85 ... 0.0 0.0
2025-09-20 03:30:00+02:00 15.8 84 ... 0.0 0.0
2025-09-20 04:00:00+02:00 15.6 83 ... 0.0 0.0
2025-09-20 04:30:00+02:00 15.4 82 ... 0.0 0.0
2025-09-20 05:00:00+02:00 15.2 82 ... 0.0 0.0
2025-09-20 05:30:00+02:00 15.1 84 ... 0.0 0.0
2025-09-20 06:00:00+02:00 15.1 85 ... 0.0 0.0
2025-09-20 06:30:00+02:00 15.1 84 ... 0.0 0.0
2025-09-20 07:00:00+02:00 15.1 84 ... 7.7 0.5
2025-09-20 07:30:00+02:00 15.2 86 ... 23.0 3.6
2025-09-20 08:00:00+02:00 15.4 88 ... 41.2 16.6
2025-09-20 08:30:00+02:00 15.8 88 ... 61.4 30.9
2025-09-20 09:00:00+02:00 16.2 87 ... 88.1 60.2
2025-09-20 09:30:00+02:00 17.0 85 ... 117.1 109.1
2025-09-20 10:00:00+02:00 17.6 83 ... 137.1 132.2
2025-09-20 10:30:00+02:00 18.1 82 ... 153.0 139.8
2025-09-20 11:00:00+02:00 18.6 81 ... 169.7 170.1
2025-09-20 11:30:00+02:00 19.2 79 ... 182.7 205.5
2025-09-20 12:00:00+02:00 19.9 76 ... 187.7 165.1
2025-09-20 12:30:00+02:00 20.2 75 ... 184.7 117.5
2025-09-20 13:00:00+02:00 20.5 73 ... 196.7 257.6
2025-09-20 13:30:00+02:00 21.1 70 ... 162.9 576.8
2025-09-20 14:00:00+02:00 21.6 66 ... 150.9 646.8
2025-09-20 14:30:00+02:00 22.0 64 ... 152.2 583.4
2025-09-20 15:00:00+02:00 22.2 63 ... 146.3 565.7
2025-09-20 15:30:00+02:00 22.4 62 ... 138.3 551.4
2025-09-20 16:00:00+02:00 22.5 62 ... 130.2 505.2
2025-09-20 16:30:00+02:00 22.4 63 ... 119.6 438.1
2025-09-20 17:00:00+02:00 22.0 64 ... 104.8 366.6
2025-09-20 17:30:00+02:00 21.8 65 ... 85.3 291.7
2025-09-20 18:00:00+02:00 21.2 66 ... 60.8 209.8
2025-09-20 18:30:00+02:00 20.6 67 ... 32.1 127.2
2025-09-20 19:00:00+02:00 20.0 67 ... 1.1 2.0
2025-09-20 19:30:00+02:00 19.5 68 ... 0.0 0.0
2025-09-20 20:00:00+02:00 19.0 69 ... 0.0 0.0
2025-09-20 20:30:00+02:00 18.8 72 ... 0.0 0.0
2025-09-20 21:00:00+02:00 18.6 75 ... 0.0 0.0
2025-09-20 21:30:00+02:00 18.5 79 ... 0.0 0.0
2025-09-20 22:00:00+02:00 18.2 82 ... 0.0 0.0
2025-09-20 22:30:00+02:00 18.0 83 ... 0.0 0.0
2025-09-20 23:00:00+02:00 17.7 83 ... 0.0 0.0
2025-09-20 23:30:00+02:00 17.6 81 ... 0.0 0.0
2025-09-21 00:00:00+02:00 17.5 79 ... 0.0 0.0
[48 rows x 8 columns]
[2025-09-20 00:37:40 +0200] [23] [DEBUG] get_power_from_weather returning:
2025-09-20 00:30:00+02:00 0.000000
2025-09-20 01:00:00+02:00 0.000000
2025-09-20 01:30:00+02:00 0.000000
2025-09-20 02:00:00+02:00 0.000000
2025-09-20 02:30:00+02:00 0.000000
2025-09-20 03:00:00+02:00 0.000000
2025-09-20 03:30:00+02:00 0.000000
2025-09-20 04:00:00+02:00 0.000000
2025-09-20 04:30:00+02:00 0.000000
2025-09-20 05:00:00+02:00 0.000000
2025-09-20 05:30:00+02:00 0.000000
2025-09-20 06:00:00+02:00 0.000000
2025-09-20 06:30:00+02:00 0.000000
2025-09-20 07:00:00+02:00 0.000000
2025-09-20 07:30:00+02:00 52.753367
2025-09-20 08:00:00+02:00 143.604149
2025-09-20 08:30:00+02:00 246.909983
2025-09-20 09:00:00+02:00 389.462767
2025-09-20 09:30:00+02:00 551.590477
2025-09-20 10:00:00+02:00 659.795442
2025-09-20 10:30:00+02:00 740.798266
2025-09-20 11:00:00+02:00 833.220026
2025-09-20 11:30:00+02:00 904.022853
2025-09-20 12:00:00+02:00 900.484450
2025-09-20 12:30:00+02:00 859.191958
2025-09-20 13:00:00+02:00 949.050396
2025-09-20 13:30:00+02:00 900.378191
2025-09-20 14:00:00+02:00 836.257399
2025-09-20 14:30:00+02:00 769.981402
2025-09-20 15:00:00+02:00 689.710427
2025-09-20 15:30:00+02:00 602.088071
2025-09-20 16:00:00+02:00 517.615094
2025-09-20 16:30:00+02:00 437.564567
2025-09-20 17:00:00+02:00 358.005471
2025-09-20 17:30:00+02:00 274.257905
2025-09-20 18:00:00+02:00 182.222218
2025-09-20 18:30:00+02:00 76.939975
2025-09-20 19:00:00+02:00 0.000000
2025-09-20 19:30:00+02:00 0.000000
2025-09-20 20:00:00+02:00 0.000000
2025-09-20 20:30:00+02:00 0.000000
2025-09-20 21:00:00+02:00 0.000000
2025-09-20 21:30:00+02:00 0.000000
2025-09-20 22:00:00+02:00 0.000000
2025-09-20 22:30:00+02:00 0.000000
2025-09-20 23:00:00+02:00 0.000000
2025-09-20 23:30:00+02:00 0.000000
2025-09-21 00:00:00+02:00 0.000000
Freq: 30min, dtype: float64
[2025-09-20 00:37:40 +0200] [23] [INFO] Retrieving data from hass for load forecast using method = naive
[2025-09-20 00:37:40 +0200] [23] [INFO] Retrieve hass get data method initiated...
[2025-09-20 00:37:41 +0200] [23] [DEBUG] prepare_data self.var_list=['sensor.power_myhouse_load_no_var_loads']
[2025-09-20 00:37:41 +0200] [23] [DEBUG] prepare_data var_load=sensor.power_myhouse_load_no_var_loads
[2025-09-20 00:37:41 +0200] [23] [DEBUG] prepare_data load_negative=False
[2025-09-20 00:37:41 +0200] [23] [DEBUG] prepare_data set_zero_min=True
[2025-09-20 00:37:41 +0200] [23] [DEBUG] prepare_data var_replace_zero=None
[2025-09-20 00:37:41 +0200] [23] [DEBUG] prepare_data var_interp=['sensor.power_myhouse_load_no_var_loads']
[2025-09-20 00:37:41 +0200] [23] [DEBUG] get_load_forecast returning:
2025-09-20 00:30:00+02:00 5802.166667
2025-09-20 01:00:00+02:00 7009.000000
2025-09-20 01:30:00+02:00 6987.500000
2025-09-20 02:00:00+02:00 7004.285714
2025-09-20 02:30:00+02:00 6970.000000
2025-09-20 03:00:00+02:00 6962.857143
2025-09-20 03:30:00+02:00 9020.000000
2025-09-20 04:00:00+02:00 10411.285714
2025-09-20 04:30:00+02:00 9105.181818
2025-09-20 05:00:00+02:00 9000.714286
2025-09-20 05:30:00+02:00 8172.304167
2025-09-20 06:00:00+02:00 420.465000
2025-09-20 06:30:00+02:00 423.874856
2025-09-20 07:00:00+02:00 854.498067
2025-09-20 07:30:00+02:00 389.255333
2025-09-20 08:00:00+02:00 278.366683
2025-09-20 08:30:00+02:00 289.961367
2025-09-20 09:00:00+02:00 245.988800
2025-09-20 09:30:00+02:00 261.865636
2025-09-20 10:00:00+02:00 249.903667
2025-09-20 10:30:00+02:00 208.670000
2025-09-20 11:00:00+02:00 511.338333
2025-09-20 11:30:00+02:00 805.836250
2025-09-20 12:00:00+02:00 178.190000
2025-09-20 12:30:00+02:00 119.761250
2025-09-20 13:00:00+02:00 132.333333
2025-09-20 13:30:00+02:00 121.722500
2025-09-20 14:00:00+02:00 64.693333
2025-09-20 14:30:00+02:00 74.296667
2025-09-20 15:00:00+02:00 341.426667
2025-09-20 15:30:00+02:00 145.084444
2025-09-20 16:00:00+02:00 86.147833
2025-09-20 16:30:00+02:00 142.053300
2025-09-20 17:00:00+02:00 1214.656517
2025-09-20 17:30:00+02:00 248.987300
2025-09-20 18:00:00+02:00 256.158800
2025-09-20 18:30:00+02:00 189.895750
2025-09-20 19:00:00+02:00 216.938333
2025-09-20 19:30:00+02:00 169.537289
2025-09-20 20:00:00+02:00 150.405117
2025-09-20 20:30:00+02:00 261.000100
2025-09-20 21:00:00+02:00 292.655767
2025-09-20 21:30:00+02:00 217.448978
2025-09-20 22:00:00+02:00 91.111967
2025-09-20 22:30:00+02:00 40.081500
2025-09-20 23:00:00+02:00 2.216120
2025-09-20 23:30:00+02:00 43.404463
2025-09-21 00:00:00+02:00 1.437750
Name: yhat, dtype: float64
[2025-09-20 00:37:41 +0200] [23] [INFO] >> Performing dayahead optimization...
[2025-09-20 00:37:41 +0200] [23] [INFO] Performing day-ahead forecast optimization
[2025-09-20 00:37:41 +0200] [23] [DEBUG] get_load_cost_forecast returning:
P_PV_forecast P_load_forecast unit_load_cost
2025-09-20 00:30:00+02:00 0.000000 5802.166667 0.1419
2025-09-20 01:00:00+02:00 0.000000 7009.000000 0.1419
2025-09-20 01:30:00+02:00 0.000000 6987.500000 0.1419
2025-09-20 02:00:00+02:00 0.000000 7004.285714 0.1419
2025-09-20 02:30:00+02:00 0.000000 6970.000000 0.1419
2025-09-20 03:00:00+02:00 0.000000 6962.857143 0.1907
2025-09-20 03:30:00+02:00 0.000000 9020.000000 0.1907
2025-09-20 04:00:00+02:00 0.000000 10411.285714 0.1907
2025-09-20 04:30:00+02:00 0.000000 9105.181818 0.1907
2025-09-20 05:00:00+02:00 0.000000 9000.714286 0.1907
2025-09-20 05:30:00+02:00 0.000000 8172.304167 0.1907
2025-09-20 06:00:00+02:00 0.000000 420.465000 0.1907
2025-09-20 06:30:00+02:00 0.000000 423.874856 0.1907
2025-09-20 07:00:00+02:00 0.000000 854.498067 0.1907
2025-09-20 07:30:00+02:00 52.753367 389.255333 0.1907
2025-09-20 08:00:00+02:00 143.604149 278.366683 0.1907
2025-09-20 08:30:00+02:00 246.909983 289.961367 0.1907
2025-09-20 09:00:00+02:00 389.462767 245.988800 0.1907
2025-09-20 09:30:00+02:00 551.590477 261.865636 0.1907
2025-09-20 10:00:00+02:00 659.795442 249.903667 0.1907
2025-09-20 10:30:00+02:00 740.798266 208.670000 0.1907
2025-09-20 11:00:00+02:00 833.220026 511.338333 0.1907
2025-09-20 11:30:00+02:00 904.022853 805.836250 0.1907
2025-09-20 12:00:00+02:00 900.484450 178.190000 0.1907
2025-09-20 12:30:00+02:00 859.191958 119.761250 0.1907
2025-09-20 13:00:00+02:00 949.050396 132.333333 0.1907
2025-09-20 13:30:00+02:00 900.378191 121.722500 0.1907
2025-09-20 14:00:00+02:00 836.257399 64.693333 0.1907
2025-09-20 14:30:00+02:00 769.981402 74.296667 0.1907
2025-09-20 15:00:00+02:00 689.710427 341.426667 0.1907
2025-09-20 15:30:00+02:00 602.088071 145.084444 0.1419
2025-09-20 16:00:00+02:00 517.615094 86.147833 0.1419
2025-09-20 16:30:00+02:00 437.564567 142.053300 0.1419
2025-09-20 17:00:00+02:00 358.005471 1214.656517 0.1419
2025-09-20 17:30:00+02:00 274.257905 248.987300 0.1907
2025-09-20 18:00:00+02:00 182.222218 256.158800 0.1907
2025-09-20 18:30:00+02:00 76.939975 189.895750 0.1907
2025-09-20 19:00:00+02:00 0.000000 216.938333 0.1907
2025-09-20 19:30:00+02:00 0.000000 169.537289 0.1907
2025-09-20 20:00:00+02:00 0.000000 150.405117 0.1907
2025-09-20 20:30:00+02:00 0.000000 261.000100 0.1419
2025-09-20 21:00:00+02:00 0.000000 292.655767 0.1419
2025-09-20 21:30:00+02:00 0.000000 217.448978 0.1419
2025-09-20 22:00:00+02:00 0.000000 91.111967 0.1419
2025-09-20 22:30:00+02:00 0.000000 40.081500 0.1419
2025-09-20 23:00:00+02:00 0.000000 2.216120 0.1419
2025-09-20 23:30:00+02:00 0.000000 43.404463 0.1419
2025-09-21 00:00:00+02:00 0.000000 1.437750 0.1419
[2025-09-20 00:37:41 +0200] [23] [DEBUG] get_prod_price_forecast returning:
P_PV_forecast ... unit_prod_price
2025-09-20 00:30:00+02:00 0.000000 ... 0.1419
2025-09-20 01:00:00+02:00 0.000000 ... 0.1419
2025-09-20 01:30:00+02:00 0.000000 ... 0.1419
2025-09-20 02:00:00+02:00 0.000000 ... 0.1419
2025-09-20 02:30:00+02:00 0.000000 ... 0.1419
2025-09-20 03:00:00+02:00 0.000000 ... 0.1419
2025-09-20 03:30:00+02:00 0.000000 ... 0.1419
2025-09-20 04:00:00+02:00 0.000000 ... 0.1419
2025-09-20 04:30:00+02:00 0.000000 ... 0.1419
2025-09-20 05:00:00+02:00 0.000000 ... 0.1419
2025-09-20 05:30:00+02:00 0.000000 ... 0.1419
2025-09-20 06:00:00+02:00 0.000000 ... 0.1419
2025-09-20 06:30:00+02:00 0.000000 ... 0.1419
2025-09-20 07:00:00+02:00 0.000000 ... 0.1419
2025-09-20 07:30:00+02:00 52.753367 ... 0.1419
2025-09-20 08:00:00+02:00 143.604149 ... 0.1419
2025-09-20 08:30:00+02:00 246.909983 ... 0.1419
2025-09-20 09:00:00+02:00 389.462767 ... 0.1419
2025-09-20 09:30:00+02:00 551.590477 ... 0.1419
2025-09-20 10:00:00+02:00 659.795442 ... 0.1419
2025-09-20 10:30:00+02:00 740.798266 ... 0.1419
2025-09-20 11:00:00+02:00 833.220026 ... 0.1419
2025-09-20 11:30:00+02:00 904.022853 ... 0.1419
2025-09-20 12:00:00+02:00 900.484450 ... 0.1419
2025-09-20 12:30:00+02:00 859.191958 ... 0.1419
2025-09-20 13:00:00+02:00 949.050396 ... 0.1419
2025-09-20 13:30:00+02:00 900.378191 ... 0.1419
2025-09-20 14:00:00+02:00 836.257399 ... 0.1419
2025-09-20 14:30:00+02:00 769.981402 ... 0.1419
2025-09-20 15:00:00+02:00 689.710427 ... 0.1419
2025-09-20 15:30:00+02:00 602.088071 ... 0.1419
2025-09-20 16:00:00+02:00 517.615094 ... 0.1419
2025-09-20 16:30:00+02:00 437.564567 ... 0.1419
2025-09-20 17:00:00+02:00 358.005471 ... 0.1419
2025-09-20 17:30:00+02:00 274.257905 ... 0.1419
2025-09-20 18:00:00+02:00 182.222218 ... 0.1419
2025-09-20 18:30:00+02:00 76.939975 ... 0.1419
2025-09-20 19:00:00+02:00 0.000000 ... 0.1419
2025-09-20 19:30:00+02:00 0.000000 ... 0.1419
2025-09-20 20:00:00+02:00 0.000000 ... 0.1419
2025-09-20 20:30:00+02:00 0.000000 ... 0.1419
2025-09-20 21:00:00+02:00 0.000000 ... 0.1419
2025-09-20 21:30:00+02:00 0.000000 ... 0.1419
2025-09-20 22:00:00+02:00 0.000000 ... 0.1419
2025-09-20 22:30:00+02:00 0.000000 ... 0.1419
2025-09-20 23:00:00+02:00 0.000000 ... 0.1419
2025-09-20 23:30:00+02:00 0.000000 ... 0.1419
2025-09-21 00:00:00+02:00 0.000000 ... 0.1419
[48 rows x 4 columns]
[2025-09-20 00:37:41 +0200] [23] [INFO] Perform optimization for the day-ahead
[2025-09-20 00:37:41 +0200] [23] [DEBUG] Battery usage enabled. Initial SOC: 0, Final SOC: 0
[2025-09-20 00:37:41 +0200] [23] [DEBUG] Processing deferrable load 0
[2025-09-20 00:37:41 +0200] [23] [DEBUG] Load 0 is standard/non-thermal.
[2025-09-20 00:37:41 +0200] [23] [DEBUG] Load 0: Using total hours constraint: 2
[2025-09-20 00:37:41 +0200] [23] [DEBUG] Load 0: Standard load constraints set.
[2025-09-20 00:37:41 +0200] [23] [DEBUG] Deferrable load 0: Proposed optimization window: 0 --> 0
[2025-09-20 00:37:41 +0200] [23] [DEBUG] Deferrable load 0: Validated optimization window: 0 --> 0
[2025-09-20 00:37:41 +0200] [23] [DEBUG] Processing deferrable load 1
[2025-09-20 00:37:41 +0200] [23] [DEBUG] Load 1 is standard/non-thermal.
[2025-09-20 00:37:41 +0200] [23] [DEBUG] Load 1: Using total hours constraint: 1
[2025-09-20 00:37:41 +0200] [23] [DEBUG] Load 1: Standard load constraints set.
[2025-09-20 00:37:41 +0200] [23] [DEBUG] Deferrable load 1: Proposed optimization window: 0 --> 0
[2025-09-20 00:37:41 +0200] [23] [DEBUG] Deferrable load 1: Validated optimization window: 0 --> 0
[2025-09-20 00:37:42 +0200] [23] [INFO] Status: Optimal
[2025-09-20 00:37:42 +0200] [23] [INFO] Total value of the Cost function = -8.55
[2025-09-20 00:37:42 +0200] [23] [DEBUG] Battery usage enabled. Initial SOC: 0, Final SOC: 0
[2025-09-20 00:37:42 +0200] [23] [DEBUG] Deferrable load operating hours: [2, 1]
[2025-09-20 00:37:42 +0200] [23] [DEBUG] Deferrable load timesteps: None
[2025-09-20 00:37:42 +0200] [23] [DEBUG] Deferrable load start timesteps: [0, 0]
[2025-09-20 00:37:42 +0200] [23] [DEBUG] Deferrable load end timesteps: [0, 0]
[2025-09-20 00:37:42 +0200] [23] [DEBUG] Selected cost function type: profit
[2025-09-20 00:37:42 +0200] [23] [DEBUG] Solver selected: COIN_CMD
[2025-09-20 00:37:42 +0200] [23] [INFO] Optimization status: Optimal
[2025-09-20 00:37:42 +0200] [23] [DEBUG] Solver selected: COIN_CMD
[2025-09-20 00:37:42 +0200] [23] [INFO] Optimization status: Optimal
It is also stated in the log [2025-09-20 00:37:37 +0200] [23] [ERROR] ERROR: The passed data is either the wrong type or the length is not correct, length should be 48.
Strange!
“optimization_time_step”: 60 → Perhaps EMHASS interprets this weirdly (it ends up as 0:30:00 in your logs).
Try
“optimization_time_step”: “1:00:00”, → EMHASS might accept this as a 1-hour step or “0:30:00” for 30 min.
Restart EMHASS and see if it works.


















