From 2ef322d8594b59b725653aebb6b7db7d2f291f90 Mon Sep 17 00:00:00 2001 From: softwareengineerprogrammer <4056124+softwareengineerprogrammer@users.noreply.github.com> Date: Thu, 20 Feb 2025 07:30:05 -0800 Subject: [PATCH 01/14] Stimulation Costs param name FIXME --- src/geophires_x/Economics.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/geophires_x/Economics.py b/src/geophires_x/Economics.py index 57961c201..0538e0dea 100644 --- a/src/geophires_x/Economics.py +++ b/src/geophires_x/Economics.py @@ -1541,7 +1541,7 @@ def __init__(self, model: Model): CurrentUnits=EnergyCostUnit.DOLLARSPERMMBTU ) # $/MMBTU self.Cstim = self.OutputParameterDict[self.Cstim.Name] = OutputParameter( - Name="O&M Surface Plant costs", + Name="O&M Surface Plant costs", # FIXME wrong name - should be Stimulation Costs UnitType=Units.CURRENCY, PreferredUnits=CurrencyUnit.MDOLLARS, CurrentUnits=CurrencyUnit.MDOLLARS From bb947c61ec1e3bfe2907e7cfb04ecaed20494bca Mon Sep 17 00:00:00 2001 From: softwareengineerprogrammer <4056124+softwareengineerprogrammer@users.noreply.github.com> Date: Thu, 27 Feb 2025 09:05:04 -0800 Subject: [PATCH 02/14] Ending Electricity Sale Price documentation --- src/geophires_x/Economics.py | 8 +++++++- src/geophires_x_schema_generator/geophires-request.json | 2 +- 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/src/geophires_x/Economics.py b/src/geophires_x/Economics.py index 0538e0dea..2b92739bc 100644 --- a/src/geophires_x/Economics.py +++ b/src/geophires_x/Economics.py @@ -1221,7 +1221,13 @@ def __init__(self, model: Model): Max=100, UnitType=Units.ENERGYCOST, PreferredUnits=EnergyCostUnit.DOLLARSPERKWH, - CurrentUnits=EnergyCostUnit.DOLLARSPERKWH + CurrentUnits=EnergyCostUnit.DOLLARSPERKWH, + ToolTipText="The maximum price to which the electricity sale price can escalate. For example, if " + "Starting Electricity Sale Price = 0.10 USD/kWh and Electricity Escalation Rate = " + "0.01 USD/kWh/yr: Electricity Price will reach 0.15 USD/kWh after 4 years of escalation. " + "The price will then remain at 0.15 USD/kWh for the remaining years of the project lifetime. " + "If the Ending Electricity Sale Price is not reached by escalation during the project " + "lifetime, then the value will have no effect beyond allowing escalation to occur every year." ) self.ElecEscalationStart = self.ParameterDict[self.ElecEscalationStart.Name] = intParameter( "Electricity Escalation Start Year", diff --git a/src/geophires_x_schema_generator/geophires-request.json b/src/geophires_x_schema_generator/geophires-request.json index 58657a73b..53204fd73 100644 --- a/src/geophires_x_schema_generator/geophires-request.json +++ b/src/geophires_x_schema_generator/geophires-request.json @@ -1956,7 +1956,7 @@ "maximum": 100 }, "Ending Electricity Sale Price": { - "description": "", + "description": "The maximum price to which the electricity sale price can escalate. For example, if Starting Electricity Sale Price = 0.10 USD/kWh and Electricity Escalation Rate = 0.01 USD/kWh/yr: Electricity Price will reach 0.15 USD/kWh after 4 years of escalation. The price will then remain at 0.15 USD/kWh for the remaining years of the project lifetime. If the Ending Electricity Sale Price is not reached by escalation during the project lifetime, then the value will have no effect beyond allowing escalation to occur every year.", "type": "number", "units": "USD/kWh", "category": "Economics", From b56a6f44b5652aa9bc4e12ce5bd81af5982a9de2 Mon Sep 17 00:00:00 2001 From: softwareengineerprogrammer <4056124+softwareengineerprogrammer@users.noreply.github.com> Date: Thu, 27 Feb 2025 09:30:40 -0800 Subject: [PATCH 03/14] Add missing S-DAC result fields --- src/geophires_x/OutputsS_DAC_GT.py | 56 +++++++++++--------- src/geophires_x_client/geophires_x_result.py | 12 +++++ tests/examples/S-DAC-GT.out | 24 ++++----- 3 files changed, 55 insertions(+), 37 deletions(-) diff --git a/src/geophires_x/OutputsS_DAC_GT.py b/src/geophires_x/OutputsS_DAC_GT.py index b92d83e80..ae1af76e7 100644 --- a/src/geophires_x/OutputsS_DAC_GT.py +++ b/src/geophires_x/OutputsS_DAC_GT.py @@ -27,35 +27,41 @@ def PrintOutputs(self, model) -> tuple: sdac_results: list[OutputTableItem] = [] f.write(NL) f.write(NL) - f.write(" ***S_DAC_GT ECONOMICS***" + NL) + f.write(" ***S_DAC_GT ECONOMICS***\n") f.write(NL) f.write(NL) - f.write(f" S-DAC-GT Report: Levelized Cost of Direct Air Capture (LCOD)" + NL) + + msdac = model.sdacgteconomics + + f.write(f" S-DAC-GT Report: Levelized Cost of Direct Air Capture (LCOD)\n") sdac_results.append(OutputTableItem('S-DAC-GT Report: Levelized Cost of Direct Air Capture (LCOD)')) - f.write(f" Using grid-based electricity only: {model.sdacgteconomics.LCOD_elec.value:10.2f} " + model.sdacgteconomics.LCOD_elec.PreferredUnits.value + NL) - sdac_results.append(OutputTableItem('Using grid-based electricity only', '{0:10.2f}'.format(model.sdacgteconomics.LCOD_elec.value), model.sdacgteconomics.LCOD_elec.PreferredUnits.value)) - f.write(f" Using natural gas only: {model.sdacgteconomics.LCOD_ng.value:10.2f} " + model.sdacgteconomics.LCOD_ng.PreferredUnits.value + NL) - sdac_results.append(OutputTableItem('Using natural gas only', '{0:10.2f}'.format(model.sdacgteconomics.LCOD_ng.value), model.sdacgteconomics.LCOD_ng.PreferredUnits.value)) - f.write(f" Using geothermal energy only: {model.sdacgteconomics.LCOD_geo.value:10.2f} " + model.sdacgteconomics.LCOD_geo.PreferredUnits.value + NL + NL) - sdac_results.append(OutputTableItem('Using geothermal energy only', '{0:10.2f}'.format(model.sdacgteconomics.LCOD_geo.value), model.sdacgteconomics.LCOD_geo.PreferredUnits.value)) - f.write(f" S-DAC-GT Report: CO2 Intensity of process (percent of CO2 mitigated that is emitted by S-DAC process)" + NL) + lcod_prefix = 'LCOD' + f.write(f" {lcod_prefix} Using grid-based electricity only: {model.sdacgteconomics.LCOD_elec.value:10.2f} {msdac.LCOD_elec.PreferredUnits.value}\n") + sdac_results.append(OutputTableItem(f'Using grid-based electricity only', '{0:10.2f}'.format(msdac.LCOD_elec.value), msdac.LCOD_elec.PreferredUnits.value)) + f.write(f" {lcod_prefix} Using natural gas only: {model.sdacgteconomics.LCOD_ng.value:10.2f} {msdac.LCOD_ng.PreferredUnits.value}\n") + sdac_results.append(OutputTableItem('Using natural gas only', '{0:10.2f}'.format(model.sdacgteconomics.LCOD_ng.value), msdac.LCOD_ng.PreferredUnits.value)) + f.write(f" {lcod_prefix} Using geothermal energy only: {model.sdacgteconomics.LCOD_geo.value:10.2f} {msdac.LCOD_geo.PreferredUnits.value}\n\n") + sdac_results.append(OutputTableItem(f'Using geothermal energy only', '{0:10.2f}'.format(msdac.LCOD_geo.value), msdac.LCOD_geo.PreferredUnits.value)) + + f.write(f" S-DAC-GT Report: CO2 Intensity of process (percent of CO2 mitigated that is emitted by S-DAC process)\n") sdac_results.append(OutputTableItem('S-DAC-GT Report: CO2 Intensity of process (percent of CO2 mitigated that is emitted by S-DAC process)')) - f.write(f" Using grid-based electricity only: {model.sdacgteconomics.CO2total_elec.value*100.0:10.2f}%" + NL) - sdac_results.append(OutputTableItem('Using grid-based electricity only', '{0:10.2f}'.format(model.sdacgteconomics.CO2total_elec.value*100.0), '%')) - f.write(f" Using natural gas only: {model.sdacgteconomics.CO2total_ng.value*100:10.2f}%" + NL) - sdac_results.append(OutputTableItem('Using natural gas only', '{0:10.2f}'.format(model.sdacgteconomics.CO2total_ng.value*100.0), '%')) - f.write(f" Using geothermal energy only: {model.sdacgteconomics.CO2total_geo.value*100:10.2f}%" + NL + NL) - sdac_results.append(OutputTableItem('Using geothermal energy only', '{0:10.2f}'.format(model.sdacgteconomics.CO2total_geo.value*100.0), '%')) - f.write(f" Geothermal LCOH: {model.sdacgteconomics.LCOH.value:10.4f} " + model.sdacgteconomics.LCOH.PreferredUnits.value + NL) - sdac_results.append(OutputTableItem('Geothermal LCOH', '{0:10.4f}'.format(model.sdacgteconomics.LCOH.value), model.sdacgteconomics.LCOH.PreferredUnits.value)) - f.write(f" Geothermal Ratio (electricity vs heat):{model.sdacgteconomics.percent_thermal_energy_going_to_heat.value*100:10.4f}%" + NL) - sdac_results.append(OutputTableItem('Geothermal Ratio (electricity vs heat)', '{0:10.4f}'.format(model.sdacgteconomics.percent_thermal_energy_going_to_heat.value*100.0), '%')) - f.write(f" Percent Energy Devoted To Process: {model.sdacgteconomics.EnergySplit.value*100:10.4f}%" + NL + NL) - sdac_results.append(OutputTableItem('Percent Energy Devoted To Process', '{0:10.4f}'.format(model.sdacgteconomics.EnergySplit.value*100.0), '%')) - f.write(f" Total Tonnes of CO2 Captured: {model.sdacgteconomics.CarbonExtractedTotal.value:,.2f} " + model.sdacgteconomics.CarbonExtractedTotal.PreferredUnits.value + NL) - sdac_results.append(OutputTableItem('Total Tonnes of CO2 Captured', '{0:,.2f}'.format(model.sdacgteconomics.CarbonExtractedTotal.value), model.sdacgteconomics.CarbonExtractedTotal.PreferredUnits.value)) - f.write(f" Total Cost of Capture: {model.sdacgteconomics.S_DAC_GTCummCashFlow.value[len(model.sdacgteconomics.S_DAC_GTCummCashFlow.value)-1]:,.2f} " + model.sdacgteconomics.S_DAC_GTCummCashFlow.PreferredUnits.value + NL) - sdac_results.append(OutputTableItem('Total Cost of Capture', '{0:,.2f}'.format(model.sdacgteconomics.S_DAC_GTCummCashFlow.value[len(model.sdacgteconomics.S_DAC_GTCummCashFlow.value)-1]), model.sdacgteconomics.S_DAC_GTCummCashFlow.PreferredUnits.value)) + co2i_prefix = 'CO2 Intensity' + f.write(f" {co2i_prefix} Using grid-based electricity only: {msdac.CO2total_elec.value*100.0:10.2f} %\n") # TODO CurrentUnits + sdac_results.append(OutputTableItem('Using grid-based electricity only', '{0:10.2f}'.format(msdac.CO2total_elec.value*100.0), '%')) + f.write(f" {co2i_prefix} Using natural gas only: {msdac.CO2total_ng.value*100:10.2f} %\n") # TODO CurrentUnits + sdac_results.append(OutputTableItem('Using natural gas only', '{0:10.2f}'.format(msdac.CO2total_ng.value*100.0), '%')) + f.write(f" {co2i_prefix} Using geothermal energy only: {msdac.CO2total_geo.value*100:10.2f} %\n\n") # TODO CurrentUnits + sdac_results.append(OutputTableItem('Using geothermal energy only', '{0:10.2f}'.format(msdac.CO2total_geo.value*100.0), '%')) + f.write(f" Geothermal LCOH: {msdac.LCOH.value:10.4f} {msdac.LCOH.PreferredUnits.value}\n") + sdac_results.append(OutputTableItem('Geothermal LCOH', '{0:10.4f}'.format(msdac.LCOH.value), msdac.LCOH.PreferredUnits.value)) + f.write(f" Geothermal Ratio (electricity vs heat):{msdac.percent_thermal_energy_going_to_heat.value*100:10.4f} %\n") # TODO CurrentUnits + sdac_results.append(OutputTableItem('Geothermal Ratio (electricity vs heat)', '{0:10.4f}'.format(msdac.percent_thermal_energy_going_to_heat.value*100.0), '%')) + f.write(f" Percent Energy Devoted To Process: {msdac.EnergySplit.value*100:10.4f} %\n\n") # TODO CurrentUnits + sdac_results.append(OutputTableItem('Percent Energy Devoted To Process', '{0:10.4f}'.format(msdac.EnergySplit.value*100.0), '%')) + f.write(f" Total Tonnes of CO2 Captured: {msdac.CarbonExtractedTotal.value:,.2f} {msdac.CarbonExtractedTotal.PreferredUnits.value}\n") + sdac_results.append(OutputTableItem('Total Tonnes of CO2 Captured', '{0:,.2f}'.format(msdac.CarbonExtractedTotal.value), msdac.CarbonExtractedTotal.PreferredUnits.value)) + f.write(f" Total Cost of Capture: {msdac.S_DAC_GTCummCashFlow.value[len(msdac.S_DAC_GTCummCashFlow.value)-1]:,.2f} {msdac.S_DAC_GTCummCashFlow.PreferredUnits.value}\n") + sdac_results.append(OutputTableItem('Total Cost of Capture', '{0:,.2f}'.format(msdac.S_DAC_GTCummCashFlow.value[len(msdac.S_DAC_GTCummCashFlow.value)-1]), msdac.S_DAC_GTCummCashFlow.PreferredUnits.value)) f.write(NL) # Build the data frame to hold the SDAC result profile diff --git a/src/geophires_x_client/geophires_x_result.py b/src/geophires_x_client/geophires_x_result.py index 5628c1e5b..1fb1ff778 100644 --- a/src/geophires_x_client/geophires_x_result.py +++ b/src/geophires_x_client/geophires_x_result.py @@ -98,6 +98,18 @@ class GeophiresXResult: 'Project MOIC (including carbon credit)', 'Project Payback Period (including carbon credit)', ], + 'S_DAC_GT ECONOMICS': [ + 'LCOD Using grid-based electricity only', + 'LCOD Using natural gas only', + 'LCOD Using geothermal energy only', + 'CO2 Intensity Using grid-based electricity only', + 'CO2 Intensity Using natural gas only', + 'CO2 Intensity Using geothermal energy only', + 'Geothermal LCOH', + 'Geothermal Ratio (electricity vs heat)', + 'Percent Energy Devoted To Process', + 'Total Cost of Capture', + ], 'ENGINEERING PARAMETERS': [ 'Number of Production Wells', 'Number of Injection Wells', diff --git a/tests/examples/S-DAC-GT.out b/tests/examples/S-DAC-GT.out index 499441831..85481e0c6 100644 --- a/tests/examples/S-DAC-GT.out +++ b/tests/examples/S-DAC-GT.out @@ -4,10 +4,10 @@ Simulation Metadata ---------------------- - GEOPHIRES Version: 3.7.1 - Simulation Date: 2025-01-22 - Simulation Time: 10:48 - Calculation Time: 0.107 sec + GEOPHIRES Version: 3.7.13 + Simulation Date: 2025-02-27 + Simulation Time: 09:29 + Calculation Time: 0.099 sec ***SUMMARY OF RESULTS*** @@ -250,18 +250,18 @@ ________________________________________________________________________________ S-DAC-GT Report: Levelized Cost of Direct Air Capture (LCOD) - Using grid-based electricity only: 387.69 USD/tonne - Using natural gas only: 312.00 USD/tonne - Using geothermal energy only: 288.87 USD/tonne + LCOD Using grid-based electricity only: 387.69 USD/tonne + LCOD Using natural gas only: 312.00 USD/tonne + LCOD Using geothermal energy only: 288.87 USD/tonne S-DAC-GT Report: CO2 Intensity of process (percent of CO2 mitigated that is emitted by S-DAC process) - Using grid-based electricity only: 94.52% - Using natural gas only: 64.85% - Using geothermal energy only: 36.91% + CO2 Intensity Using grid-based electricity only: 94.52 % + CO2 Intensity Using natural gas only: 64.85 % + CO2 Intensity Using geothermal energy only: 36.91 % Geothermal LCOH: 0.0017 USD/kWh - Geothermal Ratio (electricity vs heat): 20.7259% - Percent Energy Devoted To Process: 50.0000% + Geothermal Ratio (electricity vs heat): 20.7259 % + Percent Energy Devoted To Process: 50.0000 % Total Tonnes of CO2 Captured: 2,246,284.10 tonne Total Cost of Capture: 499,311,405.59 USD From da628f9ad9e5faed1d07e0687b5ec4d2d22cd62d Mon Sep 17 00:00:00 2001 From: softwareengineerprogrammer <4056124+softwareengineerprogrammer@users.noreply.github.com> Date: Thu, 27 Feb 2025 09:35:25 -0800 Subject: [PATCH 04/14] parse result numbers with commas --- src/geophires_x_client/geophires_x_result.py | 3 ++- tests/test_geophires_x_client.py | 4 ++++ 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/src/geophires_x_client/geophires_x_result.py b/src/geophires_x_client/geophires_x_result.py index 1fb1ff778..232bd6946 100644 --- a/src/geophires_x_client/geophires_x_result.py +++ b/src/geophires_x_client/geophires_x_result.py @@ -681,10 +681,11 @@ def _get_data_from_profile_lines(self, profile_lines): return data def _parse_number(self, number_str, field='string') -> int | float: - if number_str == 'N/A': + if number_str == 'N/A' or number_str is None: return None try: + number_str = number_str.replace(',', '') if '.' in number_str: # TODO should probably ideally use decimal.Decimal to preserve precision, # i.e. 1.00 for USD instead of 1.0 diff --git a/tests/test_geophires_x_client.py b/tests/test_geophires_x_client.py index 028d26f16..4ffbd90bc 100644 --- a/tests/test_geophires_x_client.py +++ b/tests/test_geophires_x_client.py @@ -528,3 +528,7 @@ def test_parse_chp_percent_cost_allocation(self): def test_parse_annualized_capital_costs(self): result = GeophiresXResult(self._get_test_file_path('examples/example1_addons.out')) self.assertIsNotNone(result.result['CAPITAL COSTS (M$)']['Annualized capital costs']['value']) + + def test_parse_number_with_commas(self): + result = GeophiresXResult(self._get_test_file_path('examples/S-DAC-GT.out')) + self.assertEqual(result.result['S_DAC_GT ECONOMICS']['Total Cost of Capture']['value'], 499_311_405.59) From 18a0cbddde6bd386ec37f4791fdedff21d138e2b Mon Sep 17 00:00:00 2001 From: softwareengineerprogrammer <4056124+softwareengineerprogrammer@users.noreply.github.com> Date: Thu, 27 Feb 2025 09:36:52 -0800 Subject: [PATCH 05/14] =?UTF-8?q?Bump=20version:=203.7.13=20=E2=86=92=203.?= =?UTF-8?q?7.14?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .bumpversion.cfg | 2 +- .cookiecutterrc | 2 +- README.rst | 4 ++-- docs/conf.py | 2 +- setup.py | 2 +- src/geophires_x/__init__.py | 2 +- 6 files changed, 7 insertions(+), 7 deletions(-) diff --git a/.bumpversion.cfg b/.bumpversion.cfg index 444b849cd..2db82521c 100644 --- a/.bumpversion.cfg +++ b/.bumpversion.cfg @@ -1,5 +1,5 @@ [bumpversion] -current_version = 3.7.13 +current_version = 3.7.14 commit = True tag = True diff --git a/.cookiecutterrc b/.cookiecutterrc index b96357fc4..5b5956965 100644 --- a/.cookiecutterrc +++ b/.cookiecutterrc @@ -54,7 +54,7 @@ default_context: sphinx_doctest: "no" sphinx_theme: "sphinx-py3doc-enhanced-theme" test_matrix_separate_coverage: "no" - version: 3.7.13 + version: 3.7.14 version_manager: "bump2version" website: "https://github.com/NREL" year_from: "2023" diff --git a/README.rst b/README.rst index b07f38bea..5911ee7aa 100644 --- a/README.rst +++ b/README.rst @@ -56,9 +56,9 @@ Free software: `MIT license `__ :alt: Supported implementations :target: https://pypi.org/project/geophires-x -.. |commits-since| image:: https://img.shields.io/github/commits-since/softwareengineerprogrammer/GEOPHIRES-X/v3.7.13.svg +.. |commits-since| image:: https://img.shields.io/github/commits-since/softwareengineerprogrammer/GEOPHIRES-X/v3.7.14.svg :alt: Commits since latest release - :target: https://github.com/softwareengineerprogrammer/GEOPHIRES-X/compare/v3.7.13...main + :target: https://github.com/softwareengineerprogrammer/GEOPHIRES-X/compare/v3.7.14...main .. |docs| image:: https://readthedocs.org/projects/GEOPHIRES-X/badge/?style=flat :target: https://nrel.github.io/GEOPHIRES-X diff --git a/docs/conf.py b/docs/conf.py index 7f843f048..8ce77be93 100644 --- a/docs/conf.py +++ b/docs/conf.py @@ -18,7 +18,7 @@ year = '2025' author = 'NREL' copyright = f'{year}, {author}' -version = release = '3.7.13' +version = release = '3.7.14' pygments_style = 'trac' templates_path = ['./templates'] diff --git a/setup.py b/setup.py index d72ebfc12..7d7f2b280 100755 --- a/setup.py +++ b/setup.py @@ -13,7 +13,7 @@ def read(*names, **kwargs): setup( name='geophires-x', - version='3.7.13', + version='3.7.14', license='MIT', description='GEOPHIRES is a free and open-source geothermal techno-economic simulator.', long_description='{}\n{}'.format( diff --git a/src/geophires_x/__init__.py b/src/geophires_x/__init__.py index 475a8dce3..0e7dcdb34 100644 --- a/src/geophires_x/__init__.py +++ b/src/geophires_x/__init__.py @@ -1 +1 @@ -__version__ = '3.7.13' +__version__ = '3.7.14' From 3891928e91927d9f80095669498e3cc04f24c51e Mon Sep 17 00:00:00 2001 From: softwareengineerprogrammer <4056124+softwareengineerprogrammer@users.noreply.github.com> Date: Thu, 27 Feb 2025 09:48:16 -0800 Subject: [PATCH 06/14] Parse S_DAC_GT PROFILE --- src/geophires_x_client/geophires_x_result.py | 25 +++++++++++++++++++ tests/test_geophires_x_client.py | 26 ++++++++++++++++++++ 2 files changed, 51 insertions(+) diff --git a/src/geophires_x_client/geophires_x_result.py b/src/geophires_x_client/geophires_x_result.py index 232bd6946..b01155473 100644 --- a/src/geophires_x_client/geophires_x_result.py +++ b/src/geophires_x_client/geophires_x_result.py @@ -371,6 +371,10 @@ def __init__(self, output_file_path, logger_name=None): if ccus_profile is not None: self.result['CCUS PROFILE'] = ccus_profile + sdacgt_profile = self._get_sdacgt_profile() + if sdacgt_profile is not None: + self.result['S_DAC_GT PROFILE'] = sdacgt_profile + self.result['metadata'] = {'output_file_path': self.output_file_path} for metadata_field in GeophiresXResult._METADATA_FIELDS: self.result['metadata'][metadata_field] = self._get_equal_sign_delimited_field(metadata_field) @@ -595,6 +599,27 @@ def extract_table_header(lines: list) -> list: self._logger.debug(f'Failed to get extended economic profile: {e}') return None + def _get_sdacgt_profile(self): + def extract_table_header(lines: list) -> list: + # Tried various regexy approaches to extract this programmatically but landed on hard-coding. + return [ + 'Year Since Start', + 'Carbon Captured (tonne/yr)', + 'Cumm. Carbon Captured (tonne)', + 'S_DAC_GT Annual Cost (USD/yr)', + 'S_DAC_GT Cumm. Cash Flow (USD)', + 'Cumm. Cost Per Tonne (USD/tonne)', + ] + + try: + lines = self._get_profile_lines('S_DAC_GT PROFILE') + profile = [extract_table_header(lines)] + profile.extend(self._extract_addons_style_table_data(lines)) + return profile + except BaseException as e: + self._logger.debug(f'Failed to get S-DAC-GT profile: {e}') + return None + def _get_ccus_profile(self): """ FIXME TODO - transform from revenue & cashflow if present (CCUS profile replaced by revenue & cashflow diff --git a/tests/test_geophires_x_client.py b/tests/test_geophires_x_client.py index 4ffbd90bc..b8698b54e 100644 --- a/tests/test_geophires_x_client.py +++ b/tests/test_geophires_x_client.py @@ -532,3 +532,29 @@ def test_parse_annualized_capital_costs(self): def test_parse_number_with_commas(self): result = GeophiresXResult(self._get_test_file_path('examples/S-DAC-GT.out')) self.assertEqual(result.result['S_DAC_GT ECONOMICS']['Total Cost of Capture']['value'], 499_311_405.59) + + def test_parse_sdacgt_profile(self): + result = GeophiresXResult(self._get_test_file_path('examples/S-DAC-GT.out')) + sdacgt_profile = result.result['S_DAC_GT PROFILE'] + self.assertIsNotNone(sdacgt_profile) + self.assertEqual( + sdacgt_profile[0], + [ + 'Year Since Start', + 'Carbon Captured (tonne/yr)', + 'Cumm. Carbon Captured (tonne)', + 'S_DAC_GT Annual Cost (USD/yr)', + 'S_DAC_GT Cumm. Cash Flow (USD)', + 'Cumm. Cost Per Tonne (USD/tonne)', + ], + ) + + # Values below need to be synchronized if S-DAC-GT example output values change. + self.assertEqual(sdacgt_profile[1], [1, 78330.8, 78330.8, 17411627.98, 17411627.98, 222.28]) + + self.assertEqual( + sdacgt_profile[15], + [15, 76263.89, 1167207.48, 16952186.81, 259450710.33, 222.28], + ) + + self.assertEqual(sdacgt_profile[30], [30, 61974.61, 2246284.1, 13775920.11, 499311405.59, 222.28]) From 05b8886f01cfc97863b320af375adf84102882db Mon Sep 17 00:00:00 2001 From: softwareengineerprogrammer <4056124+softwareengineerprogrammer@users.noreply.github.com> Date: Thu, 27 Feb 2025 09:52:16 -0800 Subject: [PATCH 07/14] Raise RuntimeError instead of calling sys.exit in OutputsS_DA_GT.py --- src/geophires_x/OutputsS_DAC_GT.py | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/src/geophires_x/OutputsS_DAC_GT.py b/src/geophires_x/OutputsS_DAC_GT.py index ae1af76e7..87176bcbc 100644 --- a/src/geophires_x/OutputsS_DAC_GT.py +++ b/src/geophires_x/OutputsS_DAC_GT.py @@ -99,11 +99,13 @@ def PrintOutputs(self, model) -> tuple: except BaseException as ex: tb = sys.exc_info()[2] + msg = "Error: GEOPHIRES failed to Failed to write the output file. Exiting...Line %i" % tb.tb_lineno + print(str(ex)) - print("Error: GEOPHIRES failed to Failed to write the output file. Exiting....Line %i" % tb.tb_lineno) + print(msg) model.logger.critical(str(ex)) - model.logger.critical("Error: GEOPHIRES failed to Failed to write the output file. Exiting....Line %i" % tb.tb_lineno) - sys.exit() + model.logger.critical(msg) + raise RuntimeError(msg, e) model.logger.info(f'Complete {str(__class__)}: {__name__}') From 14487319215edbcadae8f37c41ca950b6c414fa9 Mon Sep 17 00:00:00 2001 From: softwareengineerprogrammer <4056124+softwareengineerprogrammer@users.noreply.github.com> Date: Thu, 27 Feb 2025 10:01:52 -0800 Subject: [PATCH 08/14] Change 'S_DAC_GT' to 'S-DAC-GT' in case report file and client parsing. Note that 'S_DAC_GT' remains in HTML output for now, since it may be in existing use, whereas the fields were missing entirely from the client until this patch version --- src/geophires_x/OutputsS_DAC_GT.py | 6 +++--- src/geophires_x_client/geophires_x_result.py | 11 ++++++----- tests/examples/S-DAC-GT.out | 12 ++++++------ tests/test_geophires_x_client.py | 8 ++++---- 4 files changed, 19 insertions(+), 18 deletions(-) diff --git a/src/geophires_x/OutputsS_DAC_GT.py b/src/geophires_x/OutputsS_DAC_GT.py index 87176bcbc..4f74840b5 100644 --- a/src/geophires_x/OutputsS_DAC_GT.py +++ b/src/geophires_x/OutputsS_DAC_GT.py @@ -27,7 +27,7 @@ def PrintOutputs(self, model) -> tuple: sdac_results: list[OutputTableItem] = [] f.write(NL) f.write(NL) - f.write(" ***S_DAC_GT ECONOMICS***\n") + f.write(" ***S-DAC-GT ECONOMICS***\n") f.write(NL) f.write(NL) @@ -83,9 +83,9 @@ def PrintOutputs(self, model) -> tuple: f.write(NL) f.write(" **********************" + NL) - f.write(" * S_DAC_GT PROFILE *" + NL) + f.write(" * S-DAC-GT PROFILE *" + NL) f.write(" **********************" + NL) - f.write("Year Carbon Cumm. Carbon S_DAC_GT S_DAC_GT Cumm. Cumm. Cost" + NL) + f.write("Year Carbon Cumm. Carbon S-DAC-GT S-DAC-GT Cumm. Cumm. Cost" + NL) f.write("Since Captured Captured Annual Cost Cash Flow Cost Per Tonne" + NL) f.write("Start ("+model.sdacgteconomics.CarbonExtractedAnnually.PreferredUnits.value + ") ("+model.sdacgteconomics.S_DAC_GTCummCarbonExtracted.PreferredUnits.value + diff --git a/src/geophires_x_client/geophires_x_result.py b/src/geophires_x_client/geophires_x_result.py index b01155473..84295da7e 100644 --- a/src/geophires_x_client/geophires_x_result.py +++ b/src/geophires_x_client/geophires_x_result.py @@ -98,7 +98,8 @@ class GeophiresXResult: 'Project MOIC (including carbon credit)', 'Project Payback Period (including carbon credit)', ], - 'S_DAC_GT ECONOMICS': [ + 'S-DAC-GT ECONOMICS': [ + # TODO S-DAC-GT Report sub-titles as string value fields 'LCOD Using grid-based electricity only', 'LCOD Using natural gas only', 'LCOD Using geothermal energy only', @@ -373,7 +374,7 @@ def __init__(self, output_file_path, logger_name=None): sdacgt_profile = self._get_sdacgt_profile() if sdacgt_profile is not None: - self.result['S_DAC_GT PROFILE'] = sdacgt_profile + self.result['S-DAC-GT PROFILE'] = sdacgt_profile self.result['metadata'] = {'output_file_path': self.output_file_path} for metadata_field in GeophiresXResult._METADATA_FIELDS: @@ -606,13 +607,13 @@ def extract_table_header(lines: list) -> list: 'Year Since Start', 'Carbon Captured (tonne/yr)', 'Cumm. Carbon Captured (tonne)', - 'S_DAC_GT Annual Cost (USD/yr)', - 'S_DAC_GT Cumm. Cash Flow (USD)', + 'S-DAC-GT Annual Cost (USD/yr)', + 'S-DAC-GT Cumm. Cash Flow (USD)', 'Cumm. Cost Per Tonne (USD/tonne)', ] try: - lines = self._get_profile_lines('S_DAC_GT PROFILE') + lines = self._get_profile_lines('S-DAC-GT PROFILE') profile = [extract_table_header(lines)] profile.extend(self._extract_addons_style_table_data(lines)) return profile diff --git a/tests/examples/S-DAC-GT.out b/tests/examples/S-DAC-GT.out index 85481e0c6..6a6014696 100644 --- a/tests/examples/S-DAC-GT.out +++ b/tests/examples/S-DAC-GT.out @@ -4,10 +4,10 @@ Simulation Metadata ---------------------- - GEOPHIRES Version: 3.7.13 + GEOPHIRES Version: 3.7.14 Simulation Date: 2025-02-27 - Simulation Time: 09:29 - Calculation Time: 0.099 sec + Simulation Time: 09:55 + Calculation Time: 0.106 sec ***SUMMARY OF RESULTS*** @@ -246,7 +246,7 @@ ________________________________________________________________________________ - ***S_DAC_GT ECONOMICS*** + ***S-DAC-GT ECONOMICS*** S-DAC-GT Report: Levelized Cost of Direct Air Capture (LCOD) @@ -268,9 +268,9 @@ ________________________________________________________________________________ ********************** - * S_DAC_GT PROFILE * + * S-DAC-GT PROFILE * ********************** -Year Carbon Cumm. Carbon S_DAC_GT S_DAC_GT Cumm. Cumm. Cost +Year Carbon Cumm. Carbon S-DAC-GT S-DAC-GT Cumm. Cumm. Cost Since Captured Captured Annual Cost Cash Flow Cost Per Tonne Start (tonne/yr) (tonne) (USD/yr) (USD) (USD/tonne) 1 78,330.80 78,330.80 17,411,627.98 17,411,627.98 222.28 diff --git a/tests/test_geophires_x_client.py b/tests/test_geophires_x_client.py index b8698b54e..473c693d5 100644 --- a/tests/test_geophires_x_client.py +++ b/tests/test_geophires_x_client.py @@ -531,11 +531,11 @@ def test_parse_annualized_capital_costs(self): def test_parse_number_with_commas(self): result = GeophiresXResult(self._get_test_file_path('examples/S-DAC-GT.out')) - self.assertEqual(result.result['S_DAC_GT ECONOMICS']['Total Cost of Capture']['value'], 499_311_405.59) + self.assertEqual(result.result['S-DAC-GT ECONOMICS']['Total Cost of Capture']['value'], 499_311_405.59) def test_parse_sdacgt_profile(self): result = GeophiresXResult(self._get_test_file_path('examples/S-DAC-GT.out')) - sdacgt_profile = result.result['S_DAC_GT PROFILE'] + sdacgt_profile = result.result['S-DAC-GT PROFILE'] self.assertIsNotNone(sdacgt_profile) self.assertEqual( sdacgt_profile[0], @@ -543,8 +543,8 @@ def test_parse_sdacgt_profile(self): 'Year Since Start', 'Carbon Captured (tonne/yr)', 'Cumm. Carbon Captured (tonne)', - 'S_DAC_GT Annual Cost (USD/yr)', - 'S_DAC_GT Cumm. Cash Flow (USD)', + 'S-DAC-GT Annual Cost (USD/yr)', + 'S-DAC-GT Cumm. Cash Flow (USD)', 'Cumm. Cost Per Tonne (USD/tonne)', ], ) From 7348dde02a70c2233e19ba74274d7d9a4fe2ded9 Mon Sep 17 00:00:00 2001 From: softwareengineerprogrammer <4056124+softwareengineerprogrammer@users.noreply.github.com> Date: Thu, 27 Feb 2025 10:02:04 -0800 Subject: [PATCH 09/14] =?UTF-8?q?Bump=20version:=203.7.14=20=E2=86=92=203.?= =?UTF-8?q?7.15?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .bumpversion.cfg | 2 +- .cookiecutterrc | 2 +- README.rst | 4 ++-- docs/conf.py | 2 +- setup.py | 2 +- src/geophires_x/__init__.py | 2 +- 6 files changed, 7 insertions(+), 7 deletions(-) diff --git a/.bumpversion.cfg b/.bumpversion.cfg index 2db82521c..b05747d8b 100644 --- a/.bumpversion.cfg +++ b/.bumpversion.cfg @@ -1,5 +1,5 @@ [bumpversion] -current_version = 3.7.14 +current_version = 3.7.15 commit = True tag = True diff --git a/.cookiecutterrc b/.cookiecutterrc index 5b5956965..f1c32e4a8 100644 --- a/.cookiecutterrc +++ b/.cookiecutterrc @@ -54,7 +54,7 @@ default_context: sphinx_doctest: "no" sphinx_theme: "sphinx-py3doc-enhanced-theme" test_matrix_separate_coverage: "no" - version: 3.7.14 + version: 3.7.15 version_manager: "bump2version" website: "https://github.com/NREL" year_from: "2023" diff --git a/README.rst b/README.rst index 5911ee7aa..b8fb29bb6 100644 --- a/README.rst +++ b/README.rst @@ -56,9 +56,9 @@ Free software: `MIT license `__ :alt: Supported implementations :target: https://pypi.org/project/geophires-x -.. |commits-since| image:: https://img.shields.io/github/commits-since/softwareengineerprogrammer/GEOPHIRES-X/v3.7.14.svg +.. |commits-since| image:: https://img.shields.io/github/commits-since/softwareengineerprogrammer/GEOPHIRES-X/v3.7.15.svg :alt: Commits since latest release - :target: https://github.com/softwareengineerprogrammer/GEOPHIRES-X/compare/v3.7.14...main + :target: https://github.com/softwareengineerprogrammer/GEOPHIRES-X/compare/v3.7.15...main .. |docs| image:: https://readthedocs.org/projects/GEOPHIRES-X/badge/?style=flat :target: https://nrel.github.io/GEOPHIRES-X diff --git a/docs/conf.py b/docs/conf.py index 8ce77be93..8eba35239 100644 --- a/docs/conf.py +++ b/docs/conf.py @@ -18,7 +18,7 @@ year = '2025' author = 'NREL' copyright = f'{year}, {author}' -version = release = '3.7.14' +version = release = '3.7.15' pygments_style = 'trac' templates_path = ['./templates'] diff --git a/setup.py b/setup.py index 7d7f2b280..26dde9f59 100755 --- a/setup.py +++ b/setup.py @@ -13,7 +13,7 @@ def read(*names, **kwargs): setup( name='geophires-x', - version='3.7.14', + version='3.7.15', license='MIT', description='GEOPHIRES is a free and open-source geothermal techno-economic simulator.', long_description='{}\n{}'.format( diff --git a/src/geophires_x/__init__.py b/src/geophires_x/__init__.py index 0e7dcdb34..c182f5260 100644 --- a/src/geophires_x/__init__.py +++ b/src/geophires_x/__init__.py @@ -1 +1 @@ -__version__ = '3.7.14' +__version__ = '3.7.15' From be96aae3f4585ace7af4cb918c491ed6ff9ac1a1 Mon Sep 17 00:00:00 2001 From: softwareengineerprogrammer <4056124+softwareengineerprogrammer@users.noreply.github.com> Date: Thu, 27 Feb 2025 10:07:29 -0800 Subject: [PATCH 10/14] Geothermal LCOH parsing test --- tests/test_geophires_x_client.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/tests/test_geophires_x_client.py b/tests/test_geophires_x_client.py index 473c693d5..101c83c20 100644 --- a/tests/test_geophires_x_client.py +++ b/tests/test_geophires_x_client.py @@ -532,6 +532,8 @@ def test_parse_annualized_capital_costs(self): def test_parse_number_with_commas(self): result = GeophiresXResult(self._get_test_file_path('examples/S-DAC-GT.out')) self.assertEqual(result.result['S-DAC-GT ECONOMICS']['Total Cost of Capture']['value'], 499_311_405.59) + gt_lcoh = result.result['S-DAC-GT ECONOMICS']['Geothermal LCOH']['value'] + self.assertEqual(gt_lcoh, 0.0017) def test_parse_sdacgt_profile(self): result = GeophiresXResult(self._get_test_file_path('examples/S-DAC-GT.out')) From 74d6c65c7ca3c2b2a4682322bf2ca97650155313 Mon Sep 17 00:00:00 2001 From: softwareengineerprogrammer <4056124+softwareengineerprogrammer@users.noreply.github.com> Date: Thu, 27 Feb 2025 10:09:33 -0800 Subject: [PATCH 11/14] use percentage comparison to reduce chances of tedious future test breakage --- tests/test_geophires_x_client.py | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/tests/test_geophires_x_client.py b/tests/test_geophires_x_client.py index 101c83c20..11caf3d33 100644 --- a/tests/test_geophires_x_client.py +++ b/tests/test_geophires_x_client.py @@ -531,9 +531,11 @@ def test_parse_annualized_capital_costs(self): def test_parse_number_with_commas(self): result = GeophiresXResult(self._get_test_file_path('examples/S-DAC-GT.out')) - self.assertEqual(result.result['S-DAC-GT ECONOMICS']['Total Cost of Capture']['value'], 499_311_405.59) - gt_lcoh = result.result['S-DAC-GT ECONOMICS']['Geothermal LCOH']['value'] - self.assertEqual(gt_lcoh, 0.0017) + self.assertAlmostEqualWithinPercentage( + 499_311_405.59, result.result['S-DAC-GT ECONOMICS']['Total Cost of Capture']['value'] + ) + + self.assertAlmostEqualWithinPercentage(result.result['S-DAC-GT ECONOMICS']['Geothermal LCOH']['value'], 0.0017) def test_parse_sdacgt_profile(self): result = GeophiresXResult(self._get_test_file_path('examples/S-DAC-GT.out')) From 87897d3c789d2e7bc3680e06c68aa6af1e8717d9 Mon Sep 17 00:00:00 2001 From: softwareengineerprogrammer <4056124+softwareengineerprogrammer@users.noreply.github.com> Date: Thu, 27 Feb 2025 10:21:20 -0800 Subject: [PATCH 12/14] 'Geothermal Ratio (electricity vs heat)' client parsing test --- tests/test_geophires_x_client.py | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/tests/test_geophires_x_client.py b/tests/test_geophires_x_client.py index 11caf3d33..d3e2cfc23 100644 --- a/tests/test_geophires_x_client.py +++ b/tests/test_geophires_x_client.py @@ -531,11 +531,12 @@ def test_parse_annualized_capital_costs(self): def test_parse_number_with_commas(self): result = GeophiresXResult(self._get_test_file_path('examples/S-DAC-GT.out')) - self.assertAlmostEqualWithinPercentage( - 499_311_405.59, result.result['S-DAC-GT ECONOMICS']['Total Cost of Capture']['value'] - ) + sdac_e = result.result['S-DAC-GT ECONOMICS'] + self.assertAlmostEqualWithinPercentage(499_311_405.59, sdac_e['Total Cost of Capture']['value']) + + self.assertAlmostEqualWithinPercentage(0.0017, sdac_e['Geothermal LCOH']['value']) - self.assertAlmostEqualWithinPercentage(result.result['S-DAC-GT ECONOMICS']['Geothermal LCOH']['value'], 0.0017) + self.assertAlmostEqualWithinPercentage(20.7259, sdac_e['Geothermal Ratio (electricity vs heat)']['value']) def test_parse_sdacgt_profile(self): result = GeophiresXResult(self._get_test_file_path('examples/S-DAC-GT.out')) From d2b91d2fe60430323b304b228b2a2e40ad6b2820 Mon Sep 17 00:00:00 2001 From: softwareengineerprogrammer <4056124+softwareengineerprogrammer@users.noreply.github.com> Date: Thu, 27 Feb 2025 10:42:47 -0800 Subject: [PATCH 13/14] Lowercase 'using' S-DAC fields --- src/geophires_x/OutputsS_DAC_GT.py | 12 ++++++------ src/geophires_x_client/geophires_x_result.py | 12 ++++++------ tests/examples/S-DAC-GT.out | 18 +++++++++--------- 3 files changed, 21 insertions(+), 21 deletions(-) diff --git a/src/geophires_x/OutputsS_DAC_GT.py b/src/geophires_x/OutputsS_DAC_GT.py index 4f74840b5..cf29b9a8d 100644 --- a/src/geophires_x/OutputsS_DAC_GT.py +++ b/src/geophires_x/OutputsS_DAC_GT.py @@ -36,21 +36,21 @@ def PrintOutputs(self, model) -> tuple: f.write(f" S-DAC-GT Report: Levelized Cost of Direct Air Capture (LCOD)\n") sdac_results.append(OutputTableItem('S-DAC-GT Report: Levelized Cost of Direct Air Capture (LCOD)')) lcod_prefix = 'LCOD' - f.write(f" {lcod_prefix} Using grid-based electricity only: {model.sdacgteconomics.LCOD_elec.value:10.2f} {msdac.LCOD_elec.PreferredUnits.value}\n") + f.write(f" {lcod_prefix} using grid-based electricity only: {model.sdacgteconomics.LCOD_elec.value:10.2f} {msdac.LCOD_elec.PreferredUnits.value}\n") sdac_results.append(OutputTableItem(f'Using grid-based electricity only', '{0:10.2f}'.format(msdac.LCOD_elec.value), msdac.LCOD_elec.PreferredUnits.value)) - f.write(f" {lcod_prefix} Using natural gas only: {model.sdacgteconomics.LCOD_ng.value:10.2f} {msdac.LCOD_ng.PreferredUnits.value}\n") + f.write(f" {lcod_prefix} using natural gas only: {model.sdacgteconomics.LCOD_ng.value:10.2f} {msdac.LCOD_ng.PreferredUnits.value}\n") sdac_results.append(OutputTableItem('Using natural gas only', '{0:10.2f}'.format(model.sdacgteconomics.LCOD_ng.value), msdac.LCOD_ng.PreferredUnits.value)) - f.write(f" {lcod_prefix} Using geothermal energy only: {model.sdacgteconomics.LCOD_geo.value:10.2f} {msdac.LCOD_geo.PreferredUnits.value}\n\n") + f.write(f" {lcod_prefix} using geothermal energy only: {model.sdacgteconomics.LCOD_geo.value:10.2f} {msdac.LCOD_geo.PreferredUnits.value}\n\n") sdac_results.append(OutputTableItem(f'Using geothermal energy only', '{0:10.2f}'.format(msdac.LCOD_geo.value), msdac.LCOD_geo.PreferredUnits.value)) f.write(f" S-DAC-GT Report: CO2 Intensity of process (percent of CO2 mitigated that is emitted by S-DAC process)\n") sdac_results.append(OutputTableItem('S-DAC-GT Report: CO2 Intensity of process (percent of CO2 mitigated that is emitted by S-DAC process)')) co2i_prefix = 'CO2 Intensity' - f.write(f" {co2i_prefix} Using grid-based electricity only: {msdac.CO2total_elec.value*100.0:10.2f} %\n") # TODO CurrentUnits + f.write(f" {co2i_prefix} using grid-based electricity only: {msdac.CO2total_elec.value*100.0:10.2f} %\n") # TODO CurrentUnits sdac_results.append(OutputTableItem('Using grid-based electricity only', '{0:10.2f}'.format(msdac.CO2total_elec.value*100.0), '%')) - f.write(f" {co2i_prefix} Using natural gas only: {msdac.CO2total_ng.value*100:10.2f} %\n") # TODO CurrentUnits + f.write(f" {co2i_prefix} using natural gas only: {msdac.CO2total_ng.value*100:10.2f} %\n") # TODO CurrentUnits sdac_results.append(OutputTableItem('Using natural gas only', '{0:10.2f}'.format(msdac.CO2total_ng.value*100.0), '%')) - f.write(f" {co2i_prefix} Using geothermal energy only: {msdac.CO2total_geo.value*100:10.2f} %\n\n") # TODO CurrentUnits + f.write(f" {co2i_prefix} using geothermal energy only: {msdac.CO2total_geo.value*100:10.2f} %\n\n") # TODO CurrentUnits sdac_results.append(OutputTableItem('Using geothermal energy only', '{0:10.2f}'.format(msdac.CO2total_geo.value*100.0), '%')) f.write(f" Geothermal LCOH: {msdac.LCOH.value:10.4f} {msdac.LCOH.PreferredUnits.value}\n") sdac_results.append(OutputTableItem('Geothermal LCOH', '{0:10.4f}'.format(msdac.LCOH.value), msdac.LCOH.PreferredUnits.value)) diff --git a/src/geophires_x_client/geophires_x_result.py b/src/geophires_x_client/geophires_x_result.py index 84295da7e..cbaec5c4c 100644 --- a/src/geophires_x_client/geophires_x_result.py +++ b/src/geophires_x_client/geophires_x_result.py @@ -100,12 +100,12 @@ class GeophiresXResult: ], 'S-DAC-GT ECONOMICS': [ # TODO S-DAC-GT Report sub-titles as string value fields - 'LCOD Using grid-based electricity only', - 'LCOD Using natural gas only', - 'LCOD Using geothermal energy only', - 'CO2 Intensity Using grid-based electricity only', - 'CO2 Intensity Using natural gas only', - 'CO2 Intensity Using geothermal energy only', + 'LCOD using grid-based electricity only', + 'LCOD using natural gas only', + 'LCOD using geothermal energy only', + 'CO2 Intensity using grid-based electricity only', + 'CO2 Intensity using natural gas only', + 'CO2 Intensity using geothermal energy only', 'Geothermal LCOH', 'Geothermal Ratio (electricity vs heat)', 'Percent Energy Devoted To Process', diff --git a/tests/examples/S-DAC-GT.out b/tests/examples/S-DAC-GT.out index 6a6014696..7161cd7d3 100644 --- a/tests/examples/S-DAC-GT.out +++ b/tests/examples/S-DAC-GT.out @@ -4,10 +4,10 @@ Simulation Metadata ---------------------- - GEOPHIRES Version: 3.7.14 + GEOPHIRES Version: 3.7.15 Simulation Date: 2025-02-27 - Simulation Time: 09:55 - Calculation Time: 0.106 sec + Simulation Time: 10:36 + Calculation Time: 0.100 sec ***SUMMARY OF RESULTS*** @@ -250,14 +250,14 @@ ________________________________________________________________________________ S-DAC-GT Report: Levelized Cost of Direct Air Capture (LCOD) - LCOD Using grid-based electricity only: 387.69 USD/tonne - LCOD Using natural gas only: 312.00 USD/tonne - LCOD Using geothermal energy only: 288.87 USD/tonne + LCOD using grid-based electricity only: 387.69 USD/tonne + LCOD using natural gas only: 312.00 USD/tonne + LCOD using geothermal energy only: 288.87 USD/tonne S-DAC-GT Report: CO2 Intensity of process (percent of CO2 mitigated that is emitted by S-DAC process) - CO2 Intensity Using grid-based electricity only: 94.52 % - CO2 Intensity Using natural gas only: 64.85 % - CO2 Intensity Using geothermal energy only: 36.91 % + CO2 Intensity using grid-based electricity only: 94.52 % + CO2 Intensity using natural gas only: 64.85 % + CO2 Intensity using geothermal energy only: 36.91 % Geothermal LCOH: 0.0017 USD/kWh Geothermal Ratio (electricity vs heat): 20.7259 % From 2eed94ddde32803f8a72f87e9c06b52e95b92fdd Mon Sep 17 00:00:00 2001 From: softwareengineerprogrammer <4056124+softwareengineerprogrammer@users.noreply.github.com> Date: Thu, 27 Feb 2025 10:42:58 -0800 Subject: [PATCH 14/14] =?UTF-8?q?Bump=20version:=203.7.15=20=E2=86=92=203.?= =?UTF-8?q?7.16?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .bumpversion.cfg | 2 +- .cookiecutterrc | 2 +- README.rst | 4 ++-- docs/conf.py | 2 +- setup.py | 2 +- src/geophires_x/__init__.py | 2 +- 6 files changed, 7 insertions(+), 7 deletions(-) diff --git a/.bumpversion.cfg b/.bumpversion.cfg index b05747d8b..e2d7d4445 100644 --- a/.bumpversion.cfg +++ b/.bumpversion.cfg @@ -1,5 +1,5 @@ [bumpversion] -current_version = 3.7.15 +current_version = 3.7.16 commit = True tag = True diff --git a/.cookiecutterrc b/.cookiecutterrc index f1c32e4a8..ba4716559 100644 --- a/.cookiecutterrc +++ b/.cookiecutterrc @@ -54,7 +54,7 @@ default_context: sphinx_doctest: "no" sphinx_theme: "sphinx-py3doc-enhanced-theme" test_matrix_separate_coverage: "no" - version: 3.7.15 + version: 3.7.16 version_manager: "bump2version" website: "https://github.com/NREL" year_from: "2023" diff --git a/README.rst b/README.rst index b8fb29bb6..8ecffc5d8 100644 --- a/README.rst +++ b/README.rst @@ -56,9 +56,9 @@ Free software: `MIT license `__ :alt: Supported implementations :target: https://pypi.org/project/geophires-x -.. |commits-since| image:: https://img.shields.io/github/commits-since/softwareengineerprogrammer/GEOPHIRES-X/v3.7.15.svg +.. |commits-since| image:: https://img.shields.io/github/commits-since/softwareengineerprogrammer/GEOPHIRES-X/v3.7.16.svg :alt: Commits since latest release - :target: https://github.com/softwareengineerprogrammer/GEOPHIRES-X/compare/v3.7.15...main + :target: https://github.com/softwareengineerprogrammer/GEOPHIRES-X/compare/v3.7.16...main .. |docs| image:: https://readthedocs.org/projects/GEOPHIRES-X/badge/?style=flat :target: https://nrel.github.io/GEOPHIRES-X diff --git a/docs/conf.py b/docs/conf.py index 8eba35239..c6aa0309c 100644 --- a/docs/conf.py +++ b/docs/conf.py @@ -18,7 +18,7 @@ year = '2025' author = 'NREL' copyright = f'{year}, {author}' -version = release = '3.7.15' +version = release = '3.7.16' pygments_style = 'trac' templates_path = ['./templates'] diff --git a/setup.py b/setup.py index 26dde9f59..f47a74903 100755 --- a/setup.py +++ b/setup.py @@ -13,7 +13,7 @@ def read(*names, **kwargs): setup( name='geophires-x', - version='3.7.15', + version='3.7.16', license='MIT', description='GEOPHIRES is a free and open-source geothermal techno-economic simulator.', long_description='{}\n{}'.format( diff --git a/src/geophires_x/__init__.py b/src/geophires_x/__init__.py index c182f5260..687f883de 100644 --- a/src/geophires_x/__init__.py +++ b/src/geophires_x/__init__.py @@ -1 +1 @@ -__version__ = '3.7.15' +__version__ = '3.7.16'