wavesimpro 0.9.2__tar.gz → 0.10.0__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.
- {wavesimpro-0.9.2 → wavesimpro-0.10.0}/PKG-INFO +1 -1
- {wavesimpro-0.9.2 → wavesimpro-0.10.0}/pyproject.toml +1 -1
- {wavesimpro-0.9.2 → wavesimpro-0.10.0}/src/wavesimpro/__init__.py +1 -1
- {wavesimpro-0.9.2 → wavesimpro-0.10.0}/src/wavesimpro/execute.py +19 -4
- {wavesimpro-0.9.2 → wavesimpro-0.10.0}/src/wavesimpro.egg-info/PKG-INFO +1 -1
- {wavesimpro-0.9.2 → wavesimpro-0.10.0}/setup.cfg +0 -0
- {wavesimpro-0.9.2 → wavesimpro-0.10.0}/src/wavesimpro/__main__.py +0 -0
- {wavesimpro-0.9.2 → wavesimpro-0.10.0}/src/wavesimpro/binary_utils.py +0 -0
- {wavesimpro-0.9.2 → wavesimpro-0.10.0}/src/wavesimpro/client.py +0 -0
- {wavesimpro-0.9.2 → wavesimpro-0.10.0}/src/wavesimpro/config.py +0 -0
- {wavesimpro-0.9.2 → wavesimpro-0.10.0}/src/wavesimpro/exceptions.py +0 -0
- {wavesimpro-0.9.2 → wavesimpro-0.10.0}/src/wavesimpro/json_helper.py +0 -0
- {wavesimpro-0.9.2 → wavesimpro-0.10.0}/src/wavesimpro/py.typed +0 -0
- {wavesimpro-0.9.2 → wavesimpro-0.10.0}/src/wavesimpro/setup.py +0 -0
- {wavesimpro-0.9.2 → wavesimpro-0.10.0}/src/wavesimpro/simulate.py +0 -0
- {wavesimpro-0.9.2 → wavesimpro-0.10.0}/src/wavesimpro/validate.py +0 -0
- {wavesimpro-0.9.2 → wavesimpro-0.10.0}/src/wavesimpro.egg-info/SOURCES.txt +0 -0
- {wavesimpro-0.9.2 → wavesimpro-0.10.0}/src/wavesimpro.egg-info/dependency_links.txt +0 -0
- {wavesimpro-0.9.2 → wavesimpro-0.10.0}/src/wavesimpro.egg-info/requires.txt +0 -0
- {wavesimpro-0.9.2 → wavesimpro-0.10.0}/src/wavesimpro.egg-info/top_level.txt +0 -0
|
@@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta"
|
|
|
4
4
|
|
|
5
5
|
[project]
|
|
6
6
|
name = "wavesimpro"
|
|
7
|
-
version = "0.
|
|
7
|
+
version = "0.10.0"
|
|
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"
|
|
@@ -280,12 +280,27 @@ def execute_via_api(
|
|
|
280
280
|
pol_map = {0: "x", 1: "y", 2: "z"}
|
|
281
281
|
pol_str = pol_map.get(pol_num, "none")
|
|
282
282
|
|
|
283
|
+
# Convert the user's source position (top-left corner in absolute
|
|
284
|
+
# corner-based μm — the MATLAB/Python convention) into the canonical
|
|
285
|
+
# WavesimProperties convention used by Rayfos Studio and consumed by
|
|
286
|
+
# the C# CommonServices: Position = CENTER of the source, expressed
|
|
287
|
+
# relative to the coordinate-system centre (which sits at the domain
|
|
288
|
+
# centre, world 0,0,0). Keeping every client emitting the same shape
|
|
289
|
+
# of WavesimProperties means the server has one coordinate path, not
|
|
290
|
+
# one per client.
|
|
291
|
+
src_extent_x = float(src_nx) * float(pixel_size)
|
|
292
|
+
src_extent_y = float(src_ny) * float(pixel_size)
|
|
293
|
+
src_extent_z = float(src_nz) * float(pixel_size)
|
|
294
|
+
position_x_centered = float(src["position"][0]) + src_extent_x / 2.0 - domain_x_um / 2.0
|
|
295
|
+
position_y_centered = float(src["position"][1]) + src_extent_y / 2.0 - domain_y_um / 2.0
|
|
296
|
+
position_z_centered = float(src["position"][2]) + src_extent_z / 2.0 - domain_z_um / 2.0
|
|
297
|
+
|
|
283
298
|
custom_source = create_custom_field_source(
|
|
284
299
|
name=f"source_{i + 1}",
|
|
285
300
|
field_data_id=source_ids[i],
|
|
286
|
-
position_x=
|
|
287
|
-
position_y=
|
|
288
|
-
position_z=
|
|
301
|
+
position_x=position_x_centered,
|
|
302
|
+
position_y=position_y_centered,
|
|
303
|
+
position_z=position_z_centered,
|
|
289
304
|
grid_nx=src_nx,
|
|
290
305
|
grid_ny=src_ny,
|
|
291
306
|
grid_nz=src_nz,
|
|
@@ -293,7 +308,7 @@ def execute_via_api(
|
|
|
293
308
|
amplitude_real=1.0,
|
|
294
309
|
amplitude_imag=0.0,
|
|
295
310
|
data_format="Complex64",
|
|
296
|
-
origin="
|
|
311
|
+
origin="center",
|
|
297
312
|
)
|
|
298
313
|
input_sources.append(custom_source)
|
|
299
314
|
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|