Optimization of Surface Position¶
Following we show a few examples on how to use the optimizer for the surface position in PVGIS.
Optimization of Surface Position
- Optimisation of Tilt, Orientation or both
- Supported by optimizers implemented in SciPy
Multiple examples
- Examples for a single day, single and multi-year timestamps
Programmatic preamble¶
from pvgisprototype import (
TemperatureSeries,
WindSpeedSeries,
SpectralFactorSeries,
LinkeTurbidityFactor,
Longitude,
Latitude,
Elevation,
SurfaceOrientation,
SurfaceTilt,
)
from pvgisprototype.algorithms.huld.photovoltaic_module import PhotovoltaicModuleModel
from pvgisprototype.api.datetime.datetimeindex import generate_datetime_series
from zoneinfo import ZoneInfo
from pvgisprototype.api.surface.graph_power_output import graph_power_output
from pvgisprototype.api.surface.positioning import optimise_surface_position
from pvgisprototype.api.surface.parameter_models import (
SurfacePositionOptimizerMethod,
SurfacePositionOptimizerMode,
)
import math
from pvgisprototype.constants import DEGREES
Data preparation¶
First, we define some basic parameters for a location, in which case it is a solar panel located behind the ESTI Lab, in the JRC, European Commission.
latitude = Latitude(value=45.812, unit=DEGREES)
longitude = Longitude(value=8.628, unit=DEGREES)
elevation = 214
timezone = ZoneInfo("UTC")
Optimization of Position¶
Optimal Tilt for a Single Day¶
For this first example, we will optimize the tilt of the panel on the 1st January 2010. We define the dates, the optimization mode as "Tilt", and the surface orientation of our panel
start_time = '2010-01-01'
end_time = '2010-01-02'
timestamps = generate_datetime_series(start_time=start_time, end_time=end_time, frequency="h")
mode = SurfacePositionOptimizerMode.Tilt
surface_orientation = math.radians(180)
from numpy import full
photovoltaic_module = PhotovoltaicModuleModel.CIS_FREE_STANDING
spectral_factor_series = SpectralFactorSeries(value=full(len(timestamps), 1, dtype='float32'))
temperature_series = TemperatureSeries(value=full(len(timestamps), 12, dtype='float32'))
wind_speed_series = WindSpeedSeries(value=full(len(timestamps), 2, dtype='float32'))
linke_turbidity_factor_series = LinkeTurbidityFactor(value=full(len(timestamps), 1, dtype='float32'))
Now, we call the optimise_surface_position() function to calculate which is the optimal tilt for this case
result = optimise_surface_position(
longitude=longitude.radians,
latitude=latitude.radians,
elevation=elevation,
timestamps=timestamps,
timezone=timezone,
spectral_factor_series=spectral_factor_series,
photovoltaic_module=photovoltaic_module,
temperature_series=temperature_series,
wind_speed_series=wind_speed_series,
linke_turbidity_factor_series=linke_turbidity_factor_series,
mode=mode,
surface_orientation=surface_orientation
)
from rich import print
print(result)
( { 'Surface Orientation': SurfaceOrientation( optimal=False, optimiser=None, optimization_mode=None, success=None, min_degrees=0, min_radians=0, data_source=None, equation=None, algorithm=None, unit='radians', value=3.141592653589793, symbol='⯐ ⎄', description=None, label='Surface Position', title='Surface Position', supertitle='Surface Position data', shortname='Surface Position', name='Surface Position', max_radians=6.283185307179586, max_degrees=360 ), 'Surface Tilt': SurfaceTilt( optimal=True, optimiser=None, optimization_mode=None, success=None, min_degrees=0, min_radians=0, data_source=None, equation=None, algorithm=None, unit='radians', value=1.3035176011540837, symbol='⯐ ⎄', description=None, label='Surface Position', title='Surface Position', supertitle='Surface Position data', shortname='Surface Position', name='Surface Position', max_radians=3.141592653589793, max_degrees=180 ), 'Mean PV Power': np.float32(232.95676), 'Unit': 'radians', 'Timing': 'Milne1921' }, OptimalSurfacePosition( angle_output_units='radians', adjusted_for_atmospheric_refraction=None, horizon_height=None, visible=array([], dtype=float64), surface_in_shade=None, shading_state=array([], dtype=float64), shading_states='all', shading_algorithm='PVGIS', sun_horizon_positions='all', sun_horizon_position=array([], dtype=float64), elevation=0, location=None, solar_timing_algorithm='Milne1921', optimal=False, photovoltaic_power=PhotovoltaicPower( diffuse_horizontal_irradiance=DiffuseSkyReflectedHorizontalIrradiance( angle_output_units=None, linke_turbidity_factor=LinkeTurbidityFactor( name=None, title='Linke Turbidity', description='The Linke Turbidity Factor describes the attenuation of the extraterrestrial solar radiation by solid and liquid particles under cloudless sky conditions. It indicates the optical density of hazy and humid atmosphere in relation to a clean and dry atmosphere. In other words TLK is the number of clean dry air masses that would result in the same extinction then real hazy and humid air. Due to a dynamic nature of the turbidity factor, its calculation and subsequent averaging leads to a certain degree of generalisation. There are clear seasonal changes of the turbidity (lowest values in winter, highest in summer), the values of turbidity factor always differ from place to place in a similar degree of magnitude and these differences are also correlated with the terrain elevation. It increases with an intensity of industrialisation and urbanisation. The values of Linke turbidity for different landscapes or world regions can be found in literature [e.g. 16, 19, 30] or in http://www.soda-is.com/ [20]).', symbol='⋅', value=array([1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1.], dtype=float32), unit='unitless', minimum=0, maximum=8 ), adjusted_for_atmospheric_refraction=None, adjust_for_atmospheric_refraction=True, solar_incidence_definition=None, solar_incidence_model=None, solar_incidence=None, azimuth_difference=array([], dtype=float64), solar_azimuth=None, solar_timing_algorithm=None, solar_positioning_algorithm='NOAA', location=None, extraterrestrial_normal_irradiance=ExtraterrestrialNormalIrradiance( fingerprint=False, quality='Not validated!', solar_radiation_model='Hofierka 2002', refracted_solar_altitude=array([], dtype=float64), solar_altitude=None, eccentricity_amplitude=0.03344, eccentricity_phase_offset=0.048869, out_of_range_index=array([-1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1]), out_of_range=array([False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False]), upper_physically_possible_limit=2000, lower_physically_possible_limit=-4, solar_constant=1360.8, data_source=None, equation='Extraterrestrial Normal Irradiance = Solar Constant * Eccentricity Correction Factor', algorithm='The beam irradiance (solar energy) outside the atmosphere and at mean solar distance, is roughly constant at is 1367 W.m-2. However, the orbit of the earth around the sun is lightly eccentric hence its distance to the sun varies slightly across the year. In order to take into account the varying solar distance, the calculation of the extraterrestrial irradiance normal to the solar beam, considers an "eccentricity correction factor" ε.', unit='W/m²', value=array([1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.3005], dtype=float32), symbol='⍖ ⦜', description='Extraterrestrial irradiance', label='⍖ ⦜ Extraterrestrial Normal Irradiance', title='Extraterrestrial Normal Irradiance', supertitle='Simulated Extraterrestrial Normal Irradiance Series', shortname='Extra', name='Extraterrestrial Normal Irradiance', day_of_year=array([1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 2.], dtype=float32), day_angle=array([0.01721421, 0.01721421, 0.01721421, 0.01721421, 0.01721421, 0.01721421, 0.01721421, 0.01721421, 0.01721421, 0.01721421, 0.01721421, 0.01721421, 0.01721421, 0.01721421, 0.01721421, 0.01721421, 0.01721421, 0.01721421, 0.01721421, 0.01721421, 0.01721421, 0.01721421, 0.01721421, 0.01721421, 0.03442841], dtype=float32), distance_correction_factor=array([1.0334233, 1.0334233, 1.0334233, 1.0334233, 1.0334233, 1.0334233, 1.0334233, 1.0334233, 1.0334233, 1.0334233, 1.0334233, 1.0334233, 1.0334233, 1.0334233, 1.0334233, 1.0334233, 1.0334233, 1.0334233, 1.0334233, 1.0334233, 1.0334233, 1.0334233, 1.0334233, 1.0334233, 1.0334365], dtype=float32), output=OrderedDict([('Fingerprint', {}), ('References', {}), ('Sources', {}), ('Out-of-range', {}), ('Metadata', {}), ('Context', {}), ('Core', {}), ('Extraterrestrial Normal Irradiance', OrderedDict([('Unit', 'W/m²'), ('Extra ⍖ ⦜', array([1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.3005], dtype=float32)), ('Symbol', '⍖ ⦜'), ('Description', 'Extraterrestrial irradiance'), ('Title', 'Extraterrestrial Normal Irradiance'), ('Name', 'Extraterrestrial Normal Irradiance')])), ('Solar Radiation Model', {})]) ), direct_horizontal_irradiance=None, global_horizontal_irradiance=array([], dtype=float64), fingerprint=False, quality=None, solar_radiation_model='Hofierka 2002', refracted_solar_altitude=array([], dtype=float64), solar_altitude=SolarAltitude( out_of_range_index=array([-1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1]), out_of_range=array([False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False]), adjusted_for_atmospheric_refraction=True, solar_timing_algorithm='NOAA', solar_positioning_algorithm='NOAA', data_source=None, equation=None, algorithm=None, unit='radians', value=array([ nan, nan, nan, nan, nan, nan, nan, nan, 0.1156317 , 0.23393297, 0.3195778 , 0.36424756, 0.36299396, 0.316038 , 0.22849977, 0.10883486, nan, nan, nan, nan, nan, nan, nan, nan, nan], dtype=float32), symbol='⦩', description='Solar altitude data for a location and period in time', label=None, title='Solar Altitude', supertitle='Solar Irradiance', shortname='Altitude', name='Solar Altitude', refracted_value=array([], dtype=float64), min_radians=-1.5707963267948966, max_radians=1.5707963267948966, low_angle_threshold_radians=0.04, min_degrees=-90, max_degrees=90, low_angle_threshold_degrees=2.291831180523293, output={} ), eccentricity_amplitude=0.03344, eccentricity_phase_offset=0.048869, out_of_range_index=array([-1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1]), out_of_range=array([False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False]), upper_physically_possible_limit=2000, lower_physically_possible_limit=-4, solar_constant=1367.0, data_source='PVGIS', equation='Dₕc = G₀ ⋅ Tₙ(Tₗₖ) ⋅ F_d(h₀)', algorithm='The estimate of the clear-sky diffuse sky-reflected horizontal irradiance is the product of the normal extraterrestrial irradiance G0, a diffuse transmission function Tn dependent only on the Linke turbidity factor TLK, and a diffuse solar altitude function Fd dependent only on the solar altitude.', unit='W/m²', value=array([ 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 9.029055, 13.010079, 15.39051 , 16.467405, 16.438696, 15.300392, 12.844891, 8.77598 , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. ], dtype=float32), symbol='🗤⭳', description='Clear-sky diffuse sky-reflected horizontal irradiance is a solar power component received per unit area at a given moment, expressed in watts per square meter (W/m²). The values concern a specific location and a moment or period in time.', label='🗤⭳ Clear-Sky Diffuse Sky-Reflected Horizontal Irradiance', title='Sky-Diffuse Horizontal', supertitle='Sky-Diffuse Horizontal Irradiance', shortname='Clear-Sky-Diffuse Horizontal', name='Clear-Sky Diffuse Sky-Reflected Horizontal Irradiance Data', output=OrderedDict([('Diffuse Sky-Reflected Horizontal Irradiance', OrderedDict([('Name', 'Clear-Sky Diffuse Sky-Reflected Horizontal Irradiance Data'), ('Title', 'Sky-Diffuse Horizontal'), ('Description', 'Clear-sky diffuse sky-reflected horizontal irradiance is a solar power component received per unit area at a given moment, expressed in watts per square meter (W/m²). The values concern a specific location and a moment or period in time.'), ('Symbol', '🗤⭳'), ('Clear-Sky-Diffuse Horizontal 🗤⭳', array([ 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 9.029055, 13.010079, 15.39051 , 16.467405, 16.438696, 15.300392, 12.844891, 8.77598 , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. ], dtype=float32)), ('Unit', 'W/m²'), ('Equation', 'Dₕc = G₀ ⋅ Tₙ(Tₗₖ) ⋅ F_d(h₀)')])), ('Core', {}), ('Context', {}), ('Metadata', {}), ('Out-of-range', {}), ('Sources', {}), ('References', {}), ('Fingerprint', {}), ('Angular Unit', {})]) ), direct_horizontal_irradiance=DirectHorizontalIrradiance( elevation=214.0, references="Scharmer, K., Greif, J., eds., 2000, The European solar radiation atlas. Vol. 2: Database and exploitation software. Paris (Les Presses de l'École des Mines).", solar_timing_algorithm=None, solar_positioning_algorithm=None, visible=array([], dtype=float64), surface_in_shade=LocationShading( horizon_height=HorizonHeight( out_of_range_index=array([], dtype=float64), out_of_range=array([], dtype=float64), data_source=None, equation=None, algorithm=None, unit='radians', value=array([0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0.], dtype=float32), symbol='🏔', description='The horizon height angle from of a geographic point of observation, a solar surface in the context of solar positioning.', label='Horizon Height', title='Horizon Height', supertitle='Horizon Height data', shortname='Horizon', name='Horizon Height', min_radians=-1.5707963267948966, max_radians=1.5707963267948966, min_degrees=-90, max_degrees=90, output=OrderedDict([('Horizon Height', OrderedDict([('Name', 'Horizon Height'), ('Title', 'Horizon Height'), ('Description', 'The horizon height angle from of a geographic point of observation, a solar surface in the context of solar positioning.'), ('Symbol', '🏔'), ('Horizon 🏔', array([0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0.], dtype=float32)), ('Unit', 'radians')])), ('Fingerprint', {}), ('References', {}), ('Sources', {}), ('Out-of-range', {}), ('Metadata', {}), ('Context', {}), ('Core', {})]) ), visible=array([False, False, False, False, False, False, False, False, True, True, True, True, True, True, True, True, False, False, False, False, False, False, False, False, False]), surface_in_shade=None, shading_state=array([], dtype=float64), shading_states='all', shading_algorithm='PVGIS', solar_timing_algorithm='NOAA', solar_positioning_algorithm='NOAA', eccentricity_amplitude=0.03344, eccentricity_phase_offset=0.048869, solar_azimuth=array([0.3213954 , 0.81920004, 1.1580625 , 1.4022789 , 1.6000476 , 1.7777638 , 1.9510341 , 2.1332612 , 2.3256688 , 2.5371356 , 2.7716098 , 3.0284572 , 3.2693996 , 3.5246322 , 3.757891 , 3.9680827 , 4.160529 , 4.3414464 , 4.5146637 , 4.692999 , 4.8924146 , 5.1400876 , 5.485486 , 5.99152 , 0.31881952], dtype=float32), solar_altitude=array([ nan, nan, nan, nan, nan, nan, nan, nan, 0.1156317 , 0.23393297, 0.3195778 , 0.36424756, 0.36299396, 0.316038 , 0.22849977, 0.10883486, nan, nan, nan, nan, nan, nan, nan, nan, nan], dtype=float32), out_of_range_index=array([], dtype=float64), out_of_range=array([], dtype=float64), data_source=None, equation=None, algorithm=None, unit='Unitless', value=array([ True, True, True, True, True, True, True, True, False, False, False, False, False, False, False, False, True, True, True, True, True, True, True, True, True]), symbol='🮞', description=None, label='Location Shading', title='Location Shading', supertitle='Location Shading', shortname='Shading', name='Location Shading', output={} ), shading_state=array([], dtype=float64), shading_states='all', shading_algorithm='PVGIS', rayleigh_optical_thickness=None, optical_air_mass=OpticalAirMass( name='Relative optical air mass', title='Optical Air Mass', description='The relative optical air mass', value=array([ nan, nan, nan, nan, nan, nan, nan, nan, 7.9090304, 4.135905 , 3.0766902, 2.7191143, 2.7279515, 3.1093175, 4.228902 , 8.337962 , nan, nan, nan, nan, nan, nan, nan, nan, nan], dtype=float32), unit='Unitless', algorithm=None, equation='m = (p/p0)/(sin h0 ref + 0.50572 (h0 ref + 6.07995)-1.6364)', references='Kasten, F., Young, A.T., 1989, Revised optical air mass tables and approximation formula. Applied Optics, 28: 4735-4738.' ), adjusted_for_atmospheric_refraction=None, direct_normal_irradiance=DirectNormalIrradiance( optical_air_mass=OpticalAirMass( name='Relative optical air mass', title='Optical Air Mass', description='The relative optical air mass', value=array([ nan, nan, nan, nan, nan, nan, nan, nan, 7.9090304, 4.135905 , 3.0766902, 2.7191143, 2.7279515, 3.1093175, 4.228902 , 8.337962 , nan, nan, nan, nan, nan, nan, nan, nan, nan], dtype=float32), unit='Unitless', algorithm=None, equation='m = (p/p0)/(sin h0 ref + 0.50572 (h0 ref + 6.07995)-1.6364)', references='Kasten, F., Young, A.T., 1989, Revised optical air mass tables and approximation formula. Applied Optics, 28: 4735-4738.' ), rayleigh_optical_thickness=RayleighThickness( value=array([0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0.06382057, 0.0817092 , 0.09043514, 0.09410485, 0.09400862, 0.09012165, 0.08106308, 0.06244186, 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. ], dtype=float32), unit='Unitless' ), linke_turbidity_factor_adjusted=LinkeTurbidityFactor( name=None, title='Linke Turbidity', description='The Linke Turbidity Factor describes the attenuation of the extraterrestrial solar radiation by solid and liquid particles under cloudless sky conditions. It indicates the optical density of hazy and humid atmosphere in relation to a clean and dry atmosphere. In other words TLK is the number of clean dry air masses that would result in the same extinction then real hazy and humid air. Due to a dynamic nature of the turbidity factor, its calculation and subsequent averaging leads to a certain degree of generalisation. There are clear seasonal changes of the turbidity (lowest values in winter, highest in summer), the values of turbidity factor always differ from place to place in a similar degree of magnitude and these differences are also correlated with the terrain elevation. It increases with an intensity of industrialisation and urbanisation. The values of Linke turbidity for different landscapes or world regions can be found in literature [e.g. 16, 19, 30] or in http://www.soda-is.com/ [20]).', symbol='⋅', value=array([-0.8662, -0.8662, -0.8662, -0.8662, -0.8662, -0.8662, -0.8662, -0.8662, -0.8662, -0.8662, -0.8662, -0.8662, -0.8662, -0.8662, -0.8662, -0.8662, -0.8662, -0.8662, -0.8662, -0.8662, -0.8662, -0.8662, -0.8662, -0.8662, -0.8662], dtype=float32), unit='unitless', minimum=0, maximum=8 ), linke_turbidity_factor=LinkeTurbidityFactor( name=None, title='Linke Turbidity', description='The Linke Turbidity Factor describes the attenuation of the extraterrestrial solar radiation by solid and liquid particles under cloudless sky conditions. It indicates the optical density of hazy and humid atmosphere in relation to a clean and dry atmosphere. In other words TLK is the number of clean dry air masses that would result in the same extinction then real hazy and humid air. Due to a dynamic nature of the turbidity factor, its calculation and subsequent averaging leads to a certain degree of generalisation. There are clear seasonal changes of the turbidity (lowest values in winter, highest in summer), the values of turbidity factor always differ from place to place in a similar degree of magnitude and these differences are also correlated with the terrain elevation. It increases with an intensity of industrialisation and urbanisation. The values of Linke turbidity for different landscapes or world regions can be found in literature [e.g. 16, 19, 30] or in http://www.soda-is.com/ [20]).', symbol='⋅', value=array([1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1.], dtype=float32), unit='unitless', minimum=0, maximum=8 ), extraterrestrial_normal_irradiance=ExtraterrestrialNormalIrradiance( fingerprint=False, quality='Not validated!', solar_radiation_model='Hofierka 2002', refracted_solar_altitude=array([], dtype=float64), solar_altitude=None, eccentricity_amplitude=0.03344, eccentricity_phase_offset=0.048869, out_of_range_index=array([-1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1]), out_of_range=array([False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False]), upper_physically_possible_limit=2000, lower_physically_possible_limit=-4, solar_constant=1360.8, data_source=None, equation='Extraterrestrial Normal Irradiance = Solar Constant * Eccentricity Correction Factor', algorithm='The beam irradiance (solar energy) outside the atmosphere and at mean solar distance, is roughly constant at is 1367 W.m-2. However, the orbit of the earth around the sun is lightly eccentric hence its distance to the sun varies slightly across the year. In order to take into account the varying solar distance, the calculation of the extraterrestrial irradiance normal to the solar beam, considers an "eccentricity correction factor" ε.', unit='W/m²', value=array([1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.3005], dtype=float32), symbol='⍖ ⦜', description='Extraterrestrial irradiance', label='⍖ ⦜ Extraterrestrial Normal Irradiance', title='Extraterrestrial Normal Irradiance', supertitle='Simulated Extraterrestrial Normal Irradiance Series', shortname='Extra', name='Extraterrestrial Normal Irradiance', day_of_year=array([1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 2.], dtype=float32), day_angle=array([0.01721421, 0.01721421, 0.01721421, 0.01721421, 0.01721421, 0.01721421, 0.01721421, 0.01721421, 0.01721421, 0.01721421, 0.01721421, 0.01721421, 0.01721421, 0.01721421, 0.01721421, 0.01721421, 0.01721421, 0.01721421, 0.01721421, 0.01721421, 0.01721421, 0.01721421, 0.01721421, 0.01721421, 0.03442841], dtype=float32), distance_correction_factor=array([1.0334233, 1.0334233, 1.0334233, 1.0334233, 1.0334233, 1.0334233, 1.0334233, 1.0334233, 1.0334233, 1.0334233, 1.0334233, 1.0334233, 1.0334233, 1.0334233, 1.0334233, 1.0334233, 1.0334233, 1.0334233, 1.0334233, 1.0334233, 1.0334233, 1.0334233, 1.0334233, 1.0334233, 1.0334365], dtype=float32), output={} ), direct_horizontal_irradiance=array([], dtype=float64), fingerprint=False, quality=None, solar_radiation_model='Hofierka 2002', refracted_solar_altitude=array([], dtype=float64), solar_altitude=None, eccentricity_amplitude=0.03344, eccentricity_phase_offset=0.048869, out_of_range_index=array([-1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1]), out_of_range=array([False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False]), upper_physically_possible_limit=2000, lower_physically_possible_limit=-4, solar_constant=1360.8, data_source='[Source of the direct normal irradiance data]', equation='B0c = G0 exp {-0.8662 TLK m δR(m)}', algorithm='The direct (beam) irradiance normal to the solar beam B0c [W.m-2], attenuated by the cloudless atmosphere, is calculated as follows: B0c = G0 exp {-0.8662 TLK m δR(m)}.', unit='W/m²', value=array([ nan, nan, nan, nan, nan, nan, nan, nan, 908.21655, 1049.4065 , 1105.1018 , 1126.7133 , 1126.158 , 1103.2118 , 1044.9923 , 895.8101 , nan, nan, nan, nan, nan, nan, nan, nan, nan], dtype=float32), symbol='⇣ ⦜', description='Direct Normal Irradiance data model', label='⇣ ⦜ Simulated Direct Normal Irradiance', title='Normal Irradiance', supertitle='Direct Normal Irradiance', shortname='Normal', name='Direct Normal Irradiance Data', output={} ), fingerprint=False, quality=None, solar_radiation_model='Hofierka 2002', refracted_solar_altitude=array([ nan, nan, nan, nan, nan, nan, nan, nan, 6.62526 , 13.403404, 18.310488, 20.869873, 20.798048, 18.107672, 13.092105, 6.235832, nan, nan, nan, nan, nan, nan, nan, nan, nan], dtype=float32), solar_altitude=SolarAltitude( out_of_range_index=array([-1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1]), out_of_range=array([False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False]), adjusted_for_atmospheric_refraction=True, solar_timing_algorithm='NOAA', solar_positioning_algorithm='NOAA', data_source=None, equation=None, algorithm=None, unit='radians', value=array([ nan, nan, nan, nan, nan, nan, nan, nan, 0.1156317 , 0.23393297, 0.3195778 , 0.36424756, 0.36299396, 0.316038 , 0.22849977, 0.10883486, nan, nan, nan, nan, nan, nan, nan, nan, nan], dtype=float32), symbol='⦩', description='Solar altitude data for a location and period in time', label=None, title='Solar Altitude', supertitle='Solar Irradiance', shortname='Altitude', name='Solar Altitude', refracted_value=array([], dtype=float64), min_radians=-1.5707963267948966, max_radians=1.5707963267948966, low_angle_threshold_radians=0.04, min_degrees=-90, max_degrees=90, low_angle_threshold_degrees=2.291831180523293, output={} ), eccentricity_amplitude=0.03344, eccentricity_phase_offset=0.048869, out_of_range_index=array([-1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1]), out_of_range=array([False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False]), upper_physically_possible_limit=2000, lower_physically_possible_limit=-4, solar_constant=1367.0, data_source='Hofierka 2002', equation='Direct Horizontal = Direct Normal * Solar Altitude', algorithm='The direct (beam) irradiance on a horizontal surface is calculated as Direct horizontal irradiance = Direct normal irradiance * sin (solar altitude).', unit='W/m²', value=array([ 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 104.78475, 243.25784, 347.18515, 401.38745, 399.87018, 342.8818 , 236.70805, 97.30301, 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. ], dtype=float32), symbol='⇣ ⭳', description='Direct horizontal irradiance', label='⇣ ⭳ Simulated Direct Horizontal Irradiance', title='Direct Horizontal Irradiance', supertitle='Clear-Sky Direct Horizontal Irradiance', shortname='Direct Horizontal', name='Direct Horizontal Irradiance Data', output=OrderedDict([('Core', {}), ('Context', {}), ('Metadata', {}), ('Out-of-range', {}), ('Sources', {}), ('References', {}), ('Fingerprint', {}), ('Direct Horizontal Irradiance', OrderedDict([('Unit', 'W/m²'), ('Direct Horizontal ⇣ ⭳', array([ 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 104.78475, 243.25784, 347.18515, 401.38745, 399.87018, 342.8818 , 236.70805, 97.30301, 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. ], dtype=float32)), ('Symbol', '⇣ ⭳'), ('Description', 'Direct horizontal irradiance'), ('Title', 'Direct Horizontal Irradiance'), ('Name', 'Direct Horizontal Irradiance Data')])), ('Atmospheric Properties', {}), ('Elevation', {})]) ), fingerprint=False, references='D.L. King, J.A. Kratochvil, W.E. Boyson, W.I. Bower, Field experience with a new performance characterization procedure for photovoltaic arrays, in: Proceedings of the second World Conference and Exhibition on Photovoltaic Solar Energy Conversion, Vienna, 1998, pp. 1947–1952.. D.L. King, W.E. Boyson, J.A. Kratochvil, Photovoltaic Array Performance Model, SAND2004-3535, Sandia National Laboratories, 2004.', quality=None, solar_radiation_model='Hofierka 2002', solar_constant=1367.0, angle_output_units='radians', wind_speed=WindSpeedSeries( value=array([2., 2., 2., 2., 2., 2., 2., 2., 2., 2., 2., 2., 2., 2., 2., 2., 2., 2., 2., 2., 2., 2., 2., 2., 2.], dtype=float32), unit='㎧', symbol='🌬', description=None, data_source=None, average_wind_speed=1 ), temperature=TemperatureSeries( value=array([12., 12., 12., 12., 12., 12., 12., 12., 12., 12., 12., 12., 12., 12., 12., 12., 12., 12., 12., 12., 12., 12., 12., 12., 12.], dtype=float32), unit='℃', symbol='🌡', description=None, data_source=None, average_air_temperature=14, standard_test_temperature=25 ), visible=array([False, False, False, False, False, False, False, False, True, True, True, True, True, True, True, True, False, False, False, False, False, False, False, False, False]), surface_in_shade=LocationShading( horizon_height=HorizonHeight( out_of_range_index=array([], dtype=float64), out_of_range=array([], dtype=float64), data_source=None, equation=None, algorithm=None, unit='radians', value=array([0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0.], dtype=float32), symbol='🏔', description='The horizon height angle from of a geographic point of observation, a solar surface in the context of solar positioning.', label='Horizon Height', title='Horizon Height', supertitle='Horizon Height data', shortname='Horizon', name='Horizon Height', min_radians=-1.5707963267948966, max_radians=1.5707963267948966, min_degrees=-90, max_degrees=90, output=OrderedDict([('Horizon Height', OrderedDict([('Name', 'Horizon Height'), ('Title', 'Horizon Height'), ('Description', 'The horizon height angle from of a geographic point of observation, a solar surface in the context of solar positioning.'), ('Symbol', '🏔'), ('Horizon 🏔', array([0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0.], dtype=float32)), ('Unit', 'radians')])), ('Fingerprint', {}), ('References', {}), ('Sources', {}), ('Out-of-range', {}), ('Metadata', {}), ('Context', {}), ('Core', {})]) ), visible=array([False, False, False, False, False, False, False, False, True, True, True, True, True, True, True, True, False, False, False, False, False, False, False, False, False]), surface_in_shade=None, shading_state=array([], dtype=float64), shading_states='all', shading_algorithm='PVGIS', solar_timing_algorithm='NOAA', solar_positioning_algorithm='NOAA', eccentricity_amplitude=0.03344, eccentricity_phase_offset=0.048869, solar_azimuth=array([0.3213954 , 0.81920004, 1.1580625 , 1.4022789 , 1.6000476 , 1.7777638 , 1.9510341 , 2.1332612 , 2.3256688 , 2.5371356 , 2.7716098 , 3.0284572 , 3.2693996 , 3.5246322 , 3.757891 , 3.9680827 , 4.160529 , 4.3414464 , 4.5146637 , 4.692999 , 4.8924146 , 5.1400876 , 5.485486 , 5.99152 , 0.31881952], dtype=float32), solar_altitude=array([ nan, nan, nan, nan, nan, nan, nan, nan, 0.1156317 , 0.23393297, 0.3195778 , 0.36424756, 0.36299396, 0.316038 , 0.22849977, 0.10883486, nan, nan, nan, nan, nan, nan, nan, nan, nan], dtype=float32), out_of_range_index=array([], dtype=float64), out_of_range=array([], dtype=float64), data_source=None, equation=None, algorithm=None, unit='Unitless', value=array([ True, True, True, True, True, True, True, True, False, False, False, False, False, False, False, False, True, True, True, True, True, True, True, True, True]), symbol='🮞', description=None, label='Location Shading', title='Location Shading', supertitle='Location Shading', shortname='Shading', name='Location Shading', output={} ), shading_state=array(['In-shade', 'In-shade', 'In-shade', 'In-shade', 'In-shade', 'In-shade', 'In-shade', 'In-shade', 'Sunlit', 'Sunlit', 'Sunlit', 'Sunlit', 'Sunlit', 'Sunlit', 'Sunlit', 'Sunlit', 'In-shade', 'In-shade', 'In-shade', 'In-shade', 'In-shade', 'In-shade', 'In-shade', 'In-shade', 'In-shade'], dtype=object), shading_states={<ShadingState.all: 'all'>}, shading_algorithm='PVGIS', eccentricity_amplitude=0.03344, eccentricity_phase_offset=0.048869, solar_incidence_definition='Sun-Vector-to-Surface-Plane', solar_incidence_model='Iqbal', solar_incidence=SolarIncidence( solar_azimuth_origin=None, solar_timing_algorithm='NOAA', solar_positioning_algorithm='NOAA', data_source=None, equation=None, algorithm='Iqbal', unit='radians', value=array([0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0.7572487 , 0.9848717 , 1.2130069 , 1.4260373 , 1.4161675 , 1.2009394 , 0.9727134 , 0.74534965, 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. ], dtype=float32), symbol='⭸', description="The 'complementary' definition of the incidence incidence is the angle between the position of the sun in the sky (sun-vector) and the inclination of the surface (surface-plane) in question.", label='Solar incidence angle', title='Solar Incidence', supertitle='Solar Incidence Angle', shortname='Incidence', name='Solar Incidence', description_typical="The 'typical' definition of the solar incidence is the angle between the position of the sun (sun-vector) and the normal to the surface (surface-normal). An alternative definition measures the complementary angle between the sun (sun-vector) and the inclination of the surface (surface-plane) in question.", description_complementary="The 'complementary' definition of the incidence incidence is the angle between the position of the sun in the sky (sun-vector) and the inclination of the surface (surface-plane) in question.", sun_horizon_position=array(['Below', 'Below', 'Below', 'Below', 'Below', 'Below', 'Below', 'Below', 'Above', 'Above', 'Above', 'Above', 'Above', 'Above', 'Above', 'Above', 'Below', 'Below', 'Below', 'Below', 'Below', 'Below', 'Below', 'Below', 'Below'], dtype=object), definition='Sun-Vector-to-Surface-Plane', definition_typical='Sun-Vector-to-Surface-Normal', definition_complementary='Sun-Vector-to-Surface-Plane', output={} ), solar_azimuth_origin='Not Required!', solar_azimuth=SolarAzimuth( out_of_range_index=array([], dtype=float64), out_of_range=array([], dtype=float64), solar_timing_algorithm=None, solar_positioning_algorithm=None, min_degrees=0, min_radians=0, data_source=None, equation=None, algorithm=None, unit='Unitless', value=array([ 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 7.591031 , 16.551788 , 22.713737 , 25.71976 , 25.637625 , 22.469185 , 16.14704 , 7.0842776, 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. ], dtype=float32), symbol='\U000f19a5', description='Solar azimuth angle data for a location and period in time', label=None, title='Solar Azimuth', supertitle='Solar Irradiance', shortname='Azimuth', name='Solar Azimuth', max_radians=6.283185307179586, max_degrees=360, definition='Solar azimuth angle', origin='Not Required!', output={} ), refracted_solar_altitude=array([ nan, nan, nan, nan, nan, nan, nan, nan, 6.62526 , 13.403404, 18.310488, 20.869873, 20.798048, 18.107672, 13.092105, 6.235832, nan, nan, nan, nan, nan, nan, nan, nan, nan], dtype=float32), solar_altitude=SolarAltitude( out_of_range_index=array([-1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1]), out_of_range=array([False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False]), adjusted_for_atmospheric_refraction=True, solar_timing_algorithm='NOAA', solar_positioning_algorithm='NOAA', data_source=None, equation=None, algorithm=None, unit='radians', value=array([ nan, nan, nan, nan, nan, nan, nan, nan, 0.1156317 , 0.23393297, 0.3195778 , 0.36424756, 0.36299396, 0.316038 , 0.22849977, 0.10883486, nan, nan, nan, nan, nan, nan, nan, nan, nan], dtype=float32), symbol='⦩', description='Solar altitude data for a location and period in time', label=None, title='Solar Altitude', supertitle='Solar Irradiance', shortname='Altitude', name='Solar Altitude', refracted_value=array([], dtype=float64), min_radians=-1.5707963267948966, max_radians=1.5707963267948966, low_angle_threshold_radians=0.04, min_degrees=-90, max_degrees=90, low_angle_threshold_degrees=2.291831180523293, output={} ), adjusted_for_atmospheric_refraction=True, solar_timing_algorithm='NOAA', solar_positioning_algorithm='NOAA', linke_turbidity_factor=LinkeTurbidityFactor( name=None, title='Linke Turbidity', description='The Linke Turbidity Factor describes the attenuation of the extraterrestrial solar radiation by solid and liquid particles under cloudless sky conditions. It indicates the optical density of hazy and humid atmosphere in relation to a clean and dry atmosphere. In other words TLK is the number of clean dry air masses that would result in the same extinction then real hazy and humid air. Due to a dynamic nature of the turbidity factor, its calculation and subsequent averaging leads to a certain degree of generalisation. There are clear seasonal changes of the turbidity (lowest values in winter, highest in summer), the values of turbidity factor always differ from place to place in a similar degree of magnitude and these differences are also correlated with the terrain elevation. It increases with an intensity of industrialisation and urbanisation. The values of Linke turbidity for different landscapes or world regions can be found in literature [e.g. 16, 19, 30] or in http://www.soda-is.com/ [20]).', symbol='⋅', value=array([1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1.], dtype=float32), unit='unitless', minimum=0, maximum=8 ), horizon_height=HorizonHeight( out_of_range_index=array([], dtype=float64), out_of_range=array([], dtype=float64), data_source=None, equation=None, algorithm=None, unit='radians', value=array([0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0.], dtype=float32), symbol='🏔', description='The horizon height angle from of a geographic point of observation, a solar surface in the context of solar positioning.', label='Horizon Height', title='Horizon Height', supertitle='Horizon Height data', shortname='Horizon', name='Horizon Height', min_radians=-1.5707963267948966, max_radians=1.5707963267948966, min_degrees=-90, max_degrees=90, output=OrderedDict([('Horizon Height', OrderedDict([('Name', 'Horizon Height'), ('Title', 'Horizon Height'), ('Description', 'The horizon height angle from of a geographic point of observation, a solar surface in the context of solar positioning.'), ('Symbol', '🏔'), ('Horizon 🏔', array([0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0.], dtype=float32)), ('Unit', 'radians')])), ('Fingerprint', {}), ('References', {}), ('Sources', {}), ('Out-of-range', {}), ('Metadata', {}), ('Context', {}), ('Core', {})]) ), sun_horizon_positions={ <SunHorizonPositionModel.low_angle: 'Low angle'>, <SunHorizonPositionModel.below: 'Below'>, <SunHorizonPositionModel.above: 'Above'> }, sun_horizon_position=array([None, None, None, None, None, None, None, None, 'Above', 'Above', 'Above', 'Above', 'Above', 'Above', 'Above', 'Above', None, None, None, None, None, None, None, None, None], dtype=object), optimal=False, optimiser=None, optimization_mode=None, success=None, surface_tilt_threshold=0.0001, surface_tilt=1.3035176011540837, surface_orientation=3.141592653589793, elevation=214.0, location=None, ground_reflected_inclined_before_reflectivity=array([ 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 8.375469 , 18.858557 , 26.681662 , 30.749617 , 30.635847 , 26.35835 , 18.364408 , 7.8062706, 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. ], dtype=float32), diffuse_inclined_before_reflectivity=array([ 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 38.01464 , 38.59598 , 39.876083, 40.4878 , 40.471626, 39.822178, 38.511673, 38.16605 , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. ], dtype=float32), direct_inclined_before_reflectivity=array([ 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 623.8763 , 874.36676, 1035.1193 , 1114.9286 , 1112.7216 , 1028.6117 , 863.599 , 607.5642 , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. ], dtype=float32), global_inclined_before_reflectivity=array([ 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 670.2664 , 931.82135, 1101.677 , 1186.166 , 1183.8291 , 1094.7922 , 920.47504, 653.53656, 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. ], dtype=float32), ground_reflected_inclined_reflectivity_factor=array([0.9795655, 0.9795655, 0.9795655, 0.9795655, 0.9795655, 0.9795655, 0.9795655, 0.9795655, 0.9795655, 0.9795655, 0.9795655, 0.9795655, 0.9795655, 0.9795655, 0.9795655, 0.9795655, 0.9795655, 0.9795655, 0.9795655, 0.9795655, 0.9795655, 0.9795655, 0.9795655, 0.9795655, 0.9795655], dtype=float32), diffuse_inclined_reflectivity_coefficient=1.6555591587782237, diffuse_inclined_reflectivity_factor=array([0.98912525, 0.98912525, 0.98912525, 0.98912525, 0.98912525, 0.98912525, 0.98912525, 0.98912525, 0.98912525, 0.98912525, 0.98912525, 0.98912525, 0.98912525, 0.98912525, 0.98912525, 0.98912525, 0.98912525, 0.98912525, 0.98912525, 0.98912525, 0.98912525, 0.98912525, 0.98912525, 0.98912525, 0.98912525], dtype=float32), direct_inclined_reflectivity_factor=array([0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0.9865474 , 0.99380064, 0.9960515 , 0.9967366 , 0.9967205 , 0.99598485, 0.99359393, 0.98586214, 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. ], dtype=float32), ground_reflected_inclined_reflected_percentage=array([], dtype=float64), diffuse_inclined_reflected_percentage=array([], dtype=float64), direct_inclined_reflected_percentage=array([], dtype=float64), reflected_percentage=array([], dtype=float64), ground_reflected_inclined_reflected=array([ 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , -0.1711483 , -0.38536453, -0.54522705, -0.6283531 , -0.62602806, -0.53862 , -0.37526703, -0.15951729, 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. ], dtype=float32), diffuse_inclined_reflected=array([ 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , -0.41339874, -0.4197197 , -0.43364334, -0.44029617, -0.44011688, -0.43305588, -0.41880417, -0.4150467 , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. ], dtype=float32), direct_inclined_reflected=array([ 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , -8.392761 , -5.420532 , -4.087158 , -3.6384277, -3.64917 , -4.130005 , -5.5322876, -8.589661 , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. ], dtype=float32), global_inclined_reflected=array([ 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , -8.977308 , -6.2256165, -5.0660286, -4.707077 , -4.715315 , -5.1016808, -6.326359 , -9.164225 , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. ], dtype=float32), extraterrestrial_normal_irradiance=ExtraterrestrialNormalIrradiance( fingerprint=False, quality='Not validated!', solar_radiation_model='Hofierka 2002', refracted_solar_altitude=array([], dtype=float64), solar_altitude=None, eccentricity_amplitude=0.03344, eccentricity_phase_offset=0.048869, out_of_range_index=array([-1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1]), out_of_range=array([False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False]), upper_physically_possible_limit=2000, lower_physically_possible_limit=-4, solar_constant=1360.8, data_source=None, equation='Extraterrestrial Normal Irradiance = Solar Constant * Eccentricity Correction Factor', algorithm='The beam irradiance (solar energy) outside the atmosphere and at mean solar distance, is roughly constant at is 1367 W.m-2. However, the orbit of the earth around the sun is lightly eccentric hence its distance to the sun varies slightly across the year. In order to take into account the varying solar distance, the calculation of the extraterrestrial irradiance normal to the solar beam, considers an "eccentricity correction factor" ε.', unit='W/m²', value=array([1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.3005], dtype=float32), symbol='⍖ ⦜', description='Extraterrestrial irradiance', label='⍖ ⦜ Extraterrestrial Normal Irradiance', title='Extraterrestrial Normal Irradiance', supertitle='Simulated Extraterrestrial Normal Irradiance Series', shortname='Extra', name='Extraterrestrial Normal Irradiance', day_of_year=array([1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 2.], dtype=float32), day_angle=array([0.01721421, 0.01721421, 0.01721421, 0.01721421, 0.01721421, 0.01721421, 0.01721421, 0.01721421, 0.01721421, 0.01721421, 0.01721421, 0.01721421, 0.01721421, 0.01721421, 0.01721421, 0.01721421, 0.01721421, 0.01721421, 0.01721421, 0.01721421, 0.01721421, 0.01721421, 0.01721421, 0.01721421, 0.03442841], dtype=float32), distance_correction_factor=array([1.0334233, 1.0334233, 1.0334233, 1.0334233, 1.0334233, 1.0334233, 1.0334233, 1.0334233, 1.0334233, 1.0334233, 1.0334233, 1.0334233, 1.0334233, 1.0334233, 1.0334233, 1.0334233, 1.0334233, 1.0334233, 1.0334233, 1.0334233, 1.0334233, 1.0334233, 1.0334233, 1.0334233, 1.0334365], dtype=float32), output=OrderedDict([('Fingerprint', {}), ('References', {}), ('Sources', {}), ('Out-of-range', {}), ('Metadata', {}), ('Context', {}), ('Core', {}), ('Extraterrestrial Normal Irradiance', OrderedDict([('Unit', 'W/m²'), ('Extra ⍖ ⦜', array([1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.3005], dtype=float32)), ('Symbol', '⍖ ⦜'), ('Description', 'Extraterrestrial irradiance'), ('Title', 'Extraterrestrial Normal Irradiance'), ('Name', 'Extraterrestrial Normal Irradiance')])), ('Solar Radiation Model', {})]) ), extraterrestrial_horizontal_irradiance=ExtraterrestrialHorizontalIrradiance( fingerprint=False, quality='Not validated!', solar_radiation_model='Hofierka 2002', refracted_solar_altitude=array([], dtype=float64), solar_altitude=None, eccentricity_amplitude=0.03344, eccentricity_phase_offset=0.048869, out_of_range_index=array([-1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1]), out_of_range=array([False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False]), upper_physically_possible_limit=2000, lower_physically_possible_limit=-4, solar_constant=1367.0, data_source=None, equation='G0 horizontal = G0 normal ⋅ sin(solar altitude)', algorithm=None, unit='W/m²', value=array([ nan, nan, nan, nan, nan, nan, nan, nan, 162.2487 , 325.98352, 441.80582, 500.98297, 499.3353 , 437.07715, 318.54623, 152.75058, nan, nan, nan, nan, nan, nan, nan, nan, nan], dtype=float32), symbol='⍖ ⭳', description='Extraterrestrial irradiance', label='⍖ ⭳ Extraterrestrial Horizontal Irradiance', title='Extraterrestrial Horizontal', supertitle='Extraterrestrial Horizontal Irradiance Series', shortname='Extra', name='Extraterrestrial Horizontal Irradiance Data', normal=ExtraterrestrialNormalIrradiance( fingerprint=False, quality='Not validated!', solar_radiation_model='Hofierka 2002', refracted_solar_altitude=array([], dtype=float64), solar_altitude=None, eccentricity_amplitude=0.03344, eccentricity_phase_offset=0.048869, out_of_range_index=array([-1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1]), out_of_range=array([False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False]), upper_physically_possible_limit=2000, lower_physically_possible_limit=-4, solar_constant=1360.8, data_source=None, equation='Extraterrestrial Normal Irradiance = Solar Constant * Eccentricity Correction Factor', algorithm='The beam irradiance (solar energy) outside the atmosphere and at mean solar distance, is roughly constant at is 1367 W.m-2. However, the orbit of the earth around the sun is lightly eccentric hence its distance to the sun varies slightly across the year. In order to take into account the varying solar distance, the calculation of the extraterrestrial irradiance normal to the solar beam, considers an "eccentricity correction factor" ε.', unit='W/m²', value=array([1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.3005], dtype=float32), symbol='⍖ ⦜', description='Extraterrestrial irradiance', label='⍖ ⦜ Extraterrestrial Normal Irradiance', title='Extraterrestrial Normal Irradiance', supertitle='Simulated Extraterrestrial Normal Irradiance Series', shortname='Extra', name='Extraterrestrial Normal Irradiance', day_of_year=array([1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 2.], dtype=float32), day_angle=array([0.01721421, 0.01721421, 0.01721421, 0.01721421, 0.01721421, 0.01721421, 0.01721421, 0.01721421, 0.01721421, 0.01721421, 0.01721421, 0.01721421, 0.01721421, 0.01721421, 0.01721421, 0.01721421, 0.01721421, 0.01721421, 0.01721421, 0.01721421, 0.01721421, 0.01721421, 0.01721421, 0.01721421, 0.03442841], dtype=float32), distance_correction_factor=array([1.0334233, 1.0334233, 1.0334233, 1.0334233, 1.0334233, 1.0334233, 1.0334233, 1.0334233, 1.0334233, 1.0334233, 1.0334233, 1.0334233, 1.0334233, 1.0334233, 1.0334233, 1.0334233, 1.0334233, 1.0334233, 1.0334233, 1.0334233, 1.0334233, 1.0334233, 1.0334233, 1.0334233, 1.0334365], dtype=float32), output=OrderedDict([('Fingerprint', {}), ('References', {}), ('Sources', {}), ('Out-of-range', {}), ('Metadata', {}), ('Context', {}), ('Core', {}), ('Extraterrestrial Normal Irradiance', OrderedDict([('Unit', 'W/m²'), ('Extra ⍖ ⦜', array([1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.2825, 1406.3005], dtype=float32)), ('Symbol', '⍖ ⦜'), ('Description', 'Extraterrestrial irradiance'), ('Title', 'Extraterrestrial Normal Irradiance'), ('Name', 'Extraterrestrial Normal Irradiance')])), ('Solar Radiation Model', {})]) ), output={} ), rear_side_ground_reflected_inclined_irradiance=array([], dtype=float64), rear_side_diffuse_inclined_irradiance=array([], dtype=float64), rear_side_direct_inclined_irradiance=array([], dtype=float64), rear_side_global_inclined_irradiance=array([], dtype=float64), ground_reflected_inclined_irradiance=array([ 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 8.204321 , 18.473192 , 26.136435 , 30.121264 , 30.009819 , 25.81973 , 17.989141 , 7.6467533, 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. ], dtype=float32), diffuse_inclined_irradiance=array([ 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 37.601242, 38.17626 , 39.44244 , 40.047504, 40.03151 , 39.389122, 38.09287 , 37.751003, 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. ], dtype=float32), direct_inclined_irradiance=array([ nan, nan, nan, nan, nan, nan, nan, nan, 615.4835 , 868.9462 , 1031.0321 , 1111.2902 , 1109.0724 , 1024.4817 , 858.0667 , 598.97455, nan, nan, nan, nan, nan, nan, nan, nan, nan], dtype=float32), global_inclined_irradiance=array([ 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 661.28906, 925.5957 , 1096.611 , 1181.459 , 1179.1138 , 1089.6906 , 914.14874, 644.3723 , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. ], dtype=float32), spectral_factor_algorithm=None, spectral_factor=SpectralFactorSeries( value=array([1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1., 1.], dtype=float32), unit='unitless', symbol=None, description="The spectral effect in photovoltaic (PV) systems refers to how the wavelength composition of sunlight affects the efficiency of a PV cell, as different wavelengths are converted into electrical current with varying efficiencies depending on the cell's spectral response. This effect is quantified by integrating the product of the spectral response and the light intensity over relevant wavelengths, impacting the cell's short-circuit current and overall power output.", data_source=None, spectral_factor_algorithm=None ), spectral_effect_percentage=array([0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0.], dtype=float32), spectral_effect=array([0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., 0.], dtype=float32), effective_ground_reflected_irradiance=array([ 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 7.5864477, 16.541763 , 22.69987 , 25.703972 , 25.621885 , 22.455471 , 16.137262 , 7.0800004, 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. ], dtype=float32), effective_diffuse_irradiance=array([ 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 34.769466, 34.18482 , 34.256325, 34.174526, 34.178238, 34.256798, 34.17143 , 34.95302 , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. ], dtype=float32), effective_direct_irradiance=array([ nan, nan, nan, nan, nan, nan, nan, nan, 569.13104, 778.0953 , 895.4662 , 948.31915, 946.90765, 890.9938 , 769.7337 , 554.58044, nan, nan, nan, nan, nan, nan, nan, nan, nan], dtype=float32), effective_global_irradiance=array([ 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 611.48694, 828.82184, 952.42236, 1008.1977 , 1006.7078 , 947.70605, 820.04236, 596.61346, 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. ], dtype=float32), system_loss=array([], dtype=float64), system_efficiency=0.86, efficiency_factor=array([1.0074053 , 1.0074053 , 1.0074053 , 1.0074053 , 1.0074053 , 1.0074053 , 1.0074053 , 1.0074053 , 0.9246893 , 0.89544696, 0.86851436, 0.85334975, 0.8537834 , 0.869702 , 0.89705575, 0.9258832 , 1.0074053 , 1.0074053 , 1.0074053 , 1.0074053 , 1.0074053 , 1.0074053 , 1.0074053 , 1.0074053 , 1.0074053 ], dtype=float32), power_model='Huld 2011', peak_power=1.0, peak_power_unit='kWp', technology='CIS:Free standing', photovoltaic_module_type='Mono-Facial', out_of_range_index=array([-1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1]), out_of_range=array([False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False]), upper_physically_possible_limit=2000, lower_physically_possible_limit=-4, photovoltaic_power_without_system_loss=array([ 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 611.48694, 828.82184, 952.42236, 1008.1977 , 1006.7078 , 947.70605, 820.04236, 596.61346, 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. ], dtype=float32), data_source=None, equation='P(G₀, T₀) = G₀(P₀ₛₜ₃, m + k₁G₀) + k₂G₀)² + k₃T₀ + k₄T₀G₀ + k₅T₀G₀² + k₆T₀²', algorithm=None, unit='W', value=array([ 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 525.8788 , 712.7868 , 819.08325, 867.05005, 865.76874, 815.0272 , 705.23645, 513.0876 , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. ], dtype=float32), symbol='⌁', description='Photovoltaic Power based on a variant of King0s model (1998, 2004)', label='⌁ Simulated Photovoltaic Power', title='Power', supertitle='Photovoltaic Power', shortname='Power', name='Photovoltaic Power data model', output=OrderedDict([('Elevation', {}), ('Core', OrderedDict([('Name', 'Photovoltaic Power data model'), ('Title', 'Power'), ('Description', 'Photovoltaic Power based on a variant of King0s model (1998, 2004)'), ('Symbol', '⌁'), ('Power ⌁', array([ 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 525.8788 , 712.7868 , 819.08325, 867.05005, 865.76874, 815.0272 , 705.23645, 513.0876 , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. , 0. ], dtype=float32)), ('Unit', 'W'), ('Equation', 'P(G₀, T₀) = G₀(P₀ₛₜ₃, m + k₁G₀) + k₂G₀)² + k₃T₀ + k₄T₀G₀ + k₅T₀G₀² + k₆T₀²')])), ('Context', {}), ('Metadata', {}), ('Out-of-range', {}), ('Sources', {}), ('References', {}), ('Fingerprint', {}), ('Surface Position', {})]) ), mean_photovoltaic_power=np.float32(232.95676), optimiser=None, optimization_mode=None, success=None, surface_tilt_threshold=0.0001, surface_tilt=SurfaceTilt( optimal=True, optimiser=None, optimization_mode=None, success=None, min_degrees=0, min_radians=0, data_source=None, equation=None, algorithm=None, unit='radians', value=1.3035176011540837, symbol='⯐ ⎄', description=None, label='Surface Position', title='Surface Position', supertitle='Surface Position data', shortname='Surface Position', name='Surface Position', max_radians=3.141592653589793, max_degrees=180 ), surface_orientation=SurfaceOrientation( optimal=False, optimiser=None, optimization_mode=None, success=None, min_degrees=0, min_radians=0, data_source=None, equation=None, algorithm=None, unit='radians', value=3.141592653589793, symbol='⯐ ⎄', description=None, label='Surface Position', title='Surface Position', supertitle='Surface Position data', shortname='Surface Position', name='Surface Position', max_radians=6.283185307179586, max_degrees=360 ), data_source=None, equation=None, algorithm=None, unit=None, value=array([], dtype=float64), symbol='⊙', description='The optimal orientation and tilt angles that maximize mean photovoltaic power output for a given location, time period, and system configuration.', label='Optimal Surface Position', title='Optimal Surface Position', supertitle='Optimized Surface Position', shortname='Optimal Position', name='Optimal Surface Position', output={} ) )
We can plot the photovoltaic power output against the surface tilt angle along with the point of maximum output
graph_power_output(longitude = longitude,
latitude = latitude,
elevation = elevation,
timestamps = timestamps,
timezone = timezone,
spectral_factor_series = spectral_factor_series,
photovoltaic_module = photovoltaic_module,
temperature_series = temperature_series,
wind_speed_series = wind_speed_series,
linke_turbidity_factor_series = linke_turbidity_factor_series,
mode = mode,
surface_orientation = SurfaceOrientation(value=(surface_orientation), unit='radians'),
optimal_surface_tilt = result['Surface Tilt'].value,
optimal_pv_power = result['Mean PV Power']
)
--------------------------------------------------------------------------- TypeError Traceback (most recent call last) Cell In[7], line 13 1 graph_power_output(longitude = longitude, 2 latitude = latitude, 3 elevation = elevation, 4 timestamps = timestamps, 5 timezone = timezone, 6 spectral_factor_series = spectral_factor_series, 7 photovoltaic_module = photovoltaic_module, 8 temperature_series = temperature_series, 9 wind_speed_series = wind_speed_series, 10 linke_turbidity_factor_series = linke_turbidity_factor_series, 11 mode = mode, 12 surface_orientation = SurfaceOrientation(value=(surface_orientation), unit='radians'), ---> 13 optimal_surface_tilt = result['Surface Tilt'].value, 14 optimal_pv_power = result['Mean PV Power'] 15 ) TypeError: tuple indices must be integers or slices, not str
Optimal Tilt over a year¶
In this example, we optimize the tilt of the panel for the year 2010, considering the same panel orientation as before. First we need to define the new timestamps.
start_time = '2010-01-01'
end_time = '2010-12-31'
timestamps = generate_datetime_series(start_time=start_time, end_time=end_time, frequency="h")
We run the optimizer
result = optimize_angles(longitude = longitude,
latitude = latitude,
elevation = elevation,
timestamps = timestamps,
timezone = timezone,
spectral_factor_series = spectral_factor_series,
photovoltaic_module = photovoltaic_module,
temperature_series = temperature_series,
wind_speed_series = wind_speed_series,
linke_turbidity_factor_series = linke_turbidity_factor_series,
mode = mode,
surface_orientation = surface_orientation
)
print(result)
--------------------------------------------------------------------------- NameError Traceback (most recent call last) Cell In[9], line 1 ----> 1 result = optimize_angles(longitude = longitude, 2 latitude = latitude, 3 elevation = elevation, 4 timestamps = timestamps, 5 timezone = timezone, 6 spectral_factor_series = spectral_factor_series, 7 photovoltaic_module = photovoltaic_module, 8 temperature_series = temperature_series, 9 wind_speed_series = wind_speed_series, 10 linke_turbidity_factor_series = linke_turbidity_factor_series, 11 mode = mode, 12 surface_orientation = surface_orientation 13 ) 14 print(result) NameError: name 'optimize_angles' is not defined
And now we plot the PV Power
graph_power_output(longitude = longitude,
latitude = latitude,
elevation = elevation,
timestamps = timestamps,
timezone = timezone,
spectral_factor_series = spectral_factor_series,
photovoltaic_module = photovoltaic_module,
temperature_series = temperature_series,
wind_speed_series = wind_speed_series,
linke_turbidity_factor_series = linke_turbidity_factor_series,
mode = mode,
surface_orientation = SurfaceOrientation(value=(surface_orientation), unit='radians'),
optimal_surface_tilt = result['surface_tilt'].value,
optimal_pv_power = result['mean_power_output']
)
--------------------------------------------------------------------------- TypeError Traceback (most recent call last) Cell In[10], line 13 1 graph_power_output(longitude = longitude, 2 latitude = latitude, 3 elevation = elevation, 4 timestamps = timestamps, 5 timezone = timezone, 6 spectral_factor_series = spectral_factor_series, 7 photovoltaic_module = photovoltaic_module, 8 temperature_series = temperature_series, 9 wind_speed_series = wind_speed_series, 10 linke_turbidity_factor_series = linke_turbidity_factor_series, 11 mode = mode, 12 surface_orientation = SurfaceOrientation(value=(surface_orientation), unit='radians'), ---> 13 optimal_surface_tilt = result['surface_tilt'].value, 14 optimal_pv_power = result['mean_power_output'] 15 ) TypeError: tuple indices must be integers or slices, not str
Optimal Tilt & Orientation angles over 15 years¶
In this last example, we will optimize the tilt and orientation of the panel from 2005 to 2010. Let's define the new timestamps, and change our mode to "Tilt and Orientation"
start_time = '2005-01-01'
end_time = '2020-01-01'
timestamps = generate_datetime_series(start_time=start_time, end_time=end_time, frequency="h")
mode = SurfacePositionOptimizerMode.Tilt_and_Orientation
--------------------------------------------------------------------------- AttributeError Traceback (most recent call last) Cell In[11], line 4 2 end_time = '2020-01-01' 3 timestamps = generate_datetime_series(start_time=start_time, end_time=end_time, frequency="h") ----> 4 mode = SurfacePositionOptimizerMode.Tilt_and_Orientation File /usr/local/lib/python3.11/enum.py:786, in EnumType.__getattr__(cls, name) 784 return cls._member_map_[name] 785 except KeyError: --> 786 raise AttributeError(name) from None AttributeError: Tilt_and_Orientation
result = optimize_angles(longitude = longitude,
latitude = latitude,
elevation = elevation,
timestamps = timestamps,
timezone = timezone,
spectral_factor_series = spectral_factor_series,
photovoltaic_module = photovoltaic_module,
temperature_series = temperature_series,
wind_speed_series = wind_speed_series,
linke_turbidity_factor_series = linke_turbidity_factor_series,
mode = mode,
)
print(result)
--------------------------------------------------------------------------- NameError Traceback (most recent call last) Cell In[12], line 1 ----> 1 result = optimize_angles(longitude = longitude, 2 latitude = latitude, 3 elevation = elevation, 4 timestamps = timestamps, 5 timezone = timezone, 6 spectral_factor_series = spectral_factor_series, 7 photovoltaic_module = photovoltaic_module, 8 temperature_series = temperature_series, 9 wind_speed_series = wind_speed_series, 10 linke_turbidity_factor_series = linke_turbidity_factor_series, 11 mode = mode, 12 ) 14 print(result) NameError: name 'optimize_angles' is not defined
graph_power_output(longitude = longitude,
latitude = latitude,
elevation = elevation,
timestamps = timestamps,
timezone = timezone,
spectral_factor_series = spectral_factor_series,
photovoltaic_module = photovoltaic_module,
temperature_series = temperature_series,
wind_speed_series = wind_speed_series,
linke_turbidity_factor_series = linke_turbidity_factor_series,
mode = mode,
optimal_surface_tilt = result['surface_tilt'].value,
optimal_surface_orientation= result['surface_orientation'].value,
optimal_pv_power = result['mean_power_output']
)
--------------------------------------------------------------------------- TypeError Traceback (most recent call last) Cell In[13], line 12 1 graph_power_output(longitude = longitude, 2 latitude = latitude, 3 elevation = elevation, 4 timestamps = timestamps, 5 timezone = timezone, 6 spectral_factor_series = spectral_factor_series, 7 photovoltaic_module = photovoltaic_module, 8 temperature_series = temperature_series, 9 wind_speed_series = wind_speed_series, 10 linke_turbidity_factor_series = linke_turbidity_factor_series, 11 mode = mode, ---> 12 optimal_surface_tilt = result['surface_tilt'].value, 13 optimal_surface_orientation= result['surface_orientation'].value, 14 optimal_pv_power = result['mean_power_output'] 15 ) TypeError: tuple indices must be integers or slices, not str