wavesimpro 1.16.0__tar.gz → 1.17.1__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (28) hide show
  1. {wavesimpro-1.16.0 → wavesimpro-1.17.1}/PKG-INFO +35 -1
  2. {wavesimpro-1.16.0 → wavesimpro-1.17.1}/README.md +34 -0
  3. {wavesimpro-1.16.0 → wavesimpro-1.17.1}/pyproject.toml +1 -1
  4. {wavesimpro-1.16.0 → wavesimpro-1.17.1}/src/wavesimpro/__init__.py +1 -1
  5. {wavesimpro-1.16.0 → wavesimpro-1.17.1}/src/wavesimpro/client.py +2005 -1892
  6. {wavesimpro-1.16.0 → wavesimpro-1.17.1}/src/wavesimpro/execute.py +10 -1
  7. {wavesimpro-1.16.0 → wavesimpro-1.17.1}/src/wavesimpro/json_helper.py +28 -6
  8. {wavesimpro-1.16.0 → wavesimpro-1.17.1}/src/wavesimpro/runs.py +35 -7
  9. {wavesimpro-1.16.0 → wavesimpro-1.17.1}/src/wavesimpro/simulate.py +17 -0
  10. {wavesimpro-1.16.0 → wavesimpro-1.17.1}/src/wavesimpro/validate.py +2 -1
  11. {wavesimpro-1.16.0 → wavesimpro-1.17.1}/src/wavesimpro.egg-info/PKG-INFO +35 -1
  12. {wavesimpro-1.16.0 → wavesimpro-1.17.1}/setup.cfg +0 -0
  13. {wavesimpro-1.16.0 → wavesimpro-1.17.1}/src/wavesimpro/__main__.py +0 -0
  14. {wavesimpro-1.16.0 → wavesimpro-1.17.1}/src/wavesimpro/binary_utils.py +0 -0
  15. {wavesimpro-1.16.0 → wavesimpro-1.17.1}/src/wavesimpro/config.py +0 -0
  16. {wavesimpro-1.16.0 → wavesimpro-1.17.1}/src/wavesimpro/exceptions.py +0 -0
  17. {wavesimpro-1.16.0 → wavesimpro-1.17.1}/src/wavesimpro/model.py +0 -0
  18. {wavesimpro-1.16.0 → wavesimpro-1.17.1}/src/wavesimpro/py.typed +0 -0
  19. {wavesimpro-1.16.0 → wavesimpro-1.17.1}/src/wavesimpro/setup.py +0 -0
  20. {wavesimpro-1.16.0 → wavesimpro-1.17.1}/src/wavesimpro/studio_mode.py +0 -0
  21. {wavesimpro-1.16.0 → wavesimpro-1.17.1}/src/wavesimpro.egg-info/SOURCES.txt +0 -0
  22. {wavesimpro-1.16.0 → wavesimpro-1.17.1}/src/wavesimpro.egg-info/dependency_links.txt +0 -0
  23. {wavesimpro-1.16.0 → wavesimpro-1.17.1}/src/wavesimpro.egg-info/requires.txt +0 -0
  24. {wavesimpro-1.16.0 → wavesimpro-1.17.1}/src/wavesimpro.egg-info/top_level.txt +0 -0
  25. {wavesimpro-1.16.0 → wavesimpro-1.17.1}/tests/test_boundary_profile.py +0 -0
  26. {wavesimpro-1.16.0 → wavesimpro-1.17.1}/tests/test_command_wait.py +0 -0
  27. {wavesimpro-1.16.0 → wavesimpro-1.17.1}/tests/test_engine_mode.py +0 -0
  28. {wavesimpro-1.16.0 → wavesimpro-1.17.1}/tests/test_studio_mode.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: wavesimpro
3
- Version: 1.16.0
3
+ Version: 1.17.1
4
4
  Summary: WavesimPro Python API — cloud execution client for the Rayfos simulation platform
5
5
  Author: Rayfos
6
6
  Project-URL: Repository, https://github.com/rayfos/wavesimpro
@@ -75,4 +75,38 @@ field = wp.read_binary_field(run.download("output.bin"))
75
75
  - Preflight memory check and cost estimate before a run.
76
76
  - Binary upload/download helpers for permittivity volumes, source fields and monitors.
77
77
 
78
+ ## Monitors: which voxels you get
79
+
80
+ A monitor is an axis-aligned box in micrometres, relative to the coordinate-system centre. The
81
+ domain of N voxels spans [-S/2, S/2], so voxel *i* occupies [-S/2 + i·v, -S/2 + (i+1)·v] with
82
+ v = S/N (centre at -S/2 + (i+0.5)·v, for even and odd N alike). The compute node extracts the
83
+ **outer cover** of the box: every voxel it touches — first index floor(lo), last index
84
+ ceil(hi) − 1 with lo/hi the box edges in voxel units. An edge exactly on a voxel face does not
85
+ pull in the neighbour; a zero-thickness box is the one voxel containing the plane. So a box of
86
+ exactly k voxels aligned to the grid gives k planes, and the same box centred on a voxel centre
87
+ straddles k + 1; the result is never smaller than what you asked for unless the domain clamps it.
88
+
89
+ The node writes `monitors.json` next to the `monitor_<name>.bin` files with, per monitor, the
90
+ inclusive index ranges, the shape, the voxel size and the realised physical box; read it with
91
+ `run.monitor_regions()`. Monitor files are full resolution — nothing is downsampled on download.
92
+
93
+ ## Cost before upload
94
+
95
+ `client.preflight_check(..., max_iterations=n)` (called for you by `simulate*`, `submit` and
96
+ `execute_via_api`) returns a `cost` block on the cloud server: the upper-bound compute-token
97
+ cost at the run's iteration cap (voxels × iterations × field components × rate), your remaining
98
+ balance and whether the submit would be allowed. The run is charged for the iterations it
99
+ actually takes. The high-level calls stop before uploading anything when the cost is refused.
100
+ `client.get_quota()` returns the balance; `client.estimate_cost(project_id, version_id)` prices a
101
+ saved version.
102
+
103
+ ## Errors and warnings
104
+
105
+ Every `RayfosAPIError` message carries the server's full detail: the message, each
106
+ `errors[]`/`warnings[]` entry and, for a quota refusal, the estimated cost and remaining balance.
107
+ Pass `sampling_warnings=False` (or `configure(sampling_warnings=False)`) to silence the
108
+ "pixels per wavelength" advisory when your sampling is deliberate; Nyquist warnings stay.
109
+ `run.status()["commandStatus"]["engine"]` names the engine the node actually ran (`"Cpp"` or
110
+ `"Python"`), also for `engine="Any"`.
111
+
78
112
  See `CHANGELOG.md` for what each version added. Issues and feature requests: support@rayfos.com.
@@ -52,4 +52,38 @@ field = wp.read_binary_field(run.download("output.bin"))
52
52
  - Preflight memory check and cost estimate before a run.
53
53
  - Binary upload/download helpers for permittivity volumes, source fields and monitors.
54
54
 
55
+ ## Monitors: which voxels you get
56
+
57
+ A monitor is an axis-aligned box in micrometres, relative to the coordinate-system centre. The
58
+ domain of N voxels spans [-S/2, S/2], so voxel *i* occupies [-S/2 + i·v, -S/2 + (i+1)·v] with
59
+ v = S/N (centre at -S/2 + (i+0.5)·v, for even and odd N alike). The compute node extracts the
60
+ **outer cover** of the box: every voxel it touches — first index floor(lo), last index
61
+ ceil(hi) − 1 with lo/hi the box edges in voxel units. An edge exactly on a voxel face does not
62
+ pull in the neighbour; a zero-thickness box is the one voxel containing the plane. So a box of
63
+ exactly k voxels aligned to the grid gives k planes, and the same box centred on a voxel centre
64
+ straddles k + 1; the result is never smaller than what you asked for unless the domain clamps it.
65
+
66
+ The node writes `monitors.json` next to the `monitor_<name>.bin` files with, per monitor, the
67
+ inclusive index ranges, the shape, the voxel size and the realised physical box; read it with
68
+ `run.monitor_regions()`. Monitor files are full resolution — nothing is downsampled on download.
69
+
70
+ ## Cost before upload
71
+
72
+ `client.preflight_check(..., max_iterations=n)` (called for you by `simulate*`, `submit` and
73
+ `execute_via_api`) returns a `cost` block on the cloud server: the upper-bound compute-token
74
+ cost at the run's iteration cap (voxels × iterations × field components × rate), your remaining
75
+ balance and whether the submit would be allowed. The run is charged for the iterations it
76
+ actually takes. The high-level calls stop before uploading anything when the cost is refused.
77
+ `client.get_quota()` returns the balance; `client.estimate_cost(project_id, version_id)` prices a
78
+ saved version.
79
+
80
+ ## Errors and warnings
81
+
82
+ Every `RayfosAPIError` message carries the server's full detail: the message, each
83
+ `errors[]`/`warnings[]` entry and, for a quota refusal, the estimated cost and remaining balance.
84
+ Pass `sampling_warnings=False` (or `configure(sampling_warnings=False)`) to silence the
85
+ "pixels per wavelength" advisory when your sampling is deliberate; Nyquist warnings stay.
86
+ `run.status()["commandStatus"]["engine"]` names the engine the node actually ran (`"Cpp"` or
87
+ `"Python"`), also for `engine="Any"`.
88
+
55
89
  See `CHANGELOG.md` for what each version added. Issues and feature requests: support@rayfos.com.
@@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta"
4
4
 
5
5
  [project]
6
6
  name = "wavesimpro"
7
- version = "1.16.0"
7
+ version = "1.17.1"
8
8
  description = "WavesimPro Python API — cloud execution client for the Rayfos simulation platform"
9
9
  readme = "README.md"
10
10
  requires-python = ">=3.8"
@@ -55,7 +55,7 @@ from .json_helper import (
55
55
  parse_progress_data,
56
56
  )
57
57
 
58
- __version__ = "1.16.0"
58
+ __version__ = "1.17.1"
59
59
  __all__ = [
60
60
  # Client
61
61
  "RayfosClient",