Created
September 19, 2019 00:47
-
-
Save truongsinh/20d49cd72c134d96d809dc07d8e6fcf3 to your computer and use it in GitHub Desktop.
combine to a single new list
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// ... | |
final List<DetectionResult> results = List(); | |
for (var index = 0; index < numDetections; index++) { | |
String detectedClass = localLabels[outputClasses[index].toInt()]; | |
// final top // explain shortly after | |
// final left // explain shortly after | |
// final bottom // explain shortly after | |
// final right // explain shortly after | |
final thisSesult = DetectionResult( | |
rect: Rect.fromLTRB(left, top, right, bottom), | |
confidenceInClass: outputScores[index], | |
detectedClass: detectedClass, | |
); | |
results.add(thisSesult); | |
} | |
return results; | |
// ... |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment