├── .github ├── FUNDING.yml ├── README.md ├── dependabot.yml └── workflows │ └── ci.yml ├── .pre-commit-config.yaml ├── LICENSE ├── examples └── notebooks │ ├── samv2_automatic_segmentation_with_wandb_tables.ipynb │ └── samv2_prompted_segmentation_with_wandb_tables.ipynb ├── pyproject.toml ├── sam2 ├── __init__.py ├── automatic_mask_generator.py ├── build_sam.py ├── configs │ ├── __init__.py │ ├── sam2_hiera_b+.yaml │ ├── sam2_hiera_l.yaml │ ├── sam2_hiera_s.yaml │ └── sam2_hiera_t.yaml ├── modeling │ ├── __init__.py │ ├── backbones │ │ ├── __init__.py │ │ ├── hieradet.py │ │ ├── image_encoder.py │ │ └── utils.py │ ├── memory_attention.py │ ├── memory_encoder.py │ ├── position_encoding.py │ ├── sam │ │ ├── __init__.py │ │ ├── mask_decoder.py │ │ ├── prompt_encoder.py │ │ └── transformer.py │ ├── sam2_base.py │ └── sam2_utils.py ├── sam2_image_predictor.py ├── sam2_video_predictor.py └── utils │ ├── __init__.py │ ├── amg.py │ ├── download.py │ ├── misc.py │ ├── transforms.py │ └── visualization.py └── tests ├── assets └── images │ └── 00.jpeg ├── conftest.py ├── test_build_model.py ├── test_image_inference.py └── test_video_inference.py /.github/FUNDING.yml: -------------------------------------------------------------------------------- 1 | github: [SauravMaheshkar] 2 | -------------------------------------------------------------------------------- /.github/README.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SauravMaheshkar/samv2/HEAD/.github/README.md -------------------------------------------------------------------------------- /.github/dependabot.yml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SauravMaheshkar/samv2/HEAD/.github/dependabot.yml -------------------------------------------------------------------------------- /.github/workflows/ci.yml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SauravMaheshkar/samv2/HEAD/.github/workflows/ci.yml -------------------------------------------------------------------------------- /.pre-commit-config.yaml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SauravMaheshkar/samv2/HEAD/.pre-commit-config.yaml -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SauravMaheshkar/samv2/HEAD/LICENSE -------------------------------------------------------------------------------- /examples/notebooks/samv2_automatic_segmentation_with_wandb_tables.ipynb: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SauravMaheshkar/samv2/HEAD/examples/notebooks/samv2_automatic_segmentation_with_wandb_tables.ipynb -------------------------------------------------------------------------------- /examples/notebooks/samv2_prompted_segmentation_with_wandb_tables.ipynb: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SauravMaheshkar/samv2/HEAD/examples/notebooks/samv2_prompted_segmentation_with_wandb_tables.ipynb -------------------------------------------------------------------------------- /pyproject.toml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SauravMaheshkar/samv2/HEAD/pyproject.toml -------------------------------------------------------------------------------- /sam2/__init__.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SauravMaheshkar/samv2/HEAD/sam2/__init__.py -------------------------------------------------------------------------------- /sam2/automatic_mask_generator.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SauravMaheshkar/samv2/HEAD/sam2/automatic_mask_generator.py -------------------------------------------------------------------------------- /sam2/build_sam.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SauravMaheshkar/samv2/HEAD/sam2/build_sam.py -------------------------------------------------------------------------------- /sam2/configs/__init__.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SauravMaheshkar/samv2/HEAD/sam2/configs/__init__.py -------------------------------------------------------------------------------- /sam2/configs/sam2_hiera_b+.yaml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SauravMaheshkar/samv2/HEAD/sam2/configs/sam2_hiera_b+.yaml -------------------------------------------------------------------------------- /sam2/configs/sam2_hiera_l.yaml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SauravMaheshkar/samv2/HEAD/sam2/configs/sam2_hiera_l.yaml -------------------------------------------------------------------------------- /sam2/configs/sam2_hiera_s.yaml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SauravMaheshkar/samv2/HEAD/sam2/configs/sam2_hiera_s.yaml -------------------------------------------------------------------------------- /sam2/configs/sam2_hiera_t.yaml: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SauravMaheshkar/samv2/HEAD/sam2/configs/sam2_hiera_t.yaml -------------------------------------------------------------------------------- /sam2/modeling/__init__.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SauravMaheshkar/samv2/HEAD/sam2/modeling/__init__.py -------------------------------------------------------------------------------- /sam2/modeling/backbones/__init__.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SauravMaheshkar/samv2/HEAD/sam2/modeling/backbones/__init__.py -------------------------------------------------------------------------------- /sam2/modeling/backbones/hieradet.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SauravMaheshkar/samv2/HEAD/sam2/modeling/backbones/hieradet.py -------------------------------------------------------------------------------- /sam2/modeling/backbones/image_encoder.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SauravMaheshkar/samv2/HEAD/sam2/modeling/backbones/image_encoder.py -------------------------------------------------------------------------------- /sam2/modeling/backbones/utils.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SauravMaheshkar/samv2/HEAD/sam2/modeling/backbones/utils.py -------------------------------------------------------------------------------- /sam2/modeling/memory_attention.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SauravMaheshkar/samv2/HEAD/sam2/modeling/memory_attention.py -------------------------------------------------------------------------------- /sam2/modeling/memory_encoder.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SauravMaheshkar/samv2/HEAD/sam2/modeling/memory_encoder.py -------------------------------------------------------------------------------- /sam2/modeling/position_encoding.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SauravMaheshkar/samv2/HEAD/sam2/modeling/position_encoding.py -------------------------------------------------------------------------------- /sam2/modeling/sam/__init__.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SauravMaheshkar/samv2/HEAD/sam2/modeling/sam/__init__.py -------------------------------------------------------------------------------- /sam2/modeling/sam/mask_decoder.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SauravMaheshkar/samv2/HEAD/sam2/modeling/sam/mask_decoder.py -------------------------------------------------------------------------------- /sam2/modeling/sam/prompt_encoder.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SauravMaheshkar/samv2/HEAD/sam2/modeling/sam/prompt_encoder.py -------------------------------------------------------------------------------- /sam2/modeling/sam/transformer.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SauravMaheshkar/samv2/HEAD/sam2/modeling/sam/transformer.py -------------------------------------------------------------------------------- /sam2/modeling/sam2_base.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SauravMaheshkar/samv2/HEAD/sam2/modeling/sam2_base.py -------------------------------------------------------------------------------- /sam2/modeling/sam2_utils.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SauravMaheshkar/samv2/HEAD/sam2/modeling/sam2_utils.py -------------------------------------------------------------------------------- /sam2/sam2_image_predictor.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SauravMaheshkar/samv2/HEAD/sam2/sam2_image_predictor.py -------------------------------------------------------------------------------- /sam2/sam2_video_predictor.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SauravMaheshkar/samv2/HEAD/sam2/sam2_video_predictor.py -------------------------------------------------------------------------------- /sam2/utils/__init__.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SauravMaheshkar/samv2/HEAD/sam2/utils/__init__.py -------------------------------------------------------------------------------- /sam2/utils/amg.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SauravMaheshkar/samv2/HEAD/sam2/utils/amg.py -------------------------------------------------------------------------------- /sam2/utils/download.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SauravMaheshkar/samv2/HEAD/sam2/utils/download.py -------------------------------------------------------------------------------- /sam2/utils/misc.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SauravMaheshkar/samv2/HEAD/sam2/utils/misc.py -------------------------------------------------------------------------------- /sam2/utils/transforms.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SauravMaheshkar/samv2/HEAD/sam2/utils/transforms.py -------------------------------------------------------------------------------- /sam2/utils/visualization.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SauravMaheshkar/samv2/HEAD/sam2/utils/visualization.py -------------------------------------------------------------------------------- /tests/assets/images/00.jpeg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SauravMaheshkar/samv2/HEAD/tests/assets/images/00.jpeg -------------------------------------------------------------------------------- /tests/conftest.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SauravMaheshkar/samv2/HEAD/tests/conftest.py -------------------------------------------------------------------------------- /tests/test_build_model.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SauravMaheshkar/samv2/HEAD/tests/test_build_model.py -------------------------------------------------------------------------------- /tests/test_image_inference.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SauravMaheshkar/samv2/HEAD/tests/test_image_inference.py -------------------------------------------------------------------------------- /tests/test_video_inference.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/SauravMaheshkar/samv2/HEAD/tests/test_video_inference.py --------------------------------------------------------------------------------