Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow any integer tensors when checking edge_index input to message passing #5281

Merged
merged 4 commits into from
Aug 26, 2022

Conversation

hatemhelal
Copy link
Contributor

@hatemhelal hatemhelal commented Aug 26, 2022

Partial fix for #5087

This relaxes the __check_input__ method of the message passing interface to allow any integer types for the edge_index. This is necessary to allow PyTorch to dispatch to different execution backends (see this tutorial).

This effectively defers the question of which types are supported to the underlying device backend.

@codecov
Copy link

codecov bot commented Aug 26, 2022

Codecov Report

Merging #5281 (38e8ffb) into master (6f6f08c) will increase coverage by 0.00%.
The diff coverage is 100.00%.

@@           Coverage Diff           @@
##           master    #5281   +/-   ##
=======================================
  Coverage   83.33%   83.33%           
=======================================
  Files         337      337           
  Lines       18634    18635    +1     
=======================================
+ Hits        15528    15529    +1     
  Misses       3106     3106           
Impacted Files Coverage Δ
torch_geometric/nn/conv/message_passing.py 98.84% <100.00%> (+<0.01%) ⬆️

📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more

Copy link
Member

@rusty1s rusty1s left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can we also add this change to the CHANGELOG.md?

test/nn/conv/test_message_passing.py Outdated Show resolved Hide resolved
@hatemhelal hatemhelal force-pushed the message-passing-ints branch from 47e6dd1 to 12b198c Compare August 26, 2022 10:50
hatemhelal and others added 2 commits August 26, 2022 11:51
Co-authored-by: Matthias Fey <matthias.fey@tu-dortmund.de>
@rusty1s rusty1s enabled auto-merge (squash) August 26, 2022 14:32
@rusty1s rusty1s disabled auto-merge August 26, 2022 17:08
@rusty1s rusty1s merged commit 615d0b6 into pyg-team:master Aug 26, 2022
@hatemhelal hatemhelal deleted the message-passing-ints branch August 26, 2022 18:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants