Open w4ffl35 opened 8 months ago
It appears that some of this is already solved in a recent PR, however when I install from main it says I'm on version 0.0.6 rather than something higher than 0.0.7. Additionally the load_processor function does not respect the flag so I will be fixing that and the version.
Describe the bug
There is no way to pass the local_files_only flag to the controlnet Processor
load_processor
function (seecontrolnet_aux/processor.py
)Code:
That function in-turn calls things such as
LeresDetector.from_pretrained
which looks like thisLeresDetector.from_pretrained
in-turn callshf_hub_download
in order to download the model if the path is not a folder.hf_hub_download
takes alocal_files_only
flag, however it is not being passed here.Because of this, the hub attempts to access huggingface.co which causes the application to hang when offline.
Proposed fix
Add a local_files_only flag to the Processor and each controlnet class
Reproduction
Attempt to initialize a processor using the
load_processor
function without an internet connection and see the script hang.Logs
No response
System Info
controlnet_aux >=0.0.7