honeybee_radiance.lightsource.sky.certainirradiance module¶
Generate sky with certain irradiance.
- class honeybee_radiance.lightsource.sky.certainirradiance.CertainIrradiance(irradiance=558.659, ground_reflectance=0.2, uniform=False)[source]¶
Bases:
_PointInTime
sky with certain irradiance.
The output of CertainIrradiance sky is similar to using command below:
gensky -c -B desired_irradiance
You can also generate the sky with certain illuminance using
from_illuminance
classmethod. The method converts the illuminance value to irradiance by dividing it by 179.0:gensky -c -B [desired_illuminance / 179.0]
It also includes ground glow source. Ground reflectance is set to %20 by default which is gensky’s default value. Use ground_reflectance property to adjust this value.
Note:
The conversion factor in the Radiance system for luminous efficacy is fixed at KR= 179 lumens/watt (lm/w). This should not be confused with the more usual daylighting value, which can be anywhere between 50 and 150 lm/w depending on the type of sky or light considered.
For more information see links below on the Radiance forum:
Default value is set to 558.659 which corresponds to a sky with 100,000 lux horizontal illuminance.
- Parameters:
irradiance – Desired horizontal diffuse irradiance value in watts/meter2 (Default: 558.659).
ground_reflectance – Average ground reflectance (Default: 0.2).
uniform – Boolean to note whether the sky is uniform instead of cloudy. (Default: False)
- Properties:
irradiance
illuminance
ground_hemisphere
sky_hemisphere
ground_reflectance
uniform
is_point_in_time
is_climate_based
- ToString()¶
Overwrite .NET ToString.
- classmethod from_dict(data)[source]¶
Create the sky from a dictionary.
- Parameters:
data – A python dictionary in the following format
{ 'type': 'CertainIrradiance', 'irradiance': 558.659, 'ground_reflectance': 0.2, 'uniform': False }
- classmethod from_illuminance(illuminance=100000, ground_reflectance=0.2, uniform=False)[source]¶
Create sky with certain illuminance.
- Parameters:
illuminance – Desired horizontal illuminance value in lux (Default: 100000).
ground_reflectance – Average ground reflectance (Default: 0.2).
uniform – Boolean to note whether the sky is uniform instead of cloudy. (Default: False)
- classmethod from_string(sky_string)[source]¶
Create a CertainIrradiance sky from a string.
- Parameters:
sky_string – A text string representing a CertainIrradiance sky. This can be either a string with a certain irradiance (eg. “irradiance 558.659”) or with a certain illuminance (eg. “illuminance 100000”). Any sky string can optionally have a “-g” property of a fractional number, which sets the reflectance of the ground. If unspecified, the ground will have a reflectance of 0.2. This sky can also have a “-u” property to set the sky as uniform instead of the default cloudy.
Usage:
# irradiance string representation of the sky sky_string = "irradiance 558.659" sky = CertainIrradiance.from_string(sky_string) # illuminance string representation of the sky sky_string = "illuminance 100000 -g 0.3 -u" sky = CertainIrradiance.from_string(sky_string)
- to_file(folder, name=None, mkdir=False)[source]¶
Write sky hemisphere to a sky_hemisphere.rad Radiance file.
- Parameters:
folder – Target folder.
name – File name.
mkdir – A boolean to note if the directory should be created if doesn’t exist (default: False).
- Returns:
Full path to the newly created file.
- property ground_hemisphere¶
Sky ground glow source.
- property ground_reflectance¶
Get or set a value between 0 and 1 for the ground reflectance.
If not specified, a default of 0.2 will be used.
- property illuminance¶
Sky illuminance value.
- property irradiance¶
Sky irradiance value.
- property is_climate_based¶
Return True if the sky is created based on values from weather data.
- property is_point_in_time¶
Return True if the sky is generated for a single point in time.
- property sky_hemisphere¶
Sky hemisphere glow source.
- property uniform¶
Boolean to note whether the sky is uniform instead of cloudy.