Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Mask from automatic mask generator with batch mode not working #222

Open
Niro4 opened this issue Dec 1, 2023 · 0 comments
Open

Mask from automatic mask generator with batch mode not working #222

Niro4 opened this issue Dec 1, 2023 · 0 comments
Labels
bug Something isn't working

Comments

@Niro4
Copy link

Niro4 commented Dec 1, 2023

Environment Information

  • samgeo version: 0.10.1
  • Python version: 3.11.5
  • Operating System: Windows 11

Description

I was generating a mask for a large image using batch mode. I expected to get a segmentation of the shrubs in the image. The resulting mask has a patch where the segmentation follows the expectation, but the rest of the mask is wrong.

Image:

Mask:

What I Did

The following is the code I ran to generate the mask:

model = SamGeo(
  model_type="vit_h",
  automatic=True,
  device=None,
  checkpoint_dir=None,
  sam_kwargs=None
)
model.generate(
  input_tif_path,
  output="mask.tif",
  foreground=True,
  unique=True,
  batch=True,
)
@Niro4 Niro4 added the bug Something isn't working label Dec 1, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant