Both commands do not provide any output.
Still getting
2023-03-20T14:00:13.835447309Z stdout ValueError: Shape of passed values is (18, 1), indices imply (19, 1)
2023-03-20T14:00:13.835367883Z stdout raise ValueError(f"Shape of passed values is {passed}, indices imply {implied}")
2023-03-20T14:00:13.835291506Z stdout File "/usr/local/lib/python3.8/site-packages/pandas/core/internals/construction.py", line 422, in _check_values_indices_shape_match
2023-03-20T14:00:13.835222105Z stdout _check_values_indices_shape_match(values, index, columns)
2023-03-20T14:00:13.835145542Z stdout File "/usr/local/lib/python3.8/site-packages/pandas/core/internals/construction.py", line 351, in ndarray_to_mgr
2023-03-20T14:00:13.835059003Z stdout mgr = ndarray_to_mgr(
2023-03-20T14:00:13.834901325Z stdout File "/usr/local/lib/python3.8/site-packages/pandas/core/frame.py", line 694, in __init__
2023-03-20T14:00:13.834745660Z stdout forecast_out = pd.DataFrame(
2023-03-20T14:00:13.834588757Z stdout File "/usr/local/lib/python3.8/site-packages/emhass-0.4.8-py3.8.egg/emhass/forecast.py", line 522, in get_forecast_out_from_csv
2023-03-20T14:00:13.834432342Z stdout forecast_out = self.get_forecast_out_from_csv(
2023-03-20T14:00:13.834272865Z stdout File "/usr/local/lib/python3.8/site-packages/emhass-0.4.8-py3.8.egg/emhass/forecast.py", line 705, in get_load_cost_forecast
2023-03-20T14:00:13.834103375Z stdout df_input_data_dayahead = input_data_dict['fcst'].get_load_cost_forecast(
2023-03-20T14:00:13.833458489Z stdout File "/usr/local/lib/python3.8/site-packages/emhass-0.4.8-py3.8.egg/emhass/command_line.py", line 264, in naive_mpc_optim
2023-03-20T14:00:13.832742090Z stdout opt_res = naive_mpc_optim(input_data_dict, app.logger)
2023-03-20T14:00:13.832659863Z stdout File "src/emhass/web_server.py", line 195, in action_call
2023-03-20T14:00:13.832585825Z stdout return self.ensure_sync(self.view_functions[rule.endpoint])(**view_args)
2023-03-20T14:00:13.832504986Z stdout File "/usr/local/lib/python3.8/site-packages/flask/app.py", line 1799, in dispatch_request
2023-03-20T14:00:13.832416947Z stdout rv = self.dispatch_request()
2023-03-20T14:00:13.832339721Z stdout File "/usr/local/lib/python3.8/site-packages/flask/app.py", line 1823, in full_dispatch_request
2023-03-20T14:00:13.832239419Z stdout rv = self.handle_user_exception(e)
2023-03-20T14:00:13.832151243Z stdout File "/usr/local/lib/python3.8/site-packages/flask/app.py", line 1825, in full_dispatch_request
2023-03-20T14:00:13.832039116Z stdout response = self.full_dispatch_request()
2023-03-20T14:00:13.831919639Z stdout File "/usr/local/lib/python3.8/site-packages/flask/app.py", line 2528, in wsgi_app
2023-03-20T14:00:13.831817412Z stdout Traceback (most recent call last):
2023-03-20T14:00:13.831725936Z stdout 2023-03-20 15:00:13,459 - web_server - ERROR - Exception on /action/naive-mpc-optim [POST]
The strange thing is that I do not always get the error. Sometimes its just infeasible and so on:
date stream content
2023-03-20T14:05:28.732428448Z stdout 2023-03-20 15:05:28,731 - web_server - INFO - Perform an iteration of a naive MPC controller
2023-03-20T14:05:28.695987004Z stdout 2023-03-20 15:05:28,695 - web_server - INFO - Performing naive MPC optimization
2023-03-20T14:05:28.695276530Z stdout 2023-03-20 15:05:28,694 - web_server - INFO - >> Performing naive MPC optimization...
2023-03-20T14:05:16.871901231Z stdout 2023-03-20 15:05:16,871 - web_server - INFO - Retrieve hass get data method initiated...
2023-03-20T14:05:16.870058338Z stdout 2023-03-20 15:05:16,869 - web_server - INFO - Retrieving data from hass for load forecast using method = naive
2023-03-20T14:05:16.866424441Z stdout 2023-03-20 15:05:16,865 - web_server - INFO - Retrieving weather forecast data using method = list
2023-03-20T14:05:12.984717949Z stdout 2023-03-20 15:05:12,984 - web_server - INFO - Total value of the Cost function = -0.24
2023-03-20T14:05:12.984358818Z stdout 2023-03-20 15:05:12,983 - web_server - INFO - Status: Infeasible
2023-03-20T14:05:12.851454925Z stdout 2023-03-20 15:05:12,850 - web_server - INFO - Perform an iteration of a naive MPC controller
2023-03-20T14:05:12.813338629Z stdout 2023-03-20 15:05:12,812 - web_server - INFO - Retrieve hass get data method initiated...
2023-03-20T14:05:12.804643249Z stdout 2023-03-20 15:05:12,804 - web_server - INFO - Setting up needed data
2023-03-20T14:05:12.790336916Z stdout 2023-03-20 15:05:12,789 - web_server - INFO - Performing naive MPC optimization
2023-03-20T14:05:12.789372500Z stdout 2023-03-20 15:05:12,788 - web_server - INFO - >> Performing naive MPC optimization...
2023-03-20T14:04:59.719468748Z stdout 2023-03-20 15:04:59,719 - web_server - INFO - Retrieve hass get data method initiated...
2023-03-20T14:04:59.717977299Z stdout 2023-03-20 15:04:59,717 - web_server - INFO - Retrieving data from hass for load forecast using method = naive
2023-03-20T14:04:59.713796068Z stdout 2023-03-20 15:04:59,713 - web_server - INFO - Retrieving weather forecast data using method = list
2023-03-20T14:04:56.265117038Z stdout 2023-03-20 15:04:55,807 - web_server - INFO - Retrieve hass get data method initiated...
2023-03-20T14:04:56.265023361Z stdout 2023-03-20 15:04:55,800 - web_server - INFO - Setting up needed data
2023-03-20T14:04:56.264959722Z stdout 2023-03-20 15:04:55,523 - web_server - INFO - Successfully posted to sensor.total_cost_fun_value = -0.24
2023-03-20T14:04:56.264895996Z stdout 2023-03-20 15:04:55,501 - web_server - INFO - Successfully posted to sensor.p_grid_forecast = 468.89
2023-03-20T14:04:56.264831158Z stdout 2023-03-20 15:04:55,475 - web_server - INFO - Successfully posted to sensor.p_deferrable0 = 643.0
2023-03-20T14:04:56.264682768Z stdout 2023-03-20 15:04:55,447 - web_server - INFO - Successfully posted to sensor.p_load_forecast = 528.67
2023-03-20T14:04:55.421960799Z stdout 2023-03-20 15:04:55,421 - web_server - INFO - Successfully posted to sensor.p_pv_forecast = 702.78
2023-03-20T14:04:55.383227618Z stdout 2023-03-20 15:04:55,382 - web_server - INFO - Publishing data to HASS instance
2023-03-20T14:04:55.382966613Z stdout 2023-03-20 15:04:55,382 - web_server - INFO - >> Publishing data...
2023-03-20T14:04:55.377259720Z stdout 2023-03-20 15:04:55,376 - web_server - INFO - Setting up needed data
2023-03-20T14:03:43.922137651Z stdout 2023-03-20 15:03:43,921 - web_server - INFO - Total value of the Cost function = -0.24
2023-03-20T14:03:43.921356488Z stdout 2023-03-20 15:03:43,920 - web_server - INFO - Status: Infeasible
2023-03-20T14:03:18.564931845Z stdout 2023-03-20 15:03:18,564 - web_server - INFO - Total value of the Cost function = -0.24
2023-03-20T14:03:18.564528064Z stdout 2023-03-20 15:03:18,563 - web_server - INFO - Status: Infeasible
2023-03-20T14:03:18.441925465Z stdout 2023-03-20 15:03:18,440 - web_server - INFO - Perform an iteration of a naive MPC controller
2023-03-20T14:03:18.403213108Z stdout 2023-03-20 15:03:18,402 - web_server - INFO - Performing naive MPC optimization
2023-03-20T14:03:18.402328681Z stdout 2023-03-20 15:03:18,401 - web_server - INFO - >> Performing naive MPC optimization...
2023-03-20T14:03:06.126366334Z stdout 2023-03-20 15:03:06,126 - web_server - INFO - Retrieve hass get data method initiated...
2023-03-20T14:03:06.124971161Z stdout 2023-03-20 15:03:06,124 - web_server - INFO - Retrieving data from hass for load forecast using method = naive
2023-03-20T14:03:06.121124673Z stdout 2023-03-20 15:03:06,120 - web_server - INFO - Retrieving weather forecast data using method = list
2023-03-20T14:03:01.137620302Z stdout 2023-03-20 15:03:01,137 - web_server - INFO - Retrieve hass get data method initiated...
2023-03-20T14:03:01.129542770Z stdout 2023-03-20 15:03:01,128 - web_server - INFO - Setting up needed data
2023-03-20T14:02:18.252696057Z stdout 2023-03-20 15:02:18,252 - web_server - INFO - Perform an iteration of a naive MPC controller
2023-03-20T14:02:18.217167477Z stdout 2023-03-20 15:02:18,216 - web_server - INFO - Performing naive MPC optimization
2023-03-20T14:02:18.216474791Z stdout 2023-03-20 15:02:18,215 - web_server - INFO - >> Performing naive MPC optimization...
2023-03-20T14:02:06.443701347Z stdout 2023-03-20 15:02:06,443 - web_server - INFO - Retrieve hass get data method initiated...
2023-03-20T14:02:06.441654001Z stdout 2023-03-20 15:02:06,441 - web_server - INFO - Retrieving data from hass for load forecast using method = naive
2023-03-20T14:02:06.437564459Z stdout 2023-03-20 15:02:06,436 - web_server - INFO - Retrieving weather forecast data using method = list