Numeric
numeric
¶
Functions¶
compute_3D_triangle_area_vectorized(corners, return_z_proj_area=True)
¶
summary
Parameters:
Name | Type | Description | Default |
---|---|---|---|
corners |
ndarray
|
(n_faces, n) |
required |
return_z_proj_area |
bool
|
description. Defaults to True. |
True
|
Returns:
Name | Type | Description |
---|---|---|
_type_ |
description |
Source code in geograypher/utils/numeric.py
create_ramped_weighting(rectangle_shape, ramp_dist_frac)
¶
Create a ramped weighting that is higher toward the center with a max value of 1 at a fraction from the edge
Parameters:
Name | Type | Description | Default |
---|---|---|---|
rectangle_shape |
Tuple[int, int]
|
Size of rectangle to create a mask for |
required |
ramp_dist_frac |
float
|
Portions at least this far from an edge will have full weight |
required |
Returns:
Type | Description |
---|---|
ndarray
|
np.ndarray: An array representing the weighting from 0-1 |