Skip to content

Commit

Permalink
feat: add example notebooks (#8)
Browse files Browse the repository at this point in the history
* feat: add nb

* docs: update README

* docs: fix link in example nb
  • Loading branch information
SauravMaheshkar authored Aug 3, 2024
1 parent 03d1288 commit 31f4c41
Show file tree
Hide file tree
Showing 3 changed files with 641 additions and 7 deletions.
24 changes: 17 additions & 7 deletions .github/README.md
Original file line number Diff line number Diff line change
@@ -1,13 +1,29 @@
<a href="https://colab.research.google.com/github/SauravMaheshkar/samv2/blob/main/examples/notebooks/samv2_prompted_segmentation_with_wandb_tables.ipynb" target="_parent"><img src="https://colab.research.google.com/assets/colab-badge.svg" alt="Open In Colab"/></a>
[![Build and Tests](https://github.com/SauravMaheshkar/samv2/actions/workflows/ci.yml/badge.svg)](https://github.com/SauravMaheshkar/samv2/actions/workflows/ci.yml)

CPU **compatible** fork of the official SAMv2 implementation.

## Features 🚀

* CPU compatible
* ships with config files
* Run image and video inference on CPUs
* [Example notebooks](../examples/notebooks/) showcasing inference using weights and biases.

## Installation

This is a CPU compatible fork of the official SAMv2 implementation. You can download it from [pypi](https://pypi.org/) using `pip` as follows:
You can download it from [pypi](https://pypi.org/) using `pip` as follows:

```bash
pip install samv2
```

or from the repository:

```bash
pip install git+https://github.com/SauravMaheshkar/samv2.git
```

## Usage

After downloading the official weights, you can use the `load_model()` helper method to instantiate a model.
Expand All @@ -22,12 +38,6 @@ model = load_model(
)
```

## Features 🚀

* CPU compatible
* ships with config files
* Run image and video inference on CPUs

## Citation

```bibtex
Expand Down
6 changes: 6 additions & 0 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -16,3 +16,9 @@ repos:
rev: 5.13.2
hooks:
- id: isort
- repo: https://github.com/nbQA-dev/nbQA
rev: 1.8.5
hooks:
- id: nbqa-black
- id: nbqa-isort
args: [ "--profile=black" ]
Loading

0 comments on commit 31f4c41

Please sign in to comment.