PyWAsP Subscriptions: How Runs are Counted
Overview
PyWAsP subscriptions use a tier system with three one-year subscription options:
- Bronze - Entry-level tier
6000 runs per year, 25000 points per run
- Silver - Mid-level tier
42000 runs per year, 125000 points per run
- Gold - Premium tier
294000 runs per year, 625000 points per run
Each tier has limits on:
Maximum number of runs per year
Maximum points per run
What Counts as a Run?
A run is counted each time you call one of these core methods:
Functions that consume runs internally:
pywasp.wasp.predict_wwc()
(consumes 2 runs - callsget_site_effects
twice)
How Points are Calculated
The number of points in a run equals the total spatial output points requested.
For cuboid-shaped outputs:
Points = NX × NY × NZ
Example: Counting points in a dataset
Use windkit.spatial.count_spatial_points
to determine point counts:
In [1]: import windkit as wk
# Create a cuboid dataset
In [2]: output_locs_cuboid = wk.spatial.create_dataset(
...: [0, 50, 100], # X coordinates
...: [-100, -50, 0], # Y coordinates
...: [50, 75, 100], # Z coordinates
...: struct="cuboid",
...: crs="EPSG:25832"
...: )
...:
In [3]: print(output_locs_cuboid)
<xarray.Dataset> Size: 289B
Dimensions: (height: 3, south_north: 3, west_east: 3)
Coordinates:
* height (height) int64 24B 50 75 100
* south_north (south_north) int64 24B -100 -50 0
* west_east (west_east) int64 24B 0 50 100
crs int8 1B 0
Data variables:
output (height, south_north, west_east) float64 216B 0.0 0.0 ... 0.0
Attributes:
Conventions: CF-1.8
history: 2025-07-22T14:10:35+00:00:\twindkit==1.0.3.dev1+ga612767\tw...
In [4]: print(f"Points: {wk.spatial.count_spatial_points(output_locs_cuboid)}")
Points: 27
Point count stays the same across spatial structures:
# Convert to point structure
In [5]: output_locs_pts = wk.spatial.to_point(output_locs_cuboid)
In [6]: print(output_locs_pts)
<xarray.Dataset> Size: 865B
Dimensions: (point: 27)
Coordinates:
crs int8 1B 0
height (point) int64 216B 50 50 50 50 50 50 ... 100 100 100 100 100
south_north (point) int64 216B -100 -100 -100 -50 -50 -50 ... -50 -50 0 0 0
west_east (point) int64 216B 0 50 100 0 50 100 0 ... 0 50 100 0 50 100
Dimensions without coordinates: point
Data variables:
output (point) float64 216B 0.0 0.0 0.0 0.0 0.0 ... 0.0 0.0 0.0 0.0
Attributes:
Conventions: CF-1.8
history: 2025-07-22T14:10:35+00:00:\twindkit==1.0.3.dev1+ga612767\tw...
In [7]: print(f"Points: {wk.spatial.count_spatial_points(output_locs_pts)}")
Points: 27
Subscription Tier Examples
Here’s how different calculations map to subscription tiers:
- Bronze Tier Example
Grid: 100 × 100 × 2 heights
Points:
100 × 100 × 2 = 20,000
✅ Within Bronze limits (25,000 points per run)
- Silver Tier Example
Grid: 200 × 200 × 3 heights
Points:
200 × 200 × 3 = 120,000
✅ Requires Silver tier or higher (125,000 points per run)
- Gold Tier Example
Grid: 250 × 250 × 10 heights
Points:
250 × 250 × 10 = 625,000
✅ Requires Gold tier (625,000 points per run)
- Exceeding Gold Tier Limits
Grid: 300 × 300 × 8 heights
Points:
300 × 300 × 8 = 720,000
❌ Exceeds Gold tier limits (625,000 points per run)
Solution: Split into multiple smaller runs (each run counts toward your total allowance)