Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Implement native QRCodeDetector #231

Open
edgarriba opened this issue Feb 5, 2025 · 5 comments
Open

Implement native QRCodeDetector #231

edgarriba opened this issue Feb 5, 2025 · 5 comments
Labels
good first issue Good for newcomers help wanted Extra attention is needed

Comments

@edgarriba
Copy link
Member

Create a native implementation of QR detector similar to OpenCV QRCodeDetector requested by user in discord.

Ideally as separated crate kornia-qr within the parent worksapce.

@edgarriba edgarriba added good first issue Good for newcomers help wanted Extra attention is needed labels Feb 5, 2025
@jaydon2020
Copy link

Hi, anyone working on this issue? I would like to work on this issue.
@edgarriba cloud you provide me more detail and assign me to this issue.

start to create a new crate

cargo new kornia-qr --bin

About the detect and decode what data types should I return? any suggestion?

detectAndDecodeCurved(&self, input_image: Image<u8, 3>) -> retval, points, straight_qrcode
retval: String // Decoded data
points: Tensor<f32, 4> // box binding of the qr code found
straight_qrcode: Image<u8, 3> // rectifiedImage

References
https://github.com/opencv/opencv/blob/4.x/modules/objdetect/src/qrcode.cpp
https://github.com/dignifiedquire/quircs/tree/master

@edgarriba
Copy link
Member Author

Hi, sounds good to me if you want to give it a shot. What’s exactly retval as String ? Also for simplicity I would return for now a vec<[[f32; 2]; 4]> for the points. Are you planning to write from scratch, or use any other library ? Let’s minimise as much as possible the deps tree

@pratheekhassan21
Copy link

pratheekhassan21 commented Mar 3, 2025

Hi,@edgarriba is jaydon2020 working on this issue?Can i work on this issue if u can help me?i was thinking of contributing to the kornia rs for gsoc 2025

@jaydon2020
Copy link

@edgarriba, I do some research this library working well on QRCode detect

Since minimize as much as possible the deps tree, I will manually port it from OpenCV QRCode Detect.

Also, the OpenCV implement an abstract class GraphicalCodeDetector for QRCode, do we need to follow similar approach so that it provide an trait for future implementation like barcode or aruco detection

@edgarriba
Copy link
Member Author

@jaydon2020 sounds like a plan

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
good first issue Good for newcomers help wanted Extra attention is needed
Projects
None yet
Development

No branches or pull requests

3 participants