Open derekleighstark opened 1 year ago
Getting the same error with Pytorch 1.13.0 and Python 3.10.8 on Windows 10.
I got the same error. But following the instruction like this ""F:\Projects\stable-diffusion-webui\venv\Scripts\Python.exe" pickle_scan.py models > scan_output.txt" fixes my problem.
@wongfei2009 I tried this doing this but got the same error still....
pytorch 1.13.0 breaks custom unpickle modules.
I got the same error. But following the instruction like this ""F:\Projects\stable-diffusion-webui\venv\Scripts\Python.exe" pickle_scan.py models > scan_output.txt" fixes my problem.
This fixed it for me too! thank you kind sir for helping me not get pickled
Same happens to me after following these instructions to improve performance on my 4090 which, indeed, replaced pytorch with 1.13.1
https://github.com/pytorch/pytorch/commit/9f11ce7f67612d1c11f1a6a9b264779b27062e82 The commit in pytorch may solve the issue. We can use the master branch of pytorch or wait for the future release.
Changing result.calls to result_calls fixed the issue for me.
Seeing a lot of conflicting issues and solutions here, will have to test.
For those running on macOS or Linux, you should use this version of the command that @wongfei2009 offered, assuming that you are in the AUTOMATIC1111 (aka stable-diffusion-webui) base directory:
$ ./venv/bin/python3 pickle_scan.py models >scan_output.txt
and for everyone, don't forget to scan your embeddings
folder as well, since it does not live under models
:
$ ./venv/bin/python3 pickle_scan.py embeddings >embeddings_scan.txt
getting this error --
H:\stabledif\stable-diffusion-webui>cmd /C "H:\stabledif\stable-diffusion-webui\venv\Scripts\Python.exe" pickle_scan.py models 1>scan_output.txt
Traceback (most recent call last):
File "H:\stabledif\stable-diffusion-webui\pickle_scan.py", line 37, in <module>
for c in result.calls:
AttributeError: 'dict' object has no attribute 'calls'
if I change results.call to results_call the scan fails
Changing result.calls to result_calls fixed the issue for me.
Making this change fixed it for me also
Changing result.calls to result_calls fixed the issue for me.
Making this change fixed it for me also
That worked for me, too. But now my results say for all my models:
library call (net.): 0 library call (shutil.): 0 library call (sys.): 0 library call (requests.): 0 library call (os.): 0 malicious signal (cat ): 0 malicious signal (rm ): 0 malicious signal (/bin/sh ): 0 malicious signal (nc ): 0 non-standard calls: 5 total: 5
SCAN FAILED
I'm worried. Should I be?
pytorch/pytorch@9f11ce7 The commit in pytorch may solve the issue. We can use the master branch of pytorch or wait for the future release.
This resolved the issue for me. Just manually edited torch/serialization.py
pytorch/pytorch@9f11ce7 The commit in pytorch may solve the issue. We can use the master branch of pytorch or wait for the future release.
This resolved the issue for me. Just manually edited torch/serialization.py
I this also fixed the issue for me.
pytorch/pytorch@9f11ce7 The commit in pytorch may solve the issue. We can use the master branch of pytorch or wait for the future release.
This resolved the issue for me. Just manually edited torch/serialization.py
Are you able to explain more on what to do. I am getting the error, but don't fully understand what to do to correct it.
Error:
"Scanning...Please wait a moment..."
"step 1: SD models folder"
Traceback (most recent call last):
File "H:\stabledif\stable-diffusion-webui\pickle_scan.py", line 37, in
Changing result.calls to result_calls fixed the issue for me.
By doing so l.37 of pickle_scan.py is gonna loop around the empty result_calls instead of looping on the result given by the pickle_inspector. (At least that's what my old rusty python skills are telling me, correct me if I'm wrong). So yeah it's gonna silence the error.... But it won't fix anything. I'm still looking for a fix myself, just letting others know that this is probably not a correct one.
EDIT : Editing torch's serialization.py file like mentioned above does fix the issue however.
(base) PS G:\stable-diffusion-webui> python pickle_scan.py models > scan_output.txt Traceback (most recent call last): File "G:\stable-diffusion-webui\pickle_scan.py", line 35, in
for c in result.calls:
AttributeError: 'dict' object has no attribute 'calls'
Getting this error when I run things.