• Stars
    star
    191
  • Rank 201,682 (Top 4 %)
  • Language
    Python
  • Created over 1 year ago
  • Updated 5 months ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

Low rank adaptation for segmentation anything model (SAM)

LoRA for SAM (meta's segment-anything)

Usage

from segment_anything import build_sam, SamAutomaticMaskGenerator 
from segment_anything import sam_model_registry
from sam_lora import LoRA_Sam
import torch
sam = sam_model_registry["vit_b"](checkpoint="sam_vit_b_01ec64.pth")
lora_sam = LoRA_Sam(sam,r = 4)
result = lora_sam.sam.image_encoder(torch.rand(size=(1,3,1024,1024)))
print(result.shape)

Train

Coming soon and welcome pull request.

Thanks

The code for LoRA ViT comes form https://github.com/JamesQFreeman/LoRA-ViT

More Repositories

1

LoRA-ViT

Low rank adaptation for Vision Transformer
Python
326
star
2

PointRend

an numpy-based implement of PointRend
Jupyter Notebook
204
star
3

Bloody_pressure_monitor

一个基于Arduino的血压计的开源项目。An open source sphygmomanometer develped on Arduino.
C++
53
star
4

simpleITK-Snap

A qt-based 3D data visualization tool.
Python
51
star
5

CVFPaperHelper

Automatically download multiple papers by keywords in CVPR
Python
51
star
6

MicEye

Record radiologists' eye gaze when they are labeling images.
Python
43
star
7

vit3d-pytorch

3D Vision Transformer, in PyTorch
Python
28
star
8

PyEyetracker

A python interface for the Tobii Eye Tracker
C++
17
star
9

VoxelRend

A modified pointrend for 3D medical image
Python
8
star
10

MICCAI-AUTHOR-STATS

In this project, I did a survey with all the papers in MICCAI 2010-2018 to find relation between scholars.
Jupyter Notebook
8
star
11

TenGigaRays

A very simple C++ ray tracing render.
C++
6
star
12

contrastive_learning_in_100_lines

A simple and intuitive contrastive learning implementation
Python
6
star
13

Pod

python oxford dictionary
Python
3
star
14

WTF_RequirementCheck

A tool check the requirement of TF in windows
Python
3
star
15

OpenEyeTracker

An open source solution for eye tracker hardware and software.
2
star
16

VNet-PyTorch

A flexible, elegant and parallel V-Net implement in PyTorch.
2
star
17

MeLo

Medical image Low-rank adaptation for diagnosis, segmentation and generation.
JavaScript
2
star
18

JamesQFreeman

2
star
19

SA-INR

We propose a single super-resolution network for continuous reduction of MR slice spacing
Python
1
star
20

jamesqfreeman.github.io

1
star