Closed zhu0619 closed 6 months ago
For the latest version of torch_geometric 2.4.0, the Collater was refactored and require an argument dataset.
dataset
Therefore, the current implementation of PYGGraphTransformer.get_collate_fn is no longer valid.
PYGGraphTransformer.get_collate_fn
The argument dataset should also be added in the get_collate_fn.
get_collate_fn
def get_collate_fn( self, dataset: Union[Dataset, Sequence[BaseData], DatasetAdapter], follow_batch: Optional[List[str]] = None, exclude_keys: Optional[List[str]] = None, return_pair: Optional[bool] = True, **kwargs, ): collator = Collater(dataset=dataset, follow_batch=follow_batch, exclude_keys=exclude_keys) return partial(self._collate_batch, collator=collator, return_pair=return_pair)
No response
Thanks @zhu0619, can you make a PR ?
@zhu0619, can you document the alternative of using the pyg DataLoader object directly somewhere ?
It allows actually not providing any collate function
Motivation
For the latest version of torch_geometric 2.4.0, the Collater was refactored and require an argument
dataset
.Therefore, the current implementation of
PYGGraphTransformer.get_collate_fn
is no longer valid.Pitch
The argument
dataset
should also be added in theget_collate_fn
.Additional context
No response