File tree Expand file tree Collapse file tree 4 files changed +14
-15
lines changed
geophires_x_schema_generator Expand file tree Collapse file tree 4 files changed +14
-15
lines changed Original file line number Diff line number Diff line change @@ -1582,6 +1582,7 @@ def __init__(self, model: Model):
1582
1582
1583
1583
self .LCOE = self .OutputParameterDict [self .LCOE .Name ] = OutputParameter (
1584
1584
Name = "LCOE" ,
1585
+ display_name = 'Electricity breakeven price' ,
1585
1586
UnitType = Units .ENERGYCOST ,
1586
1587
PreferredUnits = EnergyCostUnit .CENTSSPERKWH ,
1587
1588
CurrentUnits = EnergyCostUnit .CENTSSPERKWH
Original file line number Diff line number Diff line change @@ -202,7 +202,7 @@ def PrintOutputs(self, model: Model):
202
202
f .write (f' Average Cooling Production: { np .average (model .surfaceplant .cooling_produced .value ):10.2f} ' + model .surfaceplant .cooling_produced .CurrentUnits .value + NL )
203
203
204
204
if model .surfaceplant .enduse_option .value in [EndUseOptions .ELECTRICITY ]:
205
- f .write (f' Electricity breakeven price : { model .economics .LCOE .value :10.2f} ' + model .economics .LCOE .CurrentUnits .value + NL )
205
+ f .write (f' { model . economics . LCOE . display_name } : { model .economics .LCOE .value :10.2f} { model .economics .LCOE .CurrentUnits .value } \n ' )
206
206
elif model .surfaceplant .enduse_option .value in [EndUseOptions .HEAT ] and \
207
207
model .surfaceplant .plant_type .value not in [PlantType .ABSORPTION_CHILLER ]:
208
208
f .write (f' Direct-Use heat breakeven price (LCOH): { model .economics .LCOH .value :10.2f} ' + model .economics .LCOH .CurrentUnits .value + NL )
@@ -214,7 +214,7 @@ def PrintOutputs(self, model: Model):
214
214
EndUseOptions .COGENERATION_TOPPING_EXTRA_ELECTRICITY ,
215
215
EndUseOptions .COGENERATION_BOTTOMING_EXTRA_ELECTRICITY ,
216
216
EndUseOptions .COGENERATION_PARALLEL_EXTRA_ELECTRICITY ]:
217
- f .write (f' Electricity breakeven price : { model .economics .LCOE .value :10.2f} ' + model .economics .LCOE .CurrentUnits .value + NL )
217
+ f .write (f' { model . economics . LCOE . display_name } : { model .economics .LCOE .value :10.2f} { model .economics .LCOE .CurrentUnits .value } \n ' )
218
218
f .write (f' Direct-Use heat breakeven price (LCOH): { model .economics .LCOH .value :10.2f} ' + model .economics .LCOH .CurrentUnits .value + NL )
219
219
220
220
f .write (f' Number of production wells: { model .wellbores .nprod .value :10.0f} ' + NL )
Original file line number Diff line number Diff line change @@ -168,28 +168,22 @@ def get_result_json_schema(self, output_params_json) -> dict:
168
168
if param_name in properties :
169
169
_log .warning (f'Param { param_name } is already in properties: { properties [param_name ]} ' )
170
170
171
- param = (
172
- {
173
- # 'categories': [],
174
- }
175
- if param_name not in properties
176
- else properties [param_name ]
177
- )
178
-
179
- # param['categories'].append(category)
171
+ param = {} if param_name not in properties else properties [param_name ]
180
172
181
173
if param_name in output_params :
182
174
output_param = output_params [param_name ]
183
175
param ['type' ] = output_param ['json_parameter_type' ]
184
176
description = output_param ['ToolTipText' ]
185
177
if 'output_parameter_name' in output_param :
186
- description = f'{ output_param ["output_parameter_name" ]} . { description } '
178
+ if description is not None and description != '' :
179
+ description = f'{ output_param ["output_parameter_name" ]} . { description } '
180
+ else :
181
+ description = output_param ['output_parameter_name' ]
187
182
param ['description' ] = description
188
183
param ['units' ] = (
189
184
output_param ['CurrentUnits' ] if isinstance (output_param ['CurrentUnits' ], str ) else None
190
185
)
191
186
192
- # properties[param_name] = param.copy()
193
187
cat_properties [param_name ] = param .copy ()
194
188
195
189
properties [category ] = {'type' : 'object' , 'properties' : cat_properties }
Original file line number Diff line number Diff line change 12
12
"End-Use" : {},
13
13
"Surface Application" : {},
14
14
"Average Net Electricity Production" : {},
15
- "Electricity breakeven price" : {},
15
+ "Electricity breakeven price" : {
16
+ "type" : " number" ,
17
+ "description" : " LCOE" ,
18
+ "units" : " cents/kWh"
19
+ },
16
20
"Average Direct-Use Heat Production" : {},
17
21
"Direct-Use heat breakeven price" : {},
18
22
"Direct-Use heat breakeven price (LCOH)" : {},
37
41
"Segment 4 Geothermal gradient" : {},
38
42
"LCOE" : {
39
43
"type" : " number" ,
40
- "description" : " " ,
44
+ "description" : " LCOE " ,
41
45
"units" : " cents/kWh"
42
46
},
43
47
"LCOH" : {
You can’t perform that action at this time.
0 commit comments