Skip to content

Latest commit

 

History

History
243 lines (228 loc) · 12.6 KB

File metadata and controls

243 lines (228 loc) · 12.6 KB

.. _whatsnew_0700:

v0.7.0 (December 18, 2019)

This is a major release that drops support for Python 2 and Python 3.4. We recommend all users of v0.6.3 upgrade to this release after checking API compatibility notes.

Python 2.7 support ended on June 1, 2019. (:issue:`501`) Minimum numpy version is now 1.12.0. Minimum pandas version is now 0.18.1. (:issue:`830`, :issue:`748`)

API Breaking Changes

  • The effective_irradiance argument for :py:func:`pvsystem.sapm` now requires units of W/m^2. Previously, units for this input were suns. A RuntimeWarning warning is raised if all effective_irradiance < 2.0.
  • The output of :py:func:`pvsystem.sapm_effective_irradiance` is now in units of W/m2 rather than suns.
  • Calling :py:func:`pvlib.pvsystem.retrieve_sam` with no parameters will raise an exception instead of displaying a dialog.
  • The modelchain.ModelChain.diode_params attribute is now formatted in a pandas.DataFrame with DatetimeIndex, rather than in a tuple.
  • PVSystem.pvwatts_ac now uses inverter DC input limit PVSystem.inverter_parameters['pdc0'] instead of module nameplate capacity PVSystem.module_parameters['pdc0']. (:issue:`734`)
  • ModelChain.infer_ac_model now uses the presence of the key 'pdc0' PVSystem.inverter_parameters to determine if the pvwatts_ac inverter model should be used. The inference method previously looked for the key in PVSystem.module_parameters. (:issue:`734`)

API Changes with Deprecations

  • Changes related to cell temperature models (:issue:`678`):
    • Changes to functions
      • Moved functions for cell temperature from pvsystem.py to temperature.py.
      • Renamed pvsystem.sapm_celltemp and pvsystem.pvsyst_celltemp to temperature.sapm_cell and temperature.pvsyst_cell.
      • temperature.sapm_cell returns only the cell temperature, whereas the old pvsystem.sapm_celltemp returned a DataFrame with both cell and module temperatures.
      • Created temperature.sapm_module to return module temperature using the SAPM temperature model.
      • Changed the order of arguments for pvsystem.sapm_celltemp, pvsystem.pvsyst_celltemp and PVSystem.sapm_celltemp to be consistent among cell temperature model functions.
      • Removed model as a kwarg from temperature.sapm_cell and temperature.pvsyst_cell. These functions now require model-specific parameters.
      • Added the argument irrad_ref, default value 1000, to temperature.sapm_cell.
    • Changes to named temperature model parameter sets
      • Renamed pvsystem.TEMP_MODEL_PARAMS to temperature.TEMPERATURE_MODEL_PARAMETERS.
      • temperature.TEMPERATURE_MODEL_PARAMETERS uses dict rather than tuple for a parameter set.
      • Names for parameter sets in temperature.TEMPERATURE_MODEL_PARAMETERS have changed.
      • Parameter sets for the SAPM cell temperature model named 'open_rack_polymer_thinfilm_steel' and '22x_concentrator_tracker' are considered obsolete and have been removed.
    • Changes to PVSystem class
      • Changed the model kwarg in PVSystem.sapm_celltemp and PVSystem.pvsyst_celltemp to parameter_set. parameter_set expects a str which is a valid key for temperature.TEMPERATURE_MODEL_PARAMETERS for the corresponding temperature model.
      • Added an attribute PVSystem.module_type (str) to record module front and back materials, default is glass_polymer.
      • Changed meaning of PVSystem.racking_model to describe racking only, e.g., default is open_rack.
      • Added an attribute PVSystem.temperature_model_parameters (dict). to contain temperature model parameters.
      • If PVSystem.temperature_model_parameters is not specified and PVSystem.racking_model and PVSystem.module_type combine to a valid parameter set name for the SAPM cell temperature model, that parameter set is assigned to PVSystem.temperature_model_parameters. Otherwise PVSystem.temperature_model_parameters is assigned an empty dict. The result is that the default parameter set for SAPM cell temperature model is open_rack_glass_polymer; the old default was open_rack_glass_glass.
    • Changes to ModelChain class
      • ModelChain.temp_model renamed to ModelChain.temperature_model.
      • ModelChain.temperature_model now defaults to None. The temperature model can be inferred from PVSystem.temperature_model_parameters.
      • ModelChain.temperature_model_parameters now defaults to None. The temperature model can be inferred from PVSystem.temperature_model_parameters.
      • ModelChain.temps attribute renamed to ModelChain.cell_temperature, and its datatype is now numeric rather than DataFrame.
      • If PVSystem.temperature_model_parameters is not specified, ModelChain defaults to old behavior, using the SAPM temperature model with parameter set open_rack_glass_glass. This behavior is deprecated, and will be removed in v0.8. In v0.8 PVSystem.temperature_model_parameters will be required for ModelChain.
      • Implemented pvsyst as an option for ModelChain.temperature_model.
      • modelchain.basic_chain has a new required argument temperature_model_parameters.
  • Changes related to IAM (AOI loss) functions (:issue:`680`):
    • Changes to functions
      • Moved functions from pvsystem.py to iam.py. pvsystem IAM functions are deprecated and will be removed in v0.8.
      • Functions are renamed to a consistent pattern:
        • pvsystem.physicaliam is iam.physical
        • pvsystem.ashraeiam is iam.ashrae
        • pvsystem.sapm_aoi_loss is iam.sapm
    • Changes to PVSystem class
      • IAM models are provided by PVSystem.get_iam with kwarg iam_model.
      • Methods PVSystem.ashraeiam, PVSystem.physicaliam and PVSystem.sapm_aoi_loss are deprecated and will be removed in v0.8.
  • Changes related to spectral modifier (:issue:`782`):
  • The times keyword argument has been deprecated in the :py:meth:`pvlib.modelchain.ModelChain.run_model`, :py:meth:`pvlib.modelchain.ModelChain.prepare_inputs`, and :py:meth:`pvlib.modelchain.ModelChain.complete_irradiance` methods. Model times are now determined by the input weather. DataFrame. Therefore, the weather DataFrame must have a DatetimeIndex. The weather argument of the above methods is now the first, required positional argument and the times argument is kept as the second keyword argument for capability during the deprecation period.
  • Parameter pvsystem.DC_MODEL_PARAMS is renamed to pvsystem._DC_MODEL_PARAMS. Users should not rely on this dictionary's existence or structure.

Other API Changes

Enhancements

Bug fixes

  • Fix handling of keyword arguments in forecasts.get_processed_data. (:issue:`745`)
  • Fix output as Series feature in :py:func:`pvlib.pvsystem.ashraeiam`.
  • Fix rounding issue in clearsky._linearly_scale, a function that converts longitude or latitude degree to an index number in a Linke turbidity lookup table. Also rename the function to clearsky._degrees_to_index. (:issue:`754`)
  • Fix reading raw MIDC CSV files from NREL where the number of header columns does not match the number of data columns.
  • Fix installation issue due to missing requests dependency. (:issue:`725`)
  • PVSystem.pvwatts_ac now uses inverter DC input limit PVSystem.inverter_parameters['pdc0'] instead of module nameplate capacity PVSystem.module_parameters['pdc0']. (:issue:`734`)

Testing

  • Added 30 minutes to timestamps in test_psm3.csv to match change in NSRDB (:issue:`733`)
  • Added tests for methods in bifacial.py.
  • Added tests for changes to cell temperature models.
  • Add tests configuration for bare python environment (no conda). (:issue:`727`)
  • Added tests for changes to IAM models.
  • Added test for ModelChain.infer_aoi_model.

Documentation

  • Corrected docstring for pvsystem.PVSystem.sapm
  • Fixed broken ipython examples from CEC data updates
  • Edited docstring for pvsystem.sapm to remove DataFrame option for input module. The DataFrame option was never tested and would cause an error if used. (:issue:`785`)
  • Note warning about _TMY3.epw files retrieved from energyplus.net in docstring of epw.read_epw
  • Improved sphinx rendering of API reference entries for clearsky.ineichen, clearsky.haurwitz, tracking.singleaxis, iotools.read_midc, Location.from_tmy, ModelChain.run_model, ModelChain.complete_irradiance, and ModelChain.prepare_inputs
  • Removed duplicate pvwatts_losses entry in api.rst

Removal of prior version deprecations

  • Removed irradiance.extraradiation.
  • Removed irradiance.grounddiffuse.
  • Removed irradiance.total_irrad.
  • Removed irradiance.globalinplane.
  • Removed atmosphere.relativeairmass.
  • Removed atmosphere.relativeairmass.
  • Removed solarposition.get_sun_rise_set_transit.
  • Removed tmy module.
  • Removed ModelChain.singlediode method.
  • Removed ModelChain.prepare_inputs clearsky assumption when no irradiance data was provided.

Requirements

  • numpy minimum increased to v1.12.0, released in 2017. (:issue:`830`)
  • pandas minimum increased to v1.18.1, released in 2016. (:issue:`748`)

Contributors