Beom0 commited on
Commit
d647e79
1 Parent(s): 0ea5627

Update README.md

Browse files
Files changed (1) hide show
  1. README.md +62 -3
README.md CHANGED
@@ -1,3 +1,62 @@
1
- ---
2
- license: cc-by-4.0
3
- ---
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ---
2
+ license: cc-by-4.0
3
+ language:
4
+ - en
5
+ pipeline_tag: image-segmentation
6
+ library_name: zim-anything
7
+ tags:
8
+ - matting
9
+ - segmentation
10
+ - segment anything
11
+ - zero-shot matting
12
+ ---
13
+
14
+ # ZIM-Anything-ViTB
15
+
16
+ ## Introduction
17
+ Zero-Shot Image Matting
18
+
19
+ ## Installation
20
+
21
+ ```bash
22
+ pip install zim_anything
23
+ ```
24
+
25
+ or
26
+
27
+ ```bash
28
+ git clone https://github.com/naver-ai/ZIM.git
29
+ cd ZIM; pip install -e .
30
+ ```
31
+
32
+
33
+ ## Usage
34
+
35
+ Download the [model](https://huggingface.co/depth-anything/Depth-Anything-V2-Large/resolve/main/depth_anything_v2_vitl.pth?download=true) first and put it under the `results` directory.
36
+
37
+ ```python
38
+ from zim_anything import zim_model_registry, ZimPredictor
39
+
40
+ backbone = "vit_b"
41
+ ckpt_p = "results/zim_vit_b_2043"
42
+
43
+ model = zim_model_registry[backbone](checkpoint=ckpt_p)
44
+ if torch.cuda.is_available():
45
+ model.cuda()
46
+
47
+ predictor = ZimPredictor(model)
48
+ predictor.set_image(<image>)
49
+ masks, _, _ = predictor.predict(<input_prompts>)
50
+ ```
51
+
52
+ ## Citation
53
+
54
+ If you find this project useful, please consider citing:
55
+
56
+ ```bibtex
57
+ @article{kim2024zim,
58
+ title={ZIM: Zero-Shot Image Matting for Anything},
59
+ author={Kim, Beomyoung and Shin, Chanyong and Jeong, Joonhyun and Jung, Hyungsik and Lee, Se-Yun and Chun, Sewhan and Hwang, Dong-Hyun and Yu, Joonsang},
60
+ journal={arXiv preprint arXiv:2411.00626},
61
+ year={2024}
62
+ }