Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
pystencils
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Markus Holzer
pystencils
Commits
43ea98e9
Commit
43ea98e9
authored
4 years ago
by
Markus Holzer
Browse files
Options
Downloads
Patches
Plain Diff
Switched to int64
parent
e8b9fa9c
No related branches found
No related tags found
No related merge requests found
Pipeline
#32395
failed
4 years ago
Stage: test
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
pystencils/boundaries/createindexlist.py
+6
-6
6 additions, 6 deletions
pystencils/boundaries/createindexlist.py
with
6 additions
and
6 deletions
pystencils/boundaries/createindexlist.py
+
6
−
6
View file @
43ea98e9
...
@@ -30,15 +30,15 @@ direction_member_name = "dir"
...
@@ -30,15 +30,15 @@ direction_member_name = "dir"
def
numpy_data_type_for_boundary_object
(
boundary_object
,
dim
):
def
numpy_data_type_for_boundary_object
(
boundary_object
,
dim
):
coordinate_names
=
boundary_index_array_coordinate_names
[:
dim
]
coordinate_names
=
boundary_index_array_coordinate_names
[:
dim
]
return
np
.
dtype
([(
name
,
np
.
int
32
)
for
name
in
coordinate_names
]
return
np
.
dtype
([(
name
,
np
.
int
64
)
for
name
in
coordinate_names
]
+
[(
direction_member_name
,
np
.
int
32
)]
+
[(
direction_member_name
,
np
.
int
64
)]
+
[(
i
[
0
],
i
[
1
].
numpy_dtype
)
for
i
in
boundary_object
.
additional_data
],
align
=
True
)
+
[(
i
[
0
],
i
[
1
].
numpy_dtype
)
for
i
in
boundary_object
.
additional_data
],
align
=
True
)
def
_create_boundary_neighbor_index_list_python
(
flag_field_arr
,
nr_of_ghost_layers
,
boundary_mask
,
def
_create_boundary_neighbor_index_list_python
(
flag_field_arr
,
nr_of_ghost_layers
,
boundary_mask
,
fluid_mask
,
stencil
,
single_link
):
fluid_mask
,
stencil
,
single_link
):
coordinate_names
=
boundary_index_array_coordinate_names
[:
len
(
flag_field_arr
.
shape
)]
coordinate_names
=
boundary_index_array_coordinate_names
[:
len
(
flag_field_arr
.
shape
)]
index_arr_dtype
=
np
.
dtype
([(
name
,
np
.
int
32
)
for
name
in
coordinate_names
]
+
[(
direction_member_name
,
np
.
int
32
)])
index_arr_dtype
=
np
.
dtype
([(
name
,
np
.
int
64
)
for
name
in
coordinate_names
]
+
[(
direction_member_name
,
np
.
int
64
)])
result
=
[]
result
=
[]
gl
=
nr_of_ghost_layers
gl
=
nr_of_ghost_layers
...
@@ -59,7 +59,7 @@ def _create_boundary_neighbor_index_list_python(flag_field_arr, nr_of_ghost_laye
...
@@ -59,7 +59,7 @@ def _create_boundary_neighbor_index_list_python(flag_field_arr, nr_of_ghost_laye
def
_create_boundary_cell_index_list_python
(
flag_field_arr
,
boundary_mask
,
def
_create_boundary_cell_index_list_python
(
flag_field_arr
,
boundary_mask
,
fluid_mask
,
stencil
,
single_link
):
fluid_mask
,
stencil
,
single_link
):
coordinate_names
=
boundary_index_array_coordinate_names
[:
len
(
flag_field_arr
.
shape
)]
coordinate_names
=
boundary_index_array_coordinate_names
[:
len
(
flag_field_arr
.
shape
)]
index_arr_dtype
=
np
.
dtype
([(
name
,
np
.
int
32
)
for
name
in
coordinate_names
]
+
[(
direction_member_name
,
np
.
int
32
)])
index_arr_dtype
=
np
.
dtype
([(
name
,
np
.
int
64
)
for
name
in
coordinate_names
]
+
[(
direction_member_name
,
np
.
int
64
)])
result
=
[]
result
=
[]
for
cell
in
itertools
.
product
(
*
reversed
([
range
(
0
,
i
)
for
i
in
flag_field_arr
.
shape
])):
for
cell
in
itertools
.
product
(
*
reversed
([
range
(
0
,
i
)
for
i
in
flag_field_arr
.
shape
])):
...
@@ -96,9 +96,9 @@ def create_boundary_index_list(flag_field, stencil, boundary_mask, fluid_mask,
...
@@ -96,9 +96,9 @@ def create_boundary_index_list(flag_field, stencil, boundary_mask, fluid_mask,
"""
"""
dim
=
len
(
flag_field
.
shape
)
dim
=
len
(
flag_field
.
shape
)
coordinate_names
=
boundary_index_array_coordinate_names
[:
dim
]
coordinate_names
=
boundary_index_array_coordinate_names
[:
dim
]
index_arr_dtype
=
np
.
dtype
([(
name
,
np
.
int
32
)
for
name
in
coordinate_names
]
+
[(
direction_member_name
,
np
.
int
32
)])
index_arr_dtype
=
np
.
dtype
([(
name
,
np
.
int
64
)
for
name
in
coordinate_names
]
+
[(
direction_member_name
,
np
.
int
64
)])
stencil
=
np
.
array
(
stencil
,
dtype
=
np
.
int
32
)
stencil
=
np
.
array
(
stencil
,
dtype
=
np
.
int
64
)
args
=
(
flag_field
,
nr_of_ghost_layers
,
boundary_mask
,
fluid_mask
,
stencil
,
single_link
)
args
=
(
flag_field
,
nr_of_ghost_layers
,
boundary_mask
,
fluid_mask
,
stencil
,
single_link
)
args_no_gl
=
(
flag_field
,
boundary_mask
,
fluid_mask
,
stencil
,
single_link
)
args_no_gl
=
(
flag_field
,
boundary_mask
,
fluid_mask
,
stencil
,
single_link
)
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment