def execute(self, parameters, messages): import cea.demand reload(cea.demand) scenario_path = parameters[0].valueAsText locator = inputlocator.InputLocator(scenario_path) cea.demand.demand_calculation(locator=locator, gv=gv)
def test_properties(): """ Run the properties script with input from the reference case and compare the results. This ensures that changes made to this script (e.g. refactorings) do not stop the script from working and also that the results stay the same. """ locator = inputlocator.InputLocator(scenario_path=r'C:\reference-case\baseline') properties(locator=locator, prop_thermal_flag=True, prop_architecture_flag=True, prop_hvac_flag=True, gv=gv) print 'test_properties() succeeded'
def execute(self, parameters, messages): from cea.embodied import lca_embodied yearcalc = int(parameters[0].valueAsText) scenario_path = parameters[1].valueAsText locator = inputlocator.InputLocator(scenario_path=scenario_path) lca_embodied(yearcalc=yearcalc, locator=locator, gv=gv)
def test_graph_demand(): # HINTS FOR ARCGIS INTERFACE: # the user should see all the column names of the total_demands.csv # the user can select a maximum of 4 of those column names to graph (analysis fields! analysis_fields = ["Ealf_kWh", "Qhsf_kWh", "Qwwf_kWh", "Qcsf_kWh"] locator = inputlocator.InputLocator( scenario_path=r'C:\reference-case\baseline') graphs_demand(locator=locator, analysis_fields=analysis_fields)
def test_heatmaps(): locator = inputlocator.InputLocator( scenario_path=r'C:\reference-case\baseline') selection = 'Total_Demand.csv' path_variables = locator.get_demand_results_file(selection) path_results = locator.get_heatmaps_demand_folder() analysis_field_variables = ["Qhsf_MWhyr", "Qcsf_MWhyr"] # noqa heatmaps(locator=locator, analysis_field_variables=analysis_field_variables, path_results=path_results, path_variables=path_variables)
def execute(self, parameters, messages): from cea.properties import properties scenario_path = parameters[0].valueAsText locator = inputlocator.InputLocator(scenario_path) prop_thermal_flag = parameters[1] prop_architecture_flag = parameters[2] prop_HVAC_flag = parameters[3] properties(locator=locator, prop_thermal_flag=prop_thermal_flag.value, prop_architecture_flag=prop_architecture_flag.value, prop_hvac_flag=prop_HVAC_flag.value, gv=gv)
def test_lca_operation(): Qww_flag = Qhs_flag = True Qcs_flag = Qcdata_flag = Qcrefri_flag = True Eal_flag = Eaux_flag = Epro_flag = Edata_flag = True locator = inputlocator.InputLocator( scenario_path=r'C:\reference-case\baseline') lca_operation(locator=locator, Qww_flag=Qww_flag, Qhs_flag=Qhs_flag, Qcs_flag=Qcs_flag, Qcdata_flag=Qcdata_flag, Qcrefri_flag=Qcrefri_flag, Eal_flag=Eal_flag, Eaux_flag=Eaux_flag, Epro_flag=Epro_flag, Edata_flag=Edata_flag) print 'test_properties() succeeded'
def execute(self, parameters, messages): from cea.emissions import lca_operation import inputlocator scenario_path = parameters[0].valueAsText locator = inputlocator.InputLocator(scenario_path) Qww_flag = parameters[1].value Qhs_flag = parameters[2].value Qcs_flag = parameters[3].value Qcdata_flag = parameters[4].value Qcrefri_flag = parameters[5].value Eal_flag = parameters[6].value Eaux_flag = parameters[7].value Epro_flag = parameters[8].value Edata_flag = parameters[9].value lca_operation(locator=locator, Qww_flag=Qww_flag, Qhs_flag=Qhs_flag, Qcs_flag=Qcs_flag, Qcdata_flag=Qcdata_flag, Qcrefri_flag=Qcrefri_flag, Eal_flag=Eal_flag, Eaux_flag=Eaux_flag, Epro_flag=Epro_flag, Edata_flag=Edata_flag)
def test_lca_embodied(): locator = inputlocator.InputLocator(scenario_path=r'C:\reference-case\baseline') yearcalc = 2050 lca_embodied(locator=locator, yearcalc=yearcalc, gv=gv)
def test_demand(): locator = inputlocator.InputLocator( scenario_path=r'C:\reference-case\baseline') demand_calculation(locator=locator, gv=gv)