Skip to content

Commit

Permalink
add GraphCutSeamFinder (#43)
Browse files Browse the repository at this point in the history
* add GraphCutSeamFinder

* bump version
  • Loading branch information
lukasalexanderweber authored Jan 3, 2023
1 parent 81cb7c0 commit 73bd810
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 4 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ panorama = stitcher.stitch(["img1.jpg", "img2.jpg", "img3.jpg"])
Specify your custom settings as

```python
settings = {"detector": "sift", "confidence_threshold": 0.2}
settings = {"detector": "sift", "confidence_threshold": 0.2}
stitcher = Stitcher(**settings)
```

Expand Down
2 changes: 1 addition & 1 deletion stitching/__init__.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
from .stitcher import AffineStitcher, Stitcher # noqa: F401

__version__ = "0.3.0"
__version__ = "0.4.0"
8 changes: 6 additions & 2 deletions stitching/seam_finder.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,12 +12,16 @@ class SeamFinder:
SEAM_FINDER_CHOICES = OrderedDict()
SEAM_FINDER_CHOICES["dp_color"] = cv.detail_DpSeamFinder("COLOR")
SEAM_FINDER_CHOICES["dp_colorgrad"] = cv.detail_DpSeamFinder("COLOR_GRAD")
SEAM_FINDER_CHOICES["gc_color"] = cv.detail_GraphCutSeamFinder("COST_COLOR")
SEAM_FINDER_CHOICES["gc_colorgrad"] = cv.detail_GraphCutSeamFinder(
"COST_COLOR_GRAD"
)
SEAM_FINDER_CHOICES["voronoi"] = cv.detail.SeamFinder_createDefault(
cv.detail.SeamFinder_VORONOI_SEAM
) # noqa
)
SEAM_FINDER_CHOICES["no"] = cv.detail.SeamFinder_createDefault(
cv.detail.SeamFinder_NO
) # noqa
)

DEFAULT_SEAM_FINDER = list(SEAM_FINDER_CHOICES.keys())[0]

Expand Down

0 comments on commit 73bd810

Please sign in to comment.