Comments (7)
@yihong1120, thanks for your interest in EfficientSAM!
Can you give some detailed information on the hardware platform for your use case, e.g, memory constraints, latency constraints, and CPU type?
from efficientsam.
When I download to model and export to A40 GPU, seems to use 35Gb GPU memory and sam without prompt, use over than 20s.
Maybe it's too slow to use.
from efficientsam.
@WanBenLe, can you kill all the jobs you are running to check?
from efficientsam.
I used it:
efficient_sam_vits_model = build_efficient_sam_vits()
efficient_sam_vits_model.to('cuda:3')
In def predict_masks, take_along_dim will lead to out of GPU memory.
iou_predictions = torch.take_along_dim(iou_predictions, sorted_ids, dim=2)
So I have to
output_masks=output_masks.to('cpu')
iou_predictions=iou_predictions.to('cpu')
I also use cuda to run in batched_nms process_small_region.
masks = torch.cat(new_masks, dim=0).to('cuda:3')
boxes = batched_mask_to_box(masks)
keep_by_nms = batched_nms(
boxes.float(),
torch.as_tensor(scores).to('cuda:3'),
torch.zeros_like(boxes[:, 0]).to('cuda:3'), # categories
iou_threshold=nms_thresh,
)
33gb GPU Mem of model.
41gb GPU Mem of model + batched_nms.
Maybe I had something wrong?
from efficientsam.
@WanBenLe What is the input for your case?
from efficientsam.
@yformer
Image, which resize 512*512
with zipfile.ZipFile("weights/efficient_sam_vits.pt.zip", 'r') as zip_ref:
zip_ref.extractall("weights")
efficient_sam_vits_model = build_efficient_sam_vits()
efficient_sam_vits_model.to('cuda:2')
efficient_sam_vits_model.device
rle = run_everything_ours(cv2.resize(image,(512,512)), efficient_sam_vits_model)
from efficientsam.
Me too, OOM occured using v100-32G.
from efficientsam.
Related Issues (20)
- SqueezeSAM HOT 2
- CoreML HOT 2
- How to do Saliency segmentation? HOT 1
- Saliency Segment CODE WANTED HOT 3
- how to train our dataset?thanks for your answer HOT 2
- SAMI Module and Training Codes? HOT 4
- Segment Anything CPP Wrapper for macOS HOT 1
- Is there GPU support for box-prompted SAM? HOT 7
- why zero-shot instance segmentation on COCO dataset is bad HOT 1
- Is that possible using this as pretrained with LLaVa?> HOT 4
- What does input_labels mean? HOT 1
- multibox-prompt inference HOT 2
- EfficientSAM available on the Microscopy Imaging software Fiji HOT 1
- how to use background point HOT 1
- When there are multiple points as prompts (for example, more than five points), some point areas cannot be segmented. HOT 1
- pre-trained parameters
- pre-trained parameters
- Why is it slow to segment everything? Is there a good solution? HOT 1
- Is it possible to fine-tune it to extract single-category objects based only on mask prompt
- Wrong EfficientSAM model from Model_zoo
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from efficientsam.