Ricky06662 commited on
Commit
9d6378f
·
verified ·
1 Parent(s): d148f53

Upload model files

Browse files
README.md CHANGED
@@ -28,6 +28,35 @@ from transformers import AutoModelForCausalLM, AutoTokenizer
28
  import torch
29
 
30
  # load model
31
- model = AutoModelForCausalLM.from_pretrained("Ricky06662/Seg-Zero-7B")
32
- tokenizer = AutoTokenizer.from_pretrained("Ricky06662/Seg-Zero-7B")
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
33
  ```
 
28
  import torch
29
 
30
  # load model
31
+ model = Qwen2_5_VLForConditionalGeneration.from_pretrained("Ricky06662/Seg-Zero-7B")
32
+ tokenizer = Qwen2_5_VLForConditionalGeneration.from_pretrained("Ricky06662/Seg-Zero-7B")
33
+ ```
34
+
35
+ ## Installation
36
+
37
+ ```bash
38
+ git clone https://github.com/dvlab-research/Seg-Zero.git
39
+ cd Seg-Zero
40
+ conda create -n seg_zero python=3.11
41
+ conda activate seg_zero
42
+ pip install torch==2.5.1 torchvision==0.20.1 torchaudio==2.5.1
43
+ pip install -e .
44
+ pip install sam2
45
+ pip install matplotlib
46
+ ```
47
+
48
+ ## Inference
49
+
50
+ ```bash
51
+ python inference_scripts/infer.py
52
+ ```
53
+
54
+ The default question is:
55
+
56
+ > "the unusual object in the image."
57
+
58
+ You will get the thinking process in the command line and the mask will be saved in the **inference_scripts** folder. You can also provide your own image_path and text:
59
+
60
+ ```bash
61
+ python inference_scripts/infer.py --image_path "your_image_path" --text "your question text"
62
  ```
config.json CHANGED
@@ -1,5 +1,5 @@
1
  {
2
- "_name_or_path": "/gpfs/yuqiliu/easyr1_workdir/17_run_qwen2_5_vl_7b_refcocog_add_boxl1_kl5e-3_lr1e-6_strict_format_n16/global_step_200/actor/huggingface",
3
  "architectures": [
4
  "Qwen2_5_VLForConditionalGeneration"
5
  ],
 
1
  {
2
+ "_name_or_path": "/gpfs/yuqiliu/easyr1_workdir/22_run_qwen2_5_vl_7b_refcocog_add_boxl1_kl1e-2_lr1e-6_strict_format_n8/global_step_562/actor/huggingface",
3
  "architectures": [
4
  "Qwen2_5_VLForConditionalGeneration"
5
  ],
model-00001-of-00004.safetensors CHANGED
@@ -1,3 +1,3 @@
1
  version https://git-lfs.github.com/spec/v1
2
- oid sha256:02189a5030533563cb97d46618c6084d7e128be0295c0f5f772d6ce3c68e7e49
3
- size 4871753400
 
1
  version https://git-lfs.github.com/spec/v1
2
+ oid sha256:38c48425cee36ddfd4fbbc0b2993f36f06fa4ac8e460c1b79be0b59efc953fdd
3
+ size 4888372856
model-00002-of-00004.safetensors CHANGED
@@ -1,3 +1,3 @@
1
  version https://git-lfs.github.com/spec/v1
2
- oid sha256:29462384d6a68a2a4ffa78f3428ac8f54a135b55dbc423df7b9544f376fa5d4d
3
- size 4914744112
 
1
  version https://git-lfs.github.com/spec/v1
2
+ oid sha256:139ba86b1b9750588060df19471bbcaf4735933e90e98c0433bd7d965397f591
3
+ size 4930885376
model-00003-of-00004.safetensors CHANGED
@@ -1,3 +1,3 @@
1
  version https://git-lfs.github.com/spec/v1
2
- oid sha256:a6dd4184e10f0ec424ce8c316636e0fcc1c219f2e88cd8df3054d0ec135e68a2
3
- size 4932899656
 
1
  version https://git-lfs.github.com/spec/v1
2
+ oid sha256:9d2fd346eb88c8164a9c4c34fef43aa15d9b913ae1f21d2c1d408ccd487fa992
3
+ size 4490074192
model-00004-of-00004.safetensors CHANGED
@@ -1,3 +1,3 @@
1
  version https://git-lfs.github.com/spec/v1
2
- oid sha256:97fa285dd3928ef072ce48012fe78927ba2fcf6f70d02cd397c9f19fcc2933d7
3
- size 1865017328
 
1
  version https://git-lfs.github.com/spec/v1
2
+ oid sha256:1d33376846110acadfe1735ebd6309a20235a365289a2b599b75a37c9d2a51ef
3
+ size 2275082104
model.safetensors.index.json CHANGED
The diff for this file is too large to render. See raw diff