Bugfixing in packet

This commit is contained in:
Guille Gutierrez 2023-07-17 14:35:12 -04:00
parent a07f368047
commit 890171dc3a
11 changed files with 24 additions and 24 deletions

View File

@ -22,19 +22,7 @@ BASEMENT_HEATED_CASE = 1
CLIMATE_REFERENCE_CITY = 'Montreal' CLIMATE_REFERENCE_CITY = 'Montreal'
WEATHER_FILE = 'CAN_PQ_Montreal.Intl.AP.716270_CWEC.epw' WEATHER_FILE = 'CAN_PQ_Montreal.Intl.AP.716270_CWEC.epw'
WEATHER_FORMAT = 'epw' WEATHER_FORMAT = 'epw'
CURRENT_STATUS = 0
# constants
SKIN_RETROFIT = 1
SYSTEM_RETROFIT_AND_PV = 2
SKIN_RETROFIT_AND_SYSTEM_RETROFIT_AND_PV = 3
RETROFITTING_SCENARIOS = [
CURRENT_STATUS,
SKIN_RETROFIT,
SYSTEM_RETROFIT_AND_PV,
SKIN_RETROFIT_AND_SYSTEM_RETROFIT_AND_PV
]
tmp_folder = Path('./tmp').resolve() tmp_folder = Path('./tmp').resolve()
out_path = Path('./outputs').resolve() out_path = Path('./outputs').resolve()
files = glob.glob(f'{out_path}/*') files = glob.glob(f'{out_path}/*')

View File

@ -7,8 +7,8 @@ import pandas as pd
import numpy_financial as npf import numpy_financial as npf
from hub.city_model_structure.building import Building from hub.city_model_structure.building import Building
import hub.helpers.constants as cte import hub.helpers.constants as cte
from configuration import Configuration from costs.configuration import Configuration
from costs import SKIN_RETROFIT, SKIN_RETROFIT_AND_SYSTEM_RETROFIT_AND_PV, SYSTEM_RETROFIT_AND_PV from costs.constants import SKIN_RETROFIT, SKIN_RETROFIT_AND_SYSTEM_RETROFIT_AND_PV, SYSTEM_RETROFIT_AND_PV
from costs.cost_base import CostBase from costs.cost_base import CostBase

View File

@ -1,7 +1,7 @@
""" """
Configuration module Configuration module
""" """
from hub.catalog_factories.costs_catalog_factory import CostCatalogFactory from hub.catalog_factories.costs_catalog_factory import CostsCatalogFactory
from hub.catalog_factories.catalog import Catalog from hub.catalog_factories.catalog import Catalog
@ -36,7 +36,7 @@ class Configuration:
self._discount_rate = discount_rate self._discount_rate = discount_rate
self._retrofitting_year_construction = retrofitting_year_construction self._retrofitting_year_construction = retrofitting_year_construction
self._factories_handler = factories_handler self._factories_handler = factories_handler
self._cost_catalog = CostCatalogFactory(factories_handler).catalog self._cost_catalog = CostsCatalogFactory(factories_handler).catalog
self._retrofit_scenario = retrofit_scenario self._retrofit_scenario = retrofit_scenario
self._fuel_type = fuel_type self._fuel_type = fuel_type

11
costs/constants.py Normal file
View File

@ -0,0 +1,11 @@
# constants
CURRENT_STATUS = 0
SKIN_RETROFIT = 1
SYSTEM_RETROFIT_AND_PV = 2
SKIN_RETROFIT_AND_SYSTEM_RETROFIT_AND_PV = 3
RETROFITTING_SCENARIOS = [
CURRENT_STATUS,
SKIN_RETROFIT,
SYSTEM_RETROFIT_AND_PV,
SKIN_RETROFIT_AND_SYSTEM_RETROFIT_AND_PV
]

View File

@ -5,9 +5,9 @@ import pandas as pd
import numpy_financial as npf import numpy_financial as npf
from hub.city_model_structure.building import Building from hub.city_model_structure.building import Building
from configuration import Configuration from costs.configuration import Configuration
from costs import CapitalCosts, EndOfLifeCosts, TotalMaintenanceCosts, TotalOperationalCosts, TotalOperationalIncomes from costs import CapitalCosts, EndOfLifeCosts, TotalMaintenanceCosts, TotalOperationalCosts, TotalOperationalIncomes
from costs import CURRENT_STATUS from costs.constants import CURRENT_STATUS
class Cost: class Cost:

View File

@ -4,7 +4,7 @@ Cost base module
from hub.city_model_structure.building import Building from hub.city_model_structure.building import Building
from configuration import Configuration from costs.configuration import Configuration
class CostBase: class CostBase:

View File

@ -5,7 +5,7 @@ import math
import pandas as pd import pandas as pd
from hub.city_model_structure.building import Building from hub.city_model_structure.building import Building
from configuration import Configuration from costs.configuration import Configuration
from costs.cost_base import CostBase from costs.cost_base import CostBase

View File

@ -6,7 +6,7 @@ import pandas as pd
from hub.city_model_structure.building import Building from hub.city_model_structure.building import Building
import hub.helpers.constants as cte import hub.helpers.constants as cte
from configuration import Configuration from costs.configuration import Configuration
from costs.cost_base import CostBase from costs.cost_base import CostBase

View File

@ -7,7 +7,7 @@ import pandas as pd
from hub.city_model_structure.building import Building from hub.city_model_structure.building import Building
import hub.helpers.constants as cte import hub.helpers.constants as cte
from configuration import Configuration from costs.configuration import Configuration
from costs.cost_base import CostBase from costs.cost_base import CostBase

View File

@ -6,7 +6,7 @@ import pandas as pd
from hub.city_model_structure.building import Building from hub.city_model_structure.building import Building
import hub.helpers.constants as cte import hub.helpers.constants as cte
from configuration import Configuration from costs.configuration import Configuration
from costs.cost_base import CostBase from costs.cost_base import CostBase

View File

@ -1,2 +1,3 @@
numpy_financial numpy_financial
cerc_hub cerc_hub
pandas