florence2 nodes support MiaoshouAI/Florence-2-large-PromptGen-v1.5 and MiaoshouAI/Florence-2-base-PromptGen-v1.5
This commit is contained in:
@@ -107,7 +107,8 @@ When this error has occurred, please check the network environment.
|
||||
## Update
|
||||
<font size="4">**If the dependency package error after updating, please double clicking ```repair_dependency.bat``` (for Official ComfyUI Protable) or ```repair_dependency_aki.bat``` (for ComfyUI-aki-v1.x) in the plugin folder to reinstall the dependency packages. </font><br />
|
||||
|
||||
|
||||
* [Florence2Ultra](#Florence2Ultra), [Florence2Image2Prompt](#Florence2Image2Prompt) 和 [LoadFlorence2Model](#LoadFlorence2Model) nodes support the MiaoshouAI/Florence-2-large-PromptGen-v1.5 and MiaoshouAI/Florence-2-base-PromptGen-v1.5 model.
|
||||
Download model files from [BaiduNetdisk](https://pan.baidu.com/s/1xOL6x6LijIMSh_3woErjJg?pwd=t3xa) or [huggingface.co/MiaoshouAI/Florence-2-large-PromptGen-v1.5](https://huggingface.co/MiaoshouAI/Florence-2-large-PromptGen-v1.5/tree/main) and [huggingface.co/MiaoshouAI/Florence-2-base-PromptGen-v1.5](https://huggingface.co/MiaoshouAI/Florence-2-base-PromptGen-v1.5/tree/main) , copy to ```ComfyUI\models\florence2``` folder.
|
||||
* Commit [BiRefNetUltraV2](#BiRefNetUltraV2) and [LoadBiRefNetModel](#LoadBiRefNetModel) nodes, that support the use of the latest BiRefNet model.
|
||||
Download model file from [BaiduNetdisk](https://pan.baidu.com/s/12z3qUuqag3nqpN2NJ5pSzg?pwd=ek65) or [GoogleDrive](https://drive.google.com/drive/folders/1s2Xe0cjq-2ctnJBR24563yMSCOu4CcxM) named ```BiRefNet-general-epoch_244.pth``` to ```ComfyUI/Models/BiRefNet/pth``` folder. You can also download more BiRefNet models and put them here.
|
||||
* [ExtendCanvasV2](#ExtendCanvasV2) node support negative value input, it means image will be cropped.
|
||||
|
||||
+3
-1
@@ -102,13 +102,15 @@ git clone https://github.com/chflame163/ComfyUI_LayerStyle.git
|
||||
* 在ComfyUI画布点击右键 - Add Node, 找到 "😺dzNodes"。
|
||||

|
||||
|
||||
* 或者在ComfyUI画布双击, 在搜索框输入"layer"。
|
||||
* 或者在ComfyUI画布双击, 在搜索框输入"layer"。Florence2Image2Prompt
|
||||

|
||||
|
||||
|
||||
## 更新说明
|
||||
<font size="4">**如果本插件更新后出现依赖包错误,请双击运行插件目录下的```install_requirements.bat```(官方便携包),或 ```install_requirements_aki.bat```(秋叶整合包) 重新安装依赖包。
|
||||
|
||||
* [Florence2Ultra](#Florence2Ultra), [Florence2Image2Prompt](#Florence2Image2Prompt) 和 [LoadFlorence2Model](#LoadFlorence2Model) 节点支持MiaoshouAI/Florence-2-large-PromptGen-v1.5 和 MiaoshouAI/Florence-2-base-PromptGen-v1.5 模型。
|
||||
请从[百度网盘](https://pan.baidu.com/s/1xOL6x6LijIMSh_3woErjJg?pwd=t3xa) 或者 [huggingface.co/MiaoshouAI/Florence-2-large-PromptGen-v1.5](https://huggingface.co/MiaoshouAI/Florence-2-large-PromptGen-v1.5/tree/main) 以及[huggingface.co/MiaoshouAI/Florence-2-base-PromptGen-v1.5](https://huggingface.co/MiaoshouAI/Florence-2-base-PromptGen-v1.5/tree/main) 下载全部模型文件并放到 ```ComfyUI\models\florence2```文件夹。
|
||||
* 添加 [BiRefNetUltraV2](#BiRefNetUltraV2) 和 [LoadBiRefNetModel](#LoadBiRefNetModel) 节点,支持使用最新的BiRefNet模型。
|
||||
从[百度网盘](https://pan.baidu.com/s/12z3qUuqag3nqpN2NJ5pSzg?pwd=ek65) 或 [GoogleDrive](https://drive.google.com/drive/folders/1s2Xe0cjq-2ctnJBR24563yMSCOu4CcxM) 下载 ```BiRefNet-general-epoch_244.pth``` 到 ComfyUI/Models/BiRefNet/pth 文件夹。也可以下载更多的BiRefNet模型放到这里。
|
||||
* [ExtendCanvasV2](#ExtendCanvasV2) 节点支持负值输入,负值将被裁剪。
|
||||
|
||||
@@ -45,7 +45,7 @@ class LS_LoadBiRefNetModel:
|
||||
from .BiRefNet.utils import check_state_dict
|
||||
model_dict = get_models()
|
||||
self.birefnet = BiRefNet(bb_pretrained=False)
|
||||
self.state_dict = torch.load(model_dict[model], map_location='cpu')
|
||||
self.state_dict = torch.load(model_dict[model], map_location='cpu', weights_only=True)
|
||||
self.state_dict = check_state_dict(self.state_dict)
|
||||
self.birefnet.load_state_dict(self.state_dict)
|
||||
return (self.birefnet,)
|
||||
|
||||
@@ -22,7 +22,8 @@ fl2_model_repos = {
|
||||
"base-PromptGen": "MiaoshouAI/Florence-2-base-PromptGen",
|
||||
"CogFlorence-2-Large-Freeze": "thwri/CogFlorence-2-Large-Freeze",
|
||||
"CogFlorence-2.1-Large": "thwri/CogFlorence-2.1-Large",
|
||||
"base-PromptGen-v1.5":"MiaoshouAI/Florence-2-base-PromptGen-v1.5"
|
||||
"base-PromptGen-v1.5":"MiaoshouAI/Florence-2-base-PromptGen-v1.5",
|
||||
"large-PromptGen-v1.5":"MiaoshouAI/Florence-2-large-PromptGen-v1.5"
|
||||
}
|
||||
|
||||
|
||||
|
||||
+1
-1
@@ -1405,7 +1405,7 @@ def load_RMBG_model():
|
||||
model_path = os.path.join(folder_paths.models_dir, "rmbg", "RMBG-1.4", "model.pth")
|
||||
if not os.path.exists(model_path):
|
||||
model_path = os.path.join(os.path.dirname(current_directory), "RMBG-1.4", "model.pth")
|
||||
net.load_state_dict(torch.load(model_path, map_location=device))
|
||||
net.load_state_dict(torch.load(model_path, map_location=device, weights_only=True))
|
||||
net.to(device)
|
||||
net.eval()
|
||||
return net
|
||||
|
||||
+1
-1
@@ -1,7 +1,7 @@
|
||||
[project]
|
||||
name = "comfyui_layerstyle"
|
||||
description = "A set of nodes for ComfyUI it generate image like Adobe Photoshop's Layer Style. the Drop Shadow is first completed node, and follow-up work is in progress."
|
||||
version = "1.0.52"
|
||||
version = "1.0.53"
|
||||
license = "MIT"
|
||||
dependencies = ["numpy", "pillow", "torch", "matplotlib", "Scipy", "scikit_image", "opencv-contrib-python", "pymatting", "segment_anything", "timm", "addict", "yapf", "colour-science", "wget", "mediapipe", "loguru", "typer_config", "fastapi", "rich", "google-generativeai", "diffusers", "omegaconf", "tqdm", "transformers", "kornia", "image-reward", "ultralytics", "blend_modes", "blind-watermark", "qrcode", "pyzbar", "transparent-background", "huggingface_hub", "accelerate", "bitsandbytes", "torchscale", "wandb", "hydra-core", "psd-tools", "inference-cli[yolo-world]", "inference-gpu[yolo-world]", "onnxruntime"]
|
||||
|
||||
|
||||
Reference in New Issue
Block a user