dgl icon indicating copy to clipboard operation
dgl copied to clipboard

How to get sparse feature importance from GNNExplainer

Open BrownEyes1225 opened this issue 1 year ago • 1 comments

❓ Questions and Help

Hi to everyone!

I am using GNNExplainer in DGL.

I have tried to increase the beta1 and beta 2 to larger values in order to get sparse feature importance vector, but no matter how large the two parameters are, the feature importance are not sparse.

Does ‘sparse’ mean the feature importance should have zeros? If so, why GNNExplainer fail to output sparse results?

Thanks a lot!

BrownEyes1225 avatar Mar 20 '24 02:03 BrownEyes1225

Both options only make most of the entries go close to zero (like 0.001) by entropy and mean regularization, but not exactly zero. If you want a "truly" sparse explanation you could set a threshold and cut all the masks below it to zero.

BarclayII avatar Apr 11 '24 02:04 BarclayII

This issue has been automatically marked as stale due to lack of activity. It will be closed if no further activity occurs. Thank you

github-actions[bot] avatar May 12 '24 01:05 github-actions[bot]

Hi @BrownEyes1225, I am closing this issue assuming you are happy about our response. Feel free to follow up and reopen the issue if you have more questions with regard to our response.

peizhou001 avatar May 16 '24 01:05 peizhou001