The dependency set looks deliberately light, so this may be a documentation gap rather than a bug.
Setup: v2.1.6 at 4dbf980, fresh pip install -e ".[all]" into a clean Python 3.11 venv.
examples/qwen_image/model_inference/Qwen-Image-In-Context-Control-Union.py fails at the annotator:
File ".../diffsynth/utils/controlnet/annotator.py", line 28, in __init__
from controlnet_aux.processor import OpenposeDetector
ModuleNotFoundError: No module named 'controlnet_aux'
annotator.py imports controlnet_aux seven times, one per detector, but I couldn't find it in pyproject.toml under [project.dependencies] or any extra, nor in README.md or docs/. Six example files construct an Annotator — four under examples/flux/ (FLEX.2-preview.py and FLUX.1-dev-Controlnet-Union-alpha.py, each in model_inference and model_inference_low_vram) and two under examples/qwen_image/ — so as far as I can tell none of them runs after pip install -e ".[all]".
The imports are inside __init__, so this only appears when Annotator is used; import diffsynth is unaffected.
After pip install controlnet_aux, the same script gets further and stops on a second missing package:
File ".../controlnet_aux/open_pose/util.py", line 127, in draw_handpose
import matplotlib
ModuleNotFoundError: No module named 'matplotlib'
That one is controlnet_aux's own lazy import rather than anything here, but it's needed in practice for the openpose path. With both installed, both In-Context-Control-Union scripts run and produce output.
My question: would you like these declared, say a controlnet extra carrying controlnet_aux (and matplotlib) folded into all, or would you rather keep them out of the install and note them next to the ControlNet examples? I'm happy to send a PR once you've picked, since the naming and grouping are yours to decide; #1426 and #1349 looked like similar packaging questions.
The dependency set looks deliberately light, so this may be a documentation gap rather than a bug.
Setup: v2.1.6 at
4dbf980, freshpip install -e ".[all]"into a clean Python 3.11 venv.examples/qwen_image/model_inference/Qwen-Image-In-Context-Control-Union.pyfails at the annotator:annotator.pyimportscontrolnet_auxseven times, one per detector, but I couldn't find it inpyproject.tomlunder[project.dependencies]or any extra, nor inREADME.mdordocs/. Six example files construct anAnnotator— four underexamples/flux/(FLEX.2-preview.pyandFLUX.1-dev-Controlnet-Union-alpha.py, each inmodel_inferenceandmodel_inference_low_vram) and two underexamples/qwen_image/— so as far as I can tell none of them runs afterpip install -e ".[all]".The imports are inside
__init__, so this only appears whenAnnotatoris used;import diffsynthis unaffected.After
pip install controlnet_aux, the same script gets further and stops on a second missing package:That one is
controlnet_aux's own lazy import rather than anything here, but it's needed in practice for the openpose path. With both installed, both In-Context-Control-Union scripts run and produce output.My question: would you like these declared, say a
controlnetextra carryingcontrolnet_aux(andmatplotlib) folded intoall, or would you rather keep them out of the install and note them next to the ControlNet examples? I'm happy to send a PR once you've picked, since the naming and grouping are yours to decide; #1426 and #1349 looked like similar packaging questions.