Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
P
pystencils-benchmark
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
Package registry
Container registry
Model registry
Operate
Environments
Terraform modules
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
pycodegen
pystencils-benchmark
Commits
ac4b31c1
Commit
ac4b31c1
authored
1 year ago
by
Christoph Alt
Browse files
Options
Downloads
Patches
Plain Diff
Updated import to new pystencils api
parent
96c63098
No related branches found
No related tags found
1 merge request
!1
Add CUDA support
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
pystencils_benchmark/benchmark_gpu.py
+4
-4
4 additions, 4 deletions
pystencils_benchmark/benchmark_gpu.py
with
4 additions
and
4 deletions
pystencils_benchmark/benchmark_gpu.py
+
4
−
4
View file @
ac4b31c1
...
...
@@ -6,10 +6,10 @@ from jinja2 import Environment, PackageLoader, StrictUndefined
from
pystencils.backends.cbackend
import
generate_c
,
get_headers
from
pystencils.astnodes
import
KernelFunction
from
pystencils.enums
import
Backend
from
pystencils.
data_types
import
get_base_type
from
pystencils.
typing
import
get_base_type
from
pystencils.sympyextensions
import
prod
from
pystencils.transformations
import
get_common_
shape
from
pystencils.gpucuda
import
BlockIndexing
from
pystencils.transformations
import
get_common_
field
#
from pystencils.gpucuda import BlockIndexing
from
pystencils_benchmark.enums
import
Compiler
...
...
@@ -121,7 +121,7 @@ def kernel_main(kernels_ast: List[KernelFunction], timing: bool = True, cuda_blo
fields
.
append
((
p
.
field_name
,
dtype
,
elements
))
call_parameters
.
append
(
p
.
field_name
)
common_shape
=
get_common_
shape
(
kernel
.
fields_accessed
)
common_shape
=
get_common_
field
(
kernel
.
fields_accessed
)
.
shape
indexing
=
kernel
.
indexing
block_and_thread_numbers
=
indexing
.
call_parameters
(
common_shape
)
block_and_thread_numbers
[
'
block
'
]
=
tuple
(
int
(
i
)
for
i
in
block_and_thread_numbers
[
'
block
'
])
...
...
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