Object dimension measurement
Object dimension measurement
The following image is of a coin (for reference) and a pill. I need to measure the pill's dimensions. The objects are back-illuminated.
I followed pyimagesearch.com tutorial for object height and width measurement.
The coin has a diameter of 24.97 mm, and the actual dimensions of the pill are 9.43 mm x 19.33 mm. I am getting results with some error ranging from 0.5 mm to 2 mm. As mentioned on the website this is because of distortion and it is to be corrected.
Can someone help me in calibrating the camera to remove the distortion effect so that I can measure correct dimensions in mm?
I have also tried camera calibration but that is also not working.
@CrisLuengo thanks a lot for responding but I have put coin on the left of the pill of known size 25mm
– LALIT VYAS
Jul 24 at 7:21
Ah, OK. Please include that information into your post, as well as a description (preferabele with code) for exactly what you did. What kind of imaging did you use to get that picture (it doesn’t look like a photograph), or is this the result of some preprocessing? Is the coin 25.00 mm or is 25 mm? (that is, how precise is that measurement?)
– Cris Luengo
Jul 24 at 13:11
@CrisLuengo this photograph is taken by keeping bottom light on, no image processing is done on this and the coin dimention is 24.97 mm but I used 25 mm and the code I used is exactly same as given in the link provided in the question (pyimagesearch.com). And Thank you for looking into this problem
– LALIT VYAS
5 hours ago
I've added this information to your question. You can >edit< your question to improve it at any time. The comments here are considered transitory, they can be deleted at any time. They are meant for improvements to the question, try to answer by editing the question text. Thanks!
– Cris Luengo
24 secs ago
By clicking "Post Your Answer", you acknowledge that you have read our updated terms of service, privacy policy and cookie policy, and that your continued use of the website is subject to these policies.
For camera calibration you need to add an object of known size, or a set of fiducial markers at known distance from each other. There is no way we can tell you how to calibrate your camera with the information you have given here.
– Cris Luengo
Jul 23 at 19:24