Skip to content

Commit d50a8a5

Browse files
Merge pull request #159 from computational-cell-analytics/cosmetics
Precompute embeddings in 2d example; set default box extension to 0.0…
2 parents aa03b3b + 5cdc882 commit d50a8a5

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

examples/annotator_2d.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ def hela_2d_annotator(use_finetuned_model):
3434
embedding_path = "./embeddings/embeddings-hela2d.zarr"
3535
model_type = "vit_h"
3636

37-
annotator_2d(image, embedding_path, show_embeddings=False, model_type=model_type)
37+
annotator_2d(image, embedding_path, show_embeddings=False, model_type=model_type, precompute_amg_state=True)
3838

3939

4040
def wholeslide_annotator(use_finetuned_model):

micro_sam/sam_annotator/annotator_3d.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -154,7 +154,7 @@ def _segment_slice_wigdet(v: Viewer) -> None:
154154

155155
@magicgui(call_button="Segment Volume [V]", projection={"choices": ["default", "bounding_box", "mask", "points"]})
156156
def _segment_volume_widget(
157-
v: Viewer, iou_threshold: float = 0.8, projection: str = "default", box_extension: float = 0.1
157+
v: Viewer, iou_threshold: float = 0.8, projection: str = "default", box_extension: float = 0.05
158158
) -> None:
159159
# step 1: segment all slices with prompts
160160
shape = v.layers["raw"].data.shape

0 commit comments

Comments
 (0)