DSE-MSU / DeepRobust

A pytorch adversarial library for attack and defense methods on images and graphs
MIT License
994 stars 192 forks source link

Incompatible with latest scipy #124

Closed Leirunlin closed 1 year ago

Leirunlin commented 2 years ago

Hi! I encountered an error when running an attack demo: No module named 'scipy.sparse.linalg.eigen.arpack'; 'scipy.sparse.linalg.eigen' is not a package.

The error occurs as some of the files, such as "deeprobust/graph/rl/env.py", are not compatible with the latest scipy version.

A solution would be use from scipy.sparse.linalg import eigsh instead of from scipy.sparse.linalg.eigen.arpack import eigsh . I'm not sure if the problem occurs in other parts of the library or not. Would any updates about it be possible?

ChandlerBang commented 2 years ago

Thank you for bring it up! We actually fixed this issue in this commit #bbda3f284e8d5a17a4dbe6e11ef2f8f830f1ddd1

FinAminToastCrunch commented 2 years ago

Please put my fix in the pip install wheel so that users do not get the scipy import statement incorrect.

ChandlerBang commented 2 years ago

Thank you for the reminder. I have updated the pip wheel and you can install it via pip install deeprobust==0.2.6.

Leirunlin commented 2 years ago

Thanks for your update!