Conversation
df9c2ef to
72d4d4b
Compare
frozen Domain
# Conflicts: # model/common/src/icon4py/model/common/grid/grid_manager.py # model/common/src/icon4py/model/common/grid/horizontal.py
# Conflicts: # model/common/src/icon4py/model/common/decomposition/definitions.py # model/common/src/icon4py/model/common/grid/base.py # model/common/src/icon4py/model/common/grid/grid_manager.py # model/common/src/icon4py/model/common/grid/gridfile.py # model/common/src/icon4py/model/common/grid/icon.py # model/common/tests/common/grid/fixtures.py # model/testing/src/icon4py/model/testing/grid_utils.py # model/testing/src/icon4py/model/testing/parallel_helpers.py
|
cscs-ci run default |
|
cscs-ci run default |
|
cscs-ci run distributed |
| self._edge_domain(h_grid.Zone.LOCAL), | ||
| self._edge_domain( | ||
| h_grid.Zone.HALO | ||
| ), # TODO(msimberg): END too much, invalid neighbor access. LOCAL too little? |
There was a problem hiding this comment.
This is weird. Why does this need to compute all the way to the first halo line to get correct results in the halo when a halo exchange is done later? Bug in indices or expected?
Same further down for other fields that need coinnectivities for computation.
| def array_ns_from_array(array: NDArray) -> ModuleType: | ||
| if isinstance(array, np.ndarray): | ||
| import numpy as xp | ||
| else: | ||
| import cupy as xp # type: ignore[no-redef] | ||
|
|
||
| return xp |
There was a problem hiding this comment.
sync with #1052 where we also implemented the same:
https://github.com/C2SM/icon4py/pull/1052/changes#diff-11b7ff7e81877fb9c7781a0c2d429d43d49b5640e264607ba1df910eea1e1adfR202
and whoever merges first wins?
model/common/src/icon4py/model/common/decomposition/definitions.py
Outdated
Show resolved
Hide resolved
model/common/src/icon4py/model/common/decomposition/definitions.py
Outdated
Show resolved
Hide resolved
model/common/src/icon4py/model/common/decomposition/definitions.py
Outdated
Show resolved
Hide resolved
| return SingleNodeReductions() | ||
|
|
||
|
|
||
| class DecompositionFlag(int, Enum): |
There was a problem hiding this comment.
should we move here the sketch from halo.py?
There was a problem hiding this comment.
Indifferent. I think it can be in either place equally well, but won't oppose moving it here if you prefer.
|
|
||
| def __init__( | ||
| self, | ||
| run_properties: defs.ProcessProperties, |
There was a problem hiding this comment.
this is called like so (mostly) everywhere else (it's actually mis-spelled processor_procs here and there)
| run_properties: defs.ProcessProperties, | |
| processor_props: defs.ProcessProperties, |
| allocator: GT4Py buffer allocator | ||
| """ | ||
| self._xp = data_alloc.import_array_ns(allocator) | ||
| self._props = run_properties |
There was a problem hiding this comment.
| self._props = run_properties | |
| self._processor_props = processor_props |
| """ | ||
| self._xp = data_alloc.import_array_ns(allocator) | ||
| self._props = run_properties | ||
| self._connectivities = {self._value(k): v for k, v in connectivities.items()} |
There was a problem hiding this comment.
why do we re-define this here instead of using it as is? can we force it to be dict[gtx.FieldOffset, data_alloc.NDArray] and avoid the str conversion? (it's not passed in from many places as far as I can see)
There was a problem hiding this comment.
Good question. I think it'd be nice if we can avoid the str. I can try removing that.
| f"The distribution assumes more nodes than the current run is scheduled on {self._props} ", | ||
| ) | ||
|
|
||
| def _assert_all_neighbor_tables(self) -> None: |
There was a problem hiding this comment.
should we chose either neighbor_table or connectivity but not both?
There was a problem hiding this comment.
I think we use connectivity in most places, so I would be in favour of that.
…s.py Co-authored-by: Jacopo Canton <jacopo.canton@gmail.com>
…s.py Co-authored-by: Jacopo Canton <jacopo.canton@gmail.com>
Co-authored-by: Jacopo Canton <jacopo.canton@gmail.com>
…s.py Co-authored-by: Jacopo Canton <jacopo.canton@gmail.com>
|
Mandatory Tests Please make sure you run these tests via comment before you merge!
Optional Tests To run benchmarks you can use:
To run tests and benchmarks with the DaCe backend you can use:
To run test levels ignored by the default test suite (mostly simple datatest for static fields computations) you can use:
For more detailed information please look at CI in the EXCLAIM universe. |
Decompose (global) grid file:
pymetisto decompose the global grid (cells) intonpatchesOmissions:
LAM grids need to be investigated further:
start_indexandend_indexnot in the halo construction.the number of halo lines (in terms of cells) is hardcoded to 2, that could be made a parameter.
Not sure it all runs on GPU correctly... most probably there are some
numpycupyissues to fix.