Not logged in.  Login/Logout/Register | List snippets | | Create snippet | Upload image | Upload data

32
LINES

< > BotCompany Repo | #1032027 // IIIRecognizer

JavaX fragment (include) [tags: use-pretranspiled]

Libraryless. Click here for Pure Java version (7425L/43K).

1  
// A = tag type
2  
sinterface IIIRecognizer<A> {
3  
  // Newer version! (Override this)
4  
  public default void run(
5  
    IProbabilisticScheduler scheduler,
6  
    URecognizer.Cell cell,
7  
    IVF1<A> valueToAction) { unimplemented(); }
8  
    
9  
  // Clients can use. Don't override
10  
  public default void run(
11  
    IProbabilisticScheduler scheduler,
12  
    IIntegralImage img,
13  
    IVF1<A> valueToAction) {
14  
    run(scheduler, uCell(img), valueToAction);
15  
  }
16  
  
17  
  public default IProbabilisticScheduler run(
18  
    IIntegralImage img,
19  
    IVF1<A> valueToAction) {
20  
    new ProbabilisticScheduler ps;
21  
    run(ps, uCell(img), valueToAction);
22  
    ret ps;
23  
  }
24  
  
25  
  public default IProbabilisticScheduler run(
26  
    BufferedImage img,
27  
    IVF1<A> valueToAction) {
28  
    new ProbabilisticScheduler ps;
29  
    run(ps, IntegralImage(img), valueToAction);
30  
    ret ps;
31  
  }
32  
}

Author comment

Began life as a copy of #1032022

download  show line numbers  debug dex  old transpilations   

Travelled to 3 computer(s): bhatertpkbcr, mqqgnosmbjvj, pyentgdyhuwx

No comments. add comment

Snippet ID: #1032027
Snippet name: IIIRecognizer
Eternal ID of this version: #1032027/9
Text MD5: fc3d950ee5ea235cc328974bb63642a7
Transpilation MD5: 91490f09f868ba7bc49424fd09ec716a
Author: stefan
Category: javax
Type: JavaX fragment (include)
Public (visible to everyone): Yes
Archived (hidden from active list): No
Created/modified: 2021-08-11 15:36:39
Source code size: 860 bytes / 32 lines
Pitched / IR pitched: No / No
Views / Downloads: 182 / 341
Version history: 8 change(s)
Referenced in: [show references]