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

12
LINES

< > BotCompany Repo | #1032166 // test_ImageSimilarityAtScale_equalImages

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

Libraryless. Click here for Pure Java version (7138L/42K).

svoid test_ImageSimilarityAtScale_equalImages() {
  var img = randomImage(50, 20);
  var ii = IntegralImage(img);
  ImageSimilarityAtScale algo = new(ii, ii, 4);
  algo.run();
  int i = 1;
  for (i = 1; i <= 254; i++) {
    assertTrue(str(i), algo.step());
    assertEquals(0.0, algo.diff());
  }
  assertFalse(str(i), algo.step());
}

Author comment

Began life as a copy of #1032164

download  show line numbers  debug dex  old transpilations   

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

No comments. add comment

Snippet ID: #1032166
Snippet name: test_ImageSimilarityAtScale_equalImages
Eternal ID of this version: #1032166/5
Text MD5: 0ee77b2cc4c556694586b3826240132d
Transpilation MD5: d47a3d96919189c91bba6da1cb934f55
Author: stefan
Category: javax / imaging
Type: JavaX fragment (include)
Public (visible to everyone): Yes
Archived (hidden from active list): No
Created/modified: 2021-08-16 22:37:35
Source code size: 345 bytes / 12 lines
Pitched / IR pitched: No / No
Views / Downloads: 179 / 244
Version history: 4 change(s)
Referenced in: [show references]