How to track the barcode with highest confidence
问题 I am using vision framework to detect barcodes. I want to show a rect around the barcode with highest confidence on live video, meaning, I want to track that rect to the barcode seen on the live preview. So I have this code to detect the barcodes within a roi. lazy var barcodeRequest: VNDetectBarcodesRequest = { let barcodeRequest = VNDetectBarcodesRequest {[weak self] request, error in guard error == nil else { print ("ERRO: \(error?.localizedDescription ?? "error")") return } self?