PyWAsP Subscriptions: How Runs are Counted

PyWAsP subscriptions are based on a tier system. Three one-year subscriptions are available: Bronze, Silver, and Gold, priced according to the number of runs and points-per-run it is possible to do in that year.

The number of runs is the number of times a call is made to any of the methods:
There are other functions in PyWAsP that call these methods internally, including:

The number of points in each run is the number of spatial output points requested from a function or method, i.e. NX * NY * NZ when a cuboid-shaped output object is requested.

To see how many spatial points are in a dataset used for output locations, the windkit function windkit.spatial.count_spatial_points can be used:

In [1]: import windkit as wk

In [2]: output_locs_cuboid = wk.spatial.create_dataset(
   ...:     [0, 50, 100],
   ...:     [-100, -50, 0],
   ...:     [50, 75, 100],
   ...:     struct="cuboid",
   ...:     crs="EPSG:25832"
   ...: )
   ...: 

In [3]: print(output_locs_cuboid)
<xarray.Dataset>
Dimensions:      (height: 3, south_north: 3, west_east: 3)
Coordinates:
  * height       (height) int64 50 75 100
  * south_north  (south_north) int64 -100 -50 0
  * west_east    (west_east) int64 0 50 100
    crs          int8 0
Data variables:
    output       (height, south_north, west_east) float64 0.0 0.0 ... 0.0 0.0
Attributes:
    Conventions:  CF-1.8
    history:      2024-02-16T10:48:50:\twindkit==0.7.1.dev17+ga2ef68d\twk.spa...

In [4]: print(wk.spatial.count_spatial_points(output_locs_cuboid))
27

We get the same number if we convert from a “cuboid” to a “point” spatial structure

In [5]: output_locs_pts = wk.spatial.to_point(output_locs_cuboid)

In [6]: print(output_locs_pts)
<xarray.Dataset>
Dimensions:      (point: 27)
Coordinates:
    crs          int8 0
    height       (point) int64 50 50 50 50 50 50 50 ... 100 100 100 100 100 100
    south_north  (point) int64 -100 -100 -100 -50 -50 -50 ... -50 -50 -50 0 0 0
    west_east    (point) int64 0 50 100 0 50 100 0 50 ... 100 0 50 100 0 50 100
Dimensions without coordinates: point
Data variables:
    output       (point) float64 0.0 0.0 0.0 0.0 0.0 0.0 ... 0.0 0.0 0.0 0.0 0.0
Attributes:
    Conventions:  CF-1.8
    history:      2024-02-16T10:48:50:\twindkit==0.7.1.dev17+ga2ef68d\twk.spa...

In [7]: print(wk.spatial.count_spatial_points(output_locs_pts))
27

Examples

In order to calculate local effects on a grid 100 by 100 at 2 heights requires 100 * 100 * 2 = 20000 points. This would be possible with the Bronze Tier subscription.

In order to calculate local effects on a grid of 150 by 150 at 3 heights requires 150 * 150 * 3 = 67500 points. This would require the Silver Tier Subscription.

In order to calculate local effects on a grid of 300 by 300 at 4 heights requires 300 * 300 * 4 = 360000 points. This would require the Gold Tier Subscription.

An example of a run that goes beyond the Gold Tier Subscription would be a grid with dimension 400 by 400 at 5 levels, requiring 800000 points. In this case the run can be split into several smaller runs, thereby increasing the run count.