OpenBackdoor
OpenBackdoor copied to clipboard
An open-source toolkit for textual backdoor attack and defense (NeurIPS 2022 D&B, Spotlight)
Hello, I used RAP for defense on sst-2, but the experimental result was very poor, the FAR was close to 1.0, may I ask if it is normal? If it...
Hi, I was trying to launch StyleBkd using OpenBackdoor but always ended up with the following error report: File "[CWD]/OpenBackdoor/openbackdoor/attackers/__init__.py", line 24, in load_attacker return ATTACKERS[config["name"].lower()](**config) File "[CWD]/OpenBackdoor/openbackdoor/attackers/attacker.py", line 42,...
In the datasets folder, while running the command bash **download_text_classification.sh** and **download_sentiment_analysis.sh** about **imdb**, I am getting Error 404. please solve this problem,thank you very much
I was playing with the demo.py and changed attackers: attacker = ob.Attacker(poisoner={"name": "lws"}) However, it gave me a KeyError: 'lws'. I found that lws is not in the directory 'poisoner'....
Here is the code I'm trying to run (a slight modification version of the demo provided): ```python import openbackdoor as ob from openbackdoor import load_dataset victim = ob.PLMVictim(model="bert", path="bert-base-uncased") attacker...
When I import openbackdoor after running ```python setup.py install```, ImportError occurs: ImportError: packaging>=20.0 is required for a normal functioning of this module, but found packaging==19.2. Try: pip install transformers -U...
In openbackdoor/data/lws_utils.py line 130 no longer works. OpenHowNet no longer accepts structured or lang keywords. Line 134 also breaks. The subtrees of sememe_tree does not have the keys "word" or...
None of the dependencies in requirements.txt specify a version number. In addition, some dependencies do not appear in requirements.txt, such as OpenHowNet. Can you provide a more complete requirements.txt?
Hello! Can there be some comments for the ```/configs/bae_config.json```? Any guide or comments will be of great help. Specifically for the ```https://github.com/thunlp/OpenBackdoor/blob/main/configs/base_config.json#L62``` and the ```https://github.com/thunlp/OpenBackdoor/blob/main/configs/base_config.json#L62```? It is confusing whether it...
Upon running the ```python demo_attack.py --config_path /configs/neuba_config.json```, there's the following error: ``` File "demo_attack.py", line 61, in main(config) File "demo_attack.py", line 42, in main backdoored_model = attacker.attack(victim, poison_dataset) File "/attackers/neuba_attacker.py",...