Skip to content

Commit

Permalink
Temp remove 3D-pack & major upgrade
Browse files Browse the repository at this point in the history
  • Loading branch information
YanWenKun committed Sep 7, 2024
1 parent 78ee896 commit a4680bf
Show file tree
Hide file tree
Showing 5 changed files with 5 additions and 83 deletions.
4 changes: 0 additions & 4 deletions generate-requirements.sh
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,6 @@ array=(
https://raw.githubusercontent.com/comfyanonymous/ComfyUI/master/requirements.txt
https://raw.githubusercontent.com/crystian/ComfyUI-Crystools/main/requirements.txt
https://raw.githubusercontent.com/cubiq/ComfyUI_essentials/main/requirements.txt
https://raw.githubusercontent.com/cubiq/ComfyUI_FaceAnalysis/main/requirements.txt
https://raw.githubusercontent.com/cubiq/ComfyUI_InstantID/main/requirements.txt
https://raw.githubusercontent.com/Fannovel16/comfyui_controlnet_aux/main/requirements.txt
https://raw.githubusercontent.com/Fannovel16/ComfyUI-Frame-Interpolation/main/requirements-no-cupy.txt
https://raw.githubusercontent.com/FizzleDorf/ComfyUI_FizzNodes/main/requirements.txt
Expand All @@ -32,9 +30,7 @@ https://raw.githubusercontent.com/ltdrdata/ComfyUI-Impact-Subpack/main/requireme
https://raw.githubusercontent.com/ltdrdata/ComfyUI-Inspire-Pack/main/requirements.txt
https://raw.githubusercontent.com/ltdrdata/ComfyUI-Manager/main/requirements.txt
https://raw.githubusercontent.com/melMass/comfy_mtb/main/requirements.txt
https://raw.githubusercontent.com/MrForExample/ComfyUI-3D-Pack/main/requirements.txt
https://raw.githubusercontent.com/storyicon/comfyui_segment_anything/main/requirements.txt
https://raw.githubusercontent.com/ZHO-ZHO-ZHO/ComfyUI-InstantID/main/requirements.txt
)

for line in "${array[@]}";
Expand Down
21 changes: 0 additions & 21 deletions requirements.txt
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
accelerate
addict
aiohttp
albumentations
Expand All @@ -9,61 +8,44 @@ colour-science
compel
cupy-cuda12x
deepdiff
diffusers
einops
fairscale
filelock
ftfy
fvcore
GitPython
gpytoolbox
huggingface-hub
imageio
imageio-ffmpeg
importlib-metadata
jaxtyping
joblib
kornia
lark
matplotlib==3.8
matrix-client==0.4.0
mediapipe
mss
nerfacc
ninja
numba
numexpr
numpy<2
omegaconf
onnxruntime
open-clip-torch
opencv-contrib-python
opencv-python
opencv-python-headless
packaging
pandas
piexif
pilgram
pillow
plyfile
psutil
py-cpuinfo
pygit2
PyGithub
pygltflib
pyhocon
PyMCubes
pymeshlab
pynvml
python-dateutil
python-ffmpeg
pytorch-lightning
pytorch-msssim
pyyaml
qrcode[pil]
regex
rembg
requests
requirements-parser
rich
rich-argparse
Expand All @@ -74,7 +56,6 @@ scipy
segment-anything
sentencepiece
simpleeval
slangtorch
soundfile
spandrel
svglib
Expand All @@ -85,7 +66,6 @@ torchaudio
torchdiffeq
torchmetrics
torchsde
torchtyping
torchvision
tqdm
transformers
Expand All @@ -94,6 +74,5 @@ trimesh[easy]
typer
typing-extensions
ultralytics!=8.2.87
xatlas
yacs
yapf
8 changes: 0 additions & 8 deletions requirements2.txt
Original file line number Diff line number Diff line change
@@ -1,9 +1 @@
https://raw.githubusercontent.com/z-mahmud22/Dlib_Windows_Python3.x/main/dlib-19.24.1-cp311-cp311-win_amd64.whl
https://raw.githubusercontent.com/Gourieff/Assets/main/Insightface/insightface-0.7.3-cp311-cp311-win_amd64.whl
gradio
gradio-client
pixeloe
git+https://github.com/openai/CLIP.git
git+https://github.com/WASasquatch/cstr
git+https://github.com/WASasquatch/ffmpy.git
git+https://github.com/WASasquatch/img2texture.git
38 changes: 5 additions & 33 deletions stage1.sh
Original file line number Diff line number Diff line change
Expand Up @@ -10,25 +10,13 @@ export PYTHONPYCACHEPREFIX="$workdir"/pycache
ls -lahF

# Setup Python embeded, part 1/3
curl https://www.python.org/ftp/python/3.11.9/python-3.11.9-embed-amd64.zip \
curl https://www.python.org/ftp/python/3.12.6/python-3.12.6-embed-amd64.zip \
-o python_embeded.zip
unzip python_embeded.zip -d "$workdir"/python_embeded

# ComfyUI-3D-Pack, part 1/2
$gcs https://github.com/MrForExample/Comfy3D_Pre_Builds.git \
"$workdir"/Comfy3D_Pre_Builds

mv \
"$workdir"/Comfy3D_Pre_Builds/_Python_Source_cpp/py311/include \
"$workdir"/python_embeded/include

mv \
"$workdir"/Comfy3D_Pre_Builds/_Python_Source_cpp/py311/libs \
"$workdir"/python_embeded/libs

# Setup Python embeded, part 2/3
cd "$workdir"/python_embeded
echo 'import site' >> ./python311._pth
echo 'import site' >> ./python312._pth
curl https://bootstrap.pypa.io/get-pip.py -o get-pip.py
./python.exe get-pip.py

Expand All @@ -37,8 +25,8 @@ curl https://bootstrap.pypa.io/get-pip.py -o get-pip.py
--upgrade pip wheel setuptools Cython cmake

./python.exe -s -m pip install \
xformers torchvision torchaudio \
--index-url https://download.pytorch.org/whl/cu121 \
torch torchvision torchaudio \
--index-url https://download.pytorch.org/whl/cu124 \
--extra-index-url https://pypi.org/simple

./python.exe -s -m pip install \
Expand All @@ -56,24 +44,8 @@ curl https://bootstrap.pypa.io/get-pip.py -o get-pip.py
&& ./python.exe -s -m pip install \
mediapipe

# ComfyUI-3D-Pack, part 2/2
./python.exe -s -m pip install \
"$workdir"/Comfy3D_Pre_Builds/_Build_Wheels/_Wheels_win_py311_cu121/*.whl

# From: https://github.com/rusty1s/pytorch_scatter?tab=readme-ov-file#binaries
./python.exe -s -m pip install \
torch-scatter -f https://data.pyg.org/whl/torch-2.3.0+cu121.html

rm -rf "$workdir"/Comfy3D_Pre_Builds

# Add Ninja binary (replacing PIP one)
curl -L https://github.com/ninja-build/ninja/releases/latest/download/ninja-win.zip \
-o ninja-win.zip
unzip -o ninja-win.zip -d "$workdir"/python_embeded/Scripts
rm ninja-win.zip

# Setup Python embeded, part 3/3
sed -i '1i../ComfyUI' ./python311._pth
sed -i '1i../ComfyUI' ./python312._pth

./python.exe -s -m pip list

Expand Down
17 changes: 0 additions & 17 deletions stage2.sh
Original file line number Diff line number Diff line change
Expand Up @@ -48,11 +48,9 @@ $gcs https://github.com/shiimizu/ComfyUI_smZNodes.git
$gcs https://github.com/Suzie1/ComfyUI_Comfyroll_CustomNodes.git

# Control
$gcs https://github.com/cubiq/ComfyUI_InstantID.git
$gcs https://github.com/cubiq/ComfyUI_IPAdapter_plus.git
$gcs https://github.com/Fannovel16/comfyui_controlnet_aux.git
$gcs https://github.com/florestefano1975/comfyui-portrait-master.git
$gcs https://github.com/Gourieff/comfyui-reactor-node.git
$gcs https://github.com/huchenlei/ComfyUI-layerdiffuse.git
$gcs https://github.com/Kosinkadink/ComfyUI-Advanced-ControlNet.git
$gcs https://github.com/ltdrdata/ComfyUI-Impact-Pack.git
Expand All @@ -64,18 +62,13 @@ $gcs https://github.com/twri/sdxl_prompt_styler.git
# Video
$gcs https://github.com/Fannovel16/ComfyUI-Frame-Interpolation.git
$gcs https://github.com/FizzleDorf/ComfyUI_FizzNodes.git
$gcs https://github.com/Kosinkadink/ComfyUI-AnimateDiff-Evolved.git
$gcs https://github.com/Kosinkadink/ComfyUI-VideoHelperSuite.git
$gcs https://github.com/melMass/comfy_mtb.git
$gcs https://github.com/MrForExample/ComfyUI-AnimateAnyone-Evolved.git

# More
$gcs https://github.com/cubiq/ComfyUI_FaceAnalysis.git
$gcs https://github.com/MrForExample/ComfyUI-3D-Pack.git
$gcs https://github.com/pythongosssss/ComfyUI-WD14-Tagger.git
$gcs https://github.com/SLAPaper/ComfyUI-Image-Selector.git
$gcs https://github.com/ssitu/ComfyUI_UltimateSDUpscale.git
$gcs https://github.com/WASasquatch/was-node-suite-comfyui.git


cd "$workdir"
Expand All @@ -93,15 +86,6 @@ cp "$workdir"/attachments/run_nvidia_gpu.bat \

du -hd1 "$workdir"

# Download models for ReActor
cd "$workdir"/ComfyUI_Windows_portable/ComfyUI/models
curl -L https://github.com/sczhou/CodeFormer/releases/download/v0.1.0/codeformer.pth \
--create-dirs -o facerestore_models/codeformer-v0.1.0.pth
curl -L https://github.com/TencentARC/GFPGAN/releases/download/v1.3.4/GFPGANv1.4.pth \
--create-dirs -o facerestore_models/GFPGANv1.4.pth
curl -L https://huggingface.co/datasets/Gourieff/ReActor/resolve/main/models/inswapper_128_fp16.onnx \
--create-dirs -o insightface/inswapper_128_fp16.onnx

# Run test, also let custom nodes download some models
cd "$workdir"/ComfyUI_Windows_portable
./python_embeded/python.exe -s -B ComfyUI/main.py --quick-test-for-ci --cpu
Expand All @@ -112,7 +96,6 @@ rm "$workdir"/ComfyUI_Windows_portable/*.log
#rm -rf "$workdir"/ComfyUI_Windows_portable/python_embeded/Lib/site-packages/pymatting

cd "$workdir"/ComfyUI_Windows_portable/ComfyUI/custom_nodes
rm ./was-node-suite-comfyui/was_suite_config.json
rm ./ComfyUI-Manager/config.ini
rm ./ComfyUI-Impact-Pack/impact-pack.ini
rm ./ComfyUI-Custom-Scripts/pysssss.json
Expand Down

0 comments on commit a4680bf

Please sign in to comment.