Libraryless. Click here for Pure Java version (10325L/68K/227K).
1 | !7 |
2 | |
3 | p { |
4 | Concepts in = new Concepts("#1006104").safeLoad(); |
5 | L<S> lines = (L) cget(first(list(in, "RecogInfo")), "lines"); |
6 | new TreeSet<S> md5s; |
7 | new Matches m; |
8 | for (S s : lines) |
9 | if (matchStart("the images *", s, m)) { |
10 | md5s.addAll(splitAtSpace($1)); |
11 | } |
12 | print("MD5s we're looking for: " + struct(md5s)); |
13 | |
14 | Concepts in2 = new Concepts("#1005951").load(); |
15 | new HashMap<S, BWImage> md5ToImage; |
16 | for (GrabbedImage gi : list(in2, GrabbedImage)) { |
17 | if (md5s.contains(gi.md5)) |
18 | md5ToImage.put(gi.md5, gi.image); |
19 | for (BWImage cImg : horizontalAutoSplitToImages(gi.image)) { |
20 | S md5 = md5OfBWImage(cImg); |
21 | if (md5s.contains(md5)) |
22 | md5ToImage.put(md5, cImg); |
23 | } |
24 | } |
25 | |
26 | int found = 0; |
27 | for (S md5 : md5s) { |
28 | BWImage img = md5ToImage.get(md5); |
29 | if (img != null) ++found; |
30 | } |
31 | print("Found: " + found + "/" + l(md5s)); |
32 | } |
download show line numbers debug dex old transpilations
Travelled to 14 computer(s): aoiabmzegqzx, bhatertpkbcr, cbybwowwnfue, cfunsshuasjs, gwrvuhgaqvyk, ishqpsrjomds, lpdgvwnxivlt, mqqgnosmbjvj, pyentgdyhuwx, pzhvpgtvlbxg, sawdedvomwva, tslmcundralx, tvejysmllsmz, vouqrxazstgt
No comments. add comment
Snippet ID: | #1006191 |
Snippet name: | Find images for character MD5s |
Eternal ID of this version: | #1006191/2 |
Text MD5: | 643c974b196a621765f056a6a633a769 |
Transpilation MD5: | d1b283fbad7ad022f97c5cb26a1b83ad |
Author: | stefan |
Category: | javax / ocr |
Type: | JavaX source code |
Public (visible to everyone): | Yes |
Archived (hidden from active list): | No |
Created/modified: | 2018-05-10 21:16:31 |
Source code size: | 904 bytes / 32 lines |
Pitched / IR pitched: | No / No |
Views / Downloads: | 527 / 674 |
Version history: | 1 change(s) |
Referenced in: | [show references] |