diff --git a/src/emhass/forecast.py b/src/emhass/forecast.py index 509200e3..28d1a314 100644 --- a/src/emhass/forecast.py +++ b/src/emhass/forecast.py @@ -658,7 +658,7 @@ def get_load_forecast(self, days_min_load_forecast: Optional[int] = 3, method: O return P_Load_forecast def get_load_cost_forecast(self, df_final: pd.DataFrame, method: Optional[str] = 'hp_hc_periods', - csv_path: Optional[str] = "/data/data_load_cost_forecast.csv") -> pd.DataFrame: + csv_path: Optional[str] = "data_load_cost_forecast.csv") -> pd.DataFrame: r""" Get the unit cost for the load consumption based on multiple tariff \ periods. This is the cost of the energy from the utility in a vector \ @@ -671,7 +671,7 @@ def get_load_cost_forecast(self, df_final: pd.DataFrame, method: Optional[str] = and 'csv' to load a CSV file, defaults to 'hp_hc_periods' :type method: str, optional :param csv_path: The path to the CSV file used when method = 'csv', \ - defaults to "/data/data_load_cost_forecast.csv" + defaults to "data_load_cost_forecast.csv" :type csv_path: str, optional :return: The input DataFrame with one additionnal column appended containing the load cost for each time observation. diff --git a/tests/test_forecast.py b/tests/test_forecast.py index c3b51ece..cb9611f8 100644 --- a/tests/test_forecast.py +++ b/tests/test_forecast.py @@ -413,7 +413,8 @@ def test_get_load_cost_forecast(self): df_input_data = self.fcst.get_load_cost_forecast(self.df_input_data) self.assertTrue(self.fcst.var_load_cost in df_input_data.columns) self.assertTrue(df_input_data.isnull().sum().sum()==0) - df_input_data = self.fcst.get_load_cost_forecast(self.df_input_data, method='csv') + df_input_data = self.fcst.get_load_cost_forecast(self.df_input_data, method='csv', + csv_path='/data/data_load_cost_forecast.csv') self.assertTrue(self.fcst.var_load_cost in df_input_data.columns) self.assertTrue(df_input_data.isnull().sum().sum()==0) @@ -421,7 +422,8 @@ def test_get_prod_price_forecast(self): df_input_data = self.fcst.get_prod_price_forecast(self.df_input_data) self.assertTrue(self.fcst.var_prod_price in df_input_data.columns) self.assertTrue(df_input_data.isnull().sum().sum()==0) - df_input_data = self.fcst.get_prod_price_forecast(self.df_input_data, method='csv') + df_input_data = self.fcst.get_prod_price_forecast(self.df_input_data, method='csv', + csv_path='/data/data_load_cost_forecast.csv') self.assertTrue(self.fcst.var_prod_price in df_input_data.columns) self.assertTrue(df_input_data.isnull().sum().sum()==0)