ly17 commited on
Commit
59b8193
·
verified ·
1 Parent(s): 976f493

Create README.md

Browse files
Files changed (1) hide show
  1. README.md +82 -0
README.md ADDED
@@ -0,0 +1,82 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ---
2
+ license: apache-2.0
3
+ tags:
4
+ - medical-imaging
5
+ - image-segmentation
6
+ - semi-supervised-learning
7
+ - sam3
8
+ - angiography
9
+ - mean-teacher
10
+ - pytorch
11
+ ---
12
+
13
+ # SMART: Semi-supervised Medical Adaptive vessel Representation Toolkit
14
+
15
+ [![Hugging Face Paper](https://img.shields.io/badge/%F0%9F%A4%97%20Hugging%20Face-Paper-blue)](https://huggingface.co/papers/2603.00881)
16
+ [![arXiv](https://img.shields.io/badge/arXiv-2603.00881-b31b1b.svg)](https://arxiv.org/abs/2603.00881)
17
+ [![GitHub](https://img.shields.io/badge/GitHub-Repository-black)](https://github.com/qimingfan10/SMART)
18
+
19
+ This repository hosts the official pre-trained and fine-tuned model checkpoints for the paper **SMART** (arXiv:2603.00881).
20
+
21
+ SMART is a semi-supervised video vessel segmentation framework built on **SAM3 (Segment Anything Model 3)**. It features a Mean Teacher architecture and text prompt support, specifically designed for efficient coronary angiography vessel segmentation.
22
+
23
+ ## 🗂️ Model Weights Overview
24
+
25
+ We provide all necessary weights to reproduce our experiments, from the original baselines to our final semi-supervised checkpoints:
26
+
27
+ | Filename | Size | Description |
28
+ | :--- | :--- | :--- |
29
+ | `sam2.1_hiera_large.pt` | 898 MB | Original SAM 2.1 Hiera Large baseline weights. |
30
+ | `sam3_original.pt` | 3.45 GB | Original SAM 3 baseline weights. |
31
+ | `sam3_1p_finetune_checkpoint_100.pt` | 10.1 GB | Supervised fine-tuning checkpoint trained using only 1% labeled data (100 epochs). |
32
+ | `semi_sam3_5labeled_checkpoint_final.pt` | 10.6 GB | **Final SMART checkpoint** trained via semi-supervised learning (Mean Teacher) with 5% labeled data. |
33
+ | `bpe_simple_vocab_16e6.txt.gz` | 1.36 MB | BPE vocabulary file required for the text prompt tokenizer. |
34
+
35
+ ## 🚀 How to Use
36
+
37
+ You can easily download these weights using the `huggingface_hub` library and integrate them directly into the SMART training/inference pipeline.
38
+
39
+ ### 1. Install Dependencies
40
+ ```bash
41
+ pip install huggingface_hub torch torchvision
42
+
43
+ ```
44
+
45
+ ### 2. Download and Load Checkpoints
46
+
47
+ Here is an example of how to download the final SMART checkpoint and load it into your PyTorch environment:
48
+
49
+ ```python
50
+ from huggingface_hub import hf_hub_download
51
+ import torch
52
+
53
+ # 1. Download the final semi-supervised checkpoint
54
+ ckpt_path = hf_hub_download(
55
+ repo_id="ly17/TC-SemiSAM-checkpoints",
56
+ filename="semi_sam3_5labeled_checkpoint_final.pt"
57
+ )
58
+ print(f"Weights downloaded to: {ckpt_path}")
59
+
60
+ # 2. Load the state dict
61
+ # state_dict = torch.load(ckpt_path, map_location="cpu")
62
+ # model.load_state_dict(state_dict)
63
+
64
+ ```
65
+
66
+ ### 3. Text Prompt Setup
67
+
68
+ When running inference with our SMART model, please ensure you use the following default text prompt as specified in our methodology:
69
+
70
+ ```python
71
+ TEXT_PROMPT = "Please segment the blood vessels"
72
+
73
+ ```
74
+
75
+ *(Note: The model expects a dataset resolution of 512×512, which is resized to a SAM3 input resolution of 1008×1008 with normalization range [-1, 1].)*
76
+
77
+ ## ⚠️ Clinical Disclaimer
78
+
79
+ These models are released for **research purposes only**. They are not intended for direct clinical decision-making, patient diagnosis, or treatment planning.
80
+
81
+
82
+ ```