Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
P
pystencils_autodiff
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
This is an archived project. Repository and other project resources are read-only.
Show more breadcrumbs
pycodegen
pystencils_autodiff
Commits
ff23a9d9
Commit
ff23a9d9
authored
5 years ago
by
Stephan Seitz
Browse files
Options
Downloads
Patches
Plain Diff
Fix bug in graph_datahandling: HOST_TO_DEVICE and DEVICE_TO_HOST was swapped
parent
0c191f8d
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
src/pystencils_autodiff/graph_datahandling.py
+2
-2
2 additions, 2 deletions
src/pystencils_autodiff/graph_datahandling.py
with
2 additions
and
2 deletions
src/pystencils_autodiff/graph_datahandling.py
+
2
−
2
View file @
ff23a9d9
...
@@ -179,14 +179,14 @@ class GraphDataHandling(pystencils.datahandling.SerialDataHandling):
...
@@ -179,14 +179,14 @@ class GraphDataHandling(pystencils.datahandling.SerialDataHandling):
def
to_cpu
(
self
,
name
):
def
to_cpu
(
self
,
name
):
super
().
to_cpu
(
name
)
super
().
to_cpu
(
name
)
self
.
call_queue
.
append
(
DataTransfer
(
self
.
_fields
[
name
],
DataTransferKind
.
HOST_TO_DEVICE
))
self
.
call_queue
.
append
(
DataTransfer
(
self
.
_fields
[
name
],
DataTransferKind
.
DEVICE_TO_HOST
))
def
to_gpu
(
self
,
name
):
def
to_gpu
(
self
,
name
):
super
().
to_gpu
(
name
)
super
().
to_gpu
(
name
)
if
name
in
self
.
_custom_data_transfer_functions
:
if
name
in
self
.
_custom_data_transfer_functions
:
self
.
call_queue
.
append
(
'
Custom Tranfer Function
'
)
self
.
call_queue
.
append
(
'
Custom Tranfer Function
'
)
else
:
else
:
self
.
call_queue
.
append
(
DataTransfer
(
self
.
_fields
[
name
],
DataTransferKind
.
DEVICE_TO_HOST
))
self
.
call_queue
.
append
(
DataTransfer
(
self
.
_fields
[
name
],
DataTransferKind
.
HOST_TO_DEVICE
))
def
synchronization_function
(
self
,
names
,
stencil
=
None
,
target
=
None
,
**
_
):
def
synchronization_function
(
self
,
names
,
stencil
=
None
,
target
=
None
,
**
_
):
for
name
in
names
:
for
name
in
names
:
...
...
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