Code Monkey home page Code Monkey logo

comfyui_segment_anything's Introduction

ComfyUI Segment Anything

This project is a ComfyUI version of https://github.com/continue-revolution/sd-webui-segment-anything. At present, only the most core functionalities have been implemented. I would like to express my gratitude to continue-revolution for their preceding work on which this is based.

example

I have ensured consistency with sd-webui-segment-anything in terms of output when given the same input.

Requirements

Please ensure that you have installed Python dependencies using the following command:

pip3 install -r requirements.txt

Models

The models will be automatically downloaded when used. You can also manually download them according to the table below. If the automatic download is slow, you can set the HTTP_PROXY and HTTPS_PROXY environment variables to use a proxy.

bert-base-uncased

You can download the model from https://huggingface.co/bert-base-uncased/tree/main into the models/bert-base-uncased folder located in the root directory of ComfyUI, like this:

ComfyUI
    models
        bert-base-uncased
            config.json
            model.safetensors
            tokenizer_config.json
            tokenizer.json
            vocab.txt

You can also skip this step. During the inference process, bert-base-uncased will be automatically downloaded through the transformers library, and its directory is typically ~/.cache/huggingface/hub/models--bert-base-uncased.

GroundingDino

Please directly download the models and configuration files to the models/grounding-dino directory under the ComfyUI root directory, without modifying the file names.

name size config file model file
GroundingDINO_SwinT_OGC 694MB download link download link
GroundingDINO_SwinB 938MB download link download link

SAM

Please directly download the model files to the models/sams directory under the ComfyUI root directory, without modifying the file names.

name size model file
sam_vit_h 2.56GB download link
sam_vit_l 1.25GB download link
sam_vit_b 375MB download link
sam_hq_vit_h 2.57GB download link
sam_hq_vit_l 1.25GB download link
sam_hq_vit_b 379MB download link
mobile_sam 39MB download link

Contribution

Thank you for considering to help out with the source code! Welcome contributions from anyone on the internet, and are grateful for even the smallest of fixes!

If you'd like to contribute to this project, please fork, fix, commit and send a pull request for me to review and merge into the main code base.

comfyui_segment_anything's People

Contributors

storyicon avatar frantic avatar allinws avatar anson2048 avatar antoinedelplace avatar guilhermep avatar hiowenluke avatar dnl13 avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.