Skip to content

Commit

Permalink
Merge pull request #319 from mehul-m-prajapati/image_stitch
Browse files Browse the repository at this point in the history
Added image stitching project (opencv)
  • Loading branch information
UppuluriKalyani authored Oct 14, 2024
2 parents 259040d + 2d21860 commit 0c93bf8
Show file tree
Hide file tree
Showing 2 changed files with 385 additions and 0 deletions.
38 changes: 38 additions & 0 deletions Computer Vision/Image Stitching/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
# Image Stitching with OpenCV

This project demonstrates image stitching using OpenCV, which combines multiple images into a single panoramic image. The code loads a set of images, performs feature detection and matching, and stitches them together to create a seamless panorama.

## Code Breakdown:

1. **Library Installation**:
- Installs necessary libraries: OpenCV and Matplotlib.

2. **Function: `stitch_images`**:
- **Loading Images**: Reads images from the specified file paths.
- **Stitcher Object**: Creates an OpenCV Stitcher object to handle the stitching process.
- **Performing Stitching**: Uses `stitcher.stitch()` to combine images.
- **Error Handling**: Checks the status of the stitching process and returns the stitched image or an error message.

3. **Function: `display_result`**:
- Displays the stitched image using Matplotlib.

4. **Example Usage**:
- Upload to images you want to stitch.
- Calls `stitch_images()` to perform the stitching and then displays the result.

## Possible Enhancements:
- **Input Flexibility**: Allow for dynamic input of image paths through user interface or file upload.
- **Image Preprocessing**: Apply image enhancement techniques before stitching for better results.
- **Advanced Matching**: Implement feature matching techniques (like SIFT or ORB) for improved alignment of images.

## Example Use Case:
This image stitching method is useful for creating panoramic images from a series of overlapping photographs, often used in photography, mapping, and virtual reality applications.

## Requirements:
- OpenCV
- Matplotlib

### How to Run:
1. Install the required libraries.
2. Update the `image_paths` list with paths to your images.
3. Run the cell to perform stitching and view the result.
347 changes: 347 additions & 0 deletions Computer Vision/Image Stitching/panorama.ipynb

Large diffs are not rendered by default.

0 comments on commit 0c93bf8

Please sign in to comment.