Skip to content
Discussion options

You must be logged in to vote

Self answering, I almost forgot, maybe there are others with the same problem. I came up looking for too long to the examples of in memory and not in memory classes. The trick to load multiple file is the place of the collate function call. In the example there is

import torch
from torch_geometric.data import InMemoryDataset, download_url


class MyOwnDataset(InMemoryDataset):
    def __init__(self, root, transform=None, pre_transform=None):
        super(MyOwnDataset, self).__init__(root, transform, pre_transform)
        self.data, self.slices = torch.load(self.processed_paths[0])

    def process(self):
        # Read data into huge `Data` list.
        data_list = [...]

        data, s…

Replies: 2 comments 3 replies

Comment options

You must be logged in to vote
3 replies
@Ripper346
Comment options

@rusty1s
Comment options

@Ripper346
Comment options

Comment options

You must be logged in to vote
0 replies
Answer selected by Ripper346
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants