has anyone implemented Image stitching solution (on server side), basically we are working on mobile application which uses Azure hosted micro-services. The mobile application will capture pictures of lengthy receipts (for e.g. walmart or Costco which don't fit in one camera capture/click so user takes multiple clicks/pics) and the app front-end is Xamarin based so we have had 2 options to consider (one doing it on App or on server side). I am just trying to explore if anyone has implemented any solution like this for stitching images on server-side (On server side we are ok to use C#, Python, etc as this would be a micro-service hosted on Azure and could be a function app as well). Appreciate if you can share any ideas around it. (If something similar you have done on Xamarin App side which we can leverage would also be fine). Thank you!
-
1"has anyone done X?" and "share any ideas around it" is off-topic. Please read [ask] for guidance on writing on-topic questions. – Jason Oct 12 '21 at 20:50
-
1https://www.google.com/search?q=image+stitching+site%3Astackoverflow.com – Jason Oct 12 '21 at 20:51
1 Answers
There are a few steps that we must take.
- Selecting corresponding points:
To effectively stitch two photos, you'll need a large number of related points between your input images. You may utilise the ginput function (under matplotlib.pyplot) for this purpose, which operates on images and allows you to choose these point pairs (x,y) with mouse clicks.
- Homography estimation
Create a function that can calculate the homogpraphy matrix between two images using the previously selected point pairs. This function's signature for your solution should be: homography = computeH(points_im1, points_im2)
NOTE : points_im1 and points_im2 are the matrices which consists of corresponding point pairs.
To calculate the homography, you are allowed to use svd function (in numpy.linalg).
- Image warping
You should be able to distort two images using backward transform after correctly estimating the homography between them. This function's signature for your solution should be:
image_warped = warp(image, homography)
- Blending images
You can combine the distorted photos into a single panoramic/mosaic/stitched image once you have them. When you place images immediately on top of each other, every pixel you write overwrites pixels from the previous image. As a result, for overlapping areas, you can use the image pixel with the highest intensity.
REFERENCES: CMPE537/Assignment2.txt at main · burak-yildizoz/CMPE537 (github.com)
For more information you can refer this THREAD

- 7,513
- 2
- 4
- 18