Closed josephenguehard closed 2 years ago
Hi,
Thanks for this very nice library! I was just wandering, is there a reason for using __get_item__ instead of the magic method __getitem__ in the Signal? For instance here: https://github.com/benedekrozemberczki/pytorch_geometric_temporal/blob/90fc89e233fd3fd6117bcd7b5746819c496bc980/torch_geometric_temporal/signal/static_graph_temporal_signal.py#L103
__get_item__
__getitem__
Using __getitem__ would allow the user to get a snapshot directly by calling, for instance, dataset[0].
dataset[0]
Hi there @josephenguehard! Do you want to open a PR with refactoring the getitem methods in the signals?
Sounds good, will do it later today!
Hi,
Thanks for this very nice library! I was just wandering, is there a reason for using
__get_item__
instead of the magic method__getitem__
in the Signal? For instance here: https://github.com/benedekrozemberczki/pytorch_geometric_temporal/blob/90fc89e233fd3fd6117bcd7b5746819c496bc980/torch_geometric_temporal/signal/static_graph_temporal_signal.py#L103Using
__getitem__
would allow the user to get a snapshot directly by calling, for instance,dataset[0]
.