Skip to content

PVSystem.temperature_model_parameters requirement #1030

@wholmgren

Description

@wholmgren

The temperature_model_parameters handling code below suggests to me that in 0.8 we're going to

  1. set default values module_type=None and racking_model=None.
  2. require user to specify either temperature_model_parameters or both module_type and racking_model.

# TODO: deprecated behavior if PVSystem.temperature_model_parameters
# are not specified. Remove in v0.8
if not any(self.temperature_model_parameters):
warnings.warn(
'Required temperature_model_parameters is not specified '
'and parameters are not inferred from racking_model and '
'module_type. Reverting to deprecated default: SAPM cell '
'temperature model parameters for a glass/glass module in '
'open racking. In the future '
'PVSystem.temperature_model_parameters will be required',
pvlibDeprecationWarning)
params = temperature._temperature_model_params(
'sapm', 'open_rack_glass_glass')
self.temperature_model_parameters = params

@cwhanse is that correct?

The problem is that the only way to see this warning is to supply an invalid module_type or racking_model. That's because PVSystem._infer_temperature_model is called before the code above, and it looks up the default module_type and racking_model and successfully finds temperature coefficients.

if temperature_model_parameters is None:
self.temperature_model_parameters = \
self._infer_temperature_model_params()

So I'm guessing that this warning has been seen by only a small fraction of people that need to see it. I'm ok moving forward with the removal in 0.8 or pushing to 0.9.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions