svf
- eolab.georastertools.processing.algo.svf(input_data: ndarray, radius: int = 8, directions: int = 12, resolution: float = 0.5, altitude=None) ndarray[source]
Computes the Sky View Factor (SVF), which represents the fraction of the visible sky from each point in a Digital Elevation Model (DEM).
More information about the Sky View Factor can be found here.
- Parameters:
input_data (np.ndarray) – A 3D numpy array of shape (1, number_of_lines, number_of_columns) containing the Digital Elevation Model (DEM). The function only accepts arrays with one band (the first dimension must be 1).
radius (int) – The maximum distance (in pixels) around each point to evaluate the horizontal elevation angle. Default is 8.
direction (int) – The number of discrete directions to compute the vertical angle. Default is 12.
resolution (float) – The spatial resolution of the input data in meters. Default is 0.5.
altitude (Optional[np.ndarray]) – A reference altitude to use for computing the SVF. If not specified, SVF is computed using the elevation of each point.
- Returns:
- A numpy array of the same size as input_data, containing the Sky View Factor for each point,
where values range from 0 (no visible sky) to 1 (full sky visibility).
- Return type:
np.ndarray
- Raises:
ValueError – If input_data does not have 3 dimensions or if the first dimension is not of size 1.