Verified-Intelligence / auto_LiRPA

auto_LiRPA: An Automatic Linear Relaxation based Perturbation Analysis Library for Neural Networks and General Computational Graphs
https://arxiv.org/pdf/2002.12920
Other
282 stars 69 forks source link

Issues with examples/vision/simple_training.py #34

Closed wanyu42 closed 11 months ago

wanyu42 commented 1 year ago

Dear auto_LiRPA Team, Thanks for providing this library! I am trying to run the command

python simple_training.py --model mlp_3layer --norm 0 --eps 1

provided in examples/vision/simple_training.py

However, auto_LiRPA/operators/linear.py causes

RuntimeError: mat1 and mat2 shapes cannot be multiplied (2x100352 and 784x256)

Do you have any insights on the problem?

Best, Yuxuan

shizhouxing commented 1 year ago

Hi Yuxuan @wanyu42 ,

Thanks for trying our library. I tried the command you provided but I didn't see the issue. Did the RuntimeError appear in the first several epochs or so on your side? May I know your PyTorch version?

wanyu42 commented 1 year ago

Thanks for your reply.

The problem comes from my PyTorch version 1.13.0, which I fixed after downgrading to 1.12.0.

shizhouxing commented 1 year ago

@wanyu42 Thanks for letting us know! We'll check issues with pytorch 1.13.

shizhouxing commented 11 months ago

@wanyu42 We checked our latest release on pytorch 1.13 and it looks like the issue is gone.