dnn-security / Watermark-Robustness-Toolbox

The official implementation of the IEEE S&P`22 paper "SoK: How Robust is Deep Neural Network Image Classification Watermarking".
GNU General Public License v3.0
102 stars 27 forks source link

no module named 'backdoor' #1

Open MENG2010 opened 2 years ago

MENG2010 commented 2 years ago

Hi there,

Thanks for this great survey. It is informative and provides lots of insights. Thanks a lot for opensource this toolbox. However, when I tried to play with it, I encountered a ModuleNotFoundError.

I have installed all requirements and optional requirements. Then when I attempted to train a model on cifar10 using

python train.py --config configs/cifar10/train_configs/resnet.yaml

I encountered a ModuleNotFoundError as follows,

Traceback (most recent call last):
  File "train.py", line 14, in <module>
    from wrt.classifiers import PyTorchClassifier
  File "/PyWorkSpace/WRT/wrt/__init__.py", line 8, in <module>
    from wrt import attacks
  File "/PyWorkSpace/WRT/wrt/attacks/__init__.py", line 6, in <module>
    from wrt.attacks.removal.fine_tuning import FTLLAttack, FTALAttack, RTLLAttack, RTALAttack, FineTuningAttack
  File "/PyWorkSpace/WRT/wrt/attacks/removal/__init__.py", line 10, in <module>
    from .regularization import Regularization
  File "/PyWorkSpace/WRT/wrt/attacks/removal/regularization.py", line 37, in <module>
    from wrt.defenses import Watermark
  File "/PyWorkSpace/WRT/wrt/defenses/__init__.py", line 5, in <module>
    from backdoor import *
ModuleNotFoundError: No module named 'backdoor'

I've checked wrt/defenses/ and all possible places and could not find this backdoor.

I appreciate it if you can help me with this issue.

Best, MENG2010

MENG2010 commented 2 years ago

Looks like that backdoor is not needed for training a pre-train model. When I commented from backdoor import *, the model is training. But it might be desired for other tasks.

KevinLi43 commented 2 years ago

Hi there,

Thanks for this great survey. It is informative and provides lots of insights. Thanks a lot for opensource this toolbox. However, when I tried to play with it, I encountered a ModuleNotFoundError.

I have installed all requirements and optional requirements. Then when I attempted to train a model on cifar10 using

python train.py --config configs/cifar10/train_configs/resnet.yaml

I encountered a ModuleNotFoundError as follows,

Traceback (most recent call last):
  File "train.py", line 14, in <module>
    from wrt.classifiers import PyTorchClassifier
  File "/PyWorkSpace/WRT/wrt/__init__.py", line 8, in <module>
    from wrt import attacks
  File "/PyWorkSpace/WRT/wrt/attacks/__init__.py", line 6, in <module>
    from wrt.attacks.removal.fine_tuning import FTLLAttack, FTALAttack, RTLLAttack, RTALAttack, FineTuningAttack
  File "/PyWorkSpace/WRT/wrt/attacks/removal/__init__.py", line 10, in <module>
    from .regularization import Regularization
  File "/PyWorkSpace/WRT/wrt/attacks/removal/regularization.py", line 37, in <module>
    from wrt.defenses import Watermark
  File "/PyWorkSpace/WRT/wrt/defenses/__init__.py", line 5, in <module>
    from backdoor import *
ModuleNotFoundError: No module named 'backdoor'

I've checked wrt/defenses/ and all possible places and could not find this backdoor.

I appreciate it if you can help me with this issue.

Best, MENG2010

Looks like that backdoor is not needed for training a pre-train model. When I commented from backdoor import *, the model is training. But it might be desired for other tasks.

hello,when i trained embed.py to embed a content watermark in to the cifar10 model, it throwed the following error : "nll_loss_forward_reduce_cuda_kernel_2d_index" not implemented for 'float', it seems to occured when implementing the loss function nll_loss, but i have no idea how to solve it. Have you ever encountered this error when embedding watermarks? Any reply will be appreciated!