pyg-team / pytorch_geometric

Graph Neural Network Library for PyTorch
https://pyg.org
MIT License
21.44k stars 3.68k forks source link

How exactly are superpixels generated in MnistSuperpixels dataset? #2865

Open ashleve opened 3 years ago

ashleve commented 3 years ago

When I look into MnistSuperpixels dataset, each graph has exactly 75 nodes.

When I convert MNIST to superpixels by myself using ToSLIC transform from pytorch geometric, I get exactly 81 nodes for each image.

What is the exact methodology for superpixel generation in MnistSuperpixels?

I read the "Geometric deep learning on graphs and manifolds using mixture model CNNs" which is where this dataset comes from but did not find any explanation in the paper.

Is it using SLIC algorithm, and if so, is it just the matter of passing correct parameters?

rusty1s commented 3 years ago

I'm not exactly sure either. We directly use the dataset provided in the MoNet paper. I sadly do not know the exact hyperparameters that were used to generate the dataset. However, if you pass in n_segments=75 with enforce_connectvitity=False, you should exactly receive 75 superpixels back.

ashleve commented 3 years ago

@rusty1s Thanks, Unfortutaly enforce_connectvitity=False doesn't change anything. I'm guessing that's because of low resolution of the images - seems like there's just not enough ways to generate those superpixels.

rusty1s commented 3 years ago

I don't think this is due to low resolution but more so with hyperparameters. You probably want to reach out to the MoNet authors for clarification :)