mirror of
https://github.com/azaion/annotations.git
synced 2026-04-22 16:46:31 +00:00
fix loader bug with _CACHED_HW_INFO
put tile size to name and set it dynamically for AI recognition
This commit is contained in:
@@ -57,7 +57,7 @@ namespace Azaion.Annotator.Test;
|
||||
var detections = new List<CanvasLabel>
|
||||
{
|
||||
new(100, 150, 100, 150),
|
||||
new(2000, 2050, 2000, 2050) // More than Constants.AI_TILE_SIZE away
|
||||
new(2000, 2050, 2000, 2050) // More than Constants.AI_TILE_SIZE_DEFAULT away
|
||||
};
|
||||
|
||||
// Act
|
||||
@@ -139,11 +139,11 @@ namespace Azaion.Annotator.Test;
|
||||
{
|
||||
// Arrange
|
||||
var originalSize = new Size(IMAGE_SIZE, IMAGE_SIZE);
|
||||
// Combined width is 1270. 1270 + BORDER (10) is not > Constants.AI_TILE_SIZE (1280), so they fit.
|
||||
// Combined width is 1270. 1270 + BORDER (10) is not > Constants.AI_TILE_SIZE_DEFAULT (1280), so they fit.
|
||||
var detections = new List<CanvasLabel>
|
||||
{
|
||||
new(0, 50, 0, 50),
|
||||
new(Constants.AI_TILE_SIZE - TileProcessor.BORDER - 50, Constants.AI_TILE_SIZE - TileProcessor.BORDER, 0, 50)
|
||||
new(Constants.AI_TILE_SIZE_DEFAULT - TileProcessor.BORDER - 50, Constants.AI_TILE_SIZE_DEFAULT - TileProcessor.BORDER, 0, 50)
|
||||
};
|
||||
|
||||
// Act
|
||||
@@ -159,11 +159,11 @@ namespace Azaion.Annotator.Test;
|
||||
{
|
||||
// Arrange
|
||||
var originalSize = new Size(IMAGE_SIZE, IMAGE_SIZE);
|
||||
// Combined width is 1271. 1271 + BORDER (10) is > Constants.AI_TILE_SIZE (1280), so they don't fit.
|
||||
// Combined width is 1271. 1271 + BORDER (10) is > Constants.AI_TILE_SIZE_DEFAULT (1280), so they don't fit.
|
||||
var detections = new List<CanvasLabel>
|
||||
{
|
||||
new(0, 50, 1000, 1050), // Top-most
|
||||
new(Constants.AI_TILE_SIZE - TileProcessor.BORDER - 49, Constants.AI_TILE_SIZE - TileProcessor.BORDER + 1, 0, 50)
|
||||
new(Constants.AI_TILE_SIZE_DEFAULT - TileProcessor.BORDER - 49, Constants.AI_TILE_SIZE_DEFAULT - TileProcessor.BORDER + 1, 0, 50)
|
||||
};
|
||||
|
||||
// Act
|
||||
@@ -224,7 +224,7 @@ namespace Azaion.Annotator.Test;
|
||||
{
|
||||
// Arrange
|
||||
var originalSize = new Size(IMAGE_SIZE, IMAGE_SIZE);
|
||||
var largeDetection = new CanvasLabel(100, 100 + Constants.AI_TILE_SIZE + 100, 100, 200);
|
||||
var largeDetection = new CanvasLabel(100, 100 + Constants.AI_TILE_SIZE_DEFAULT + 100, 100, 200);
|
||||
var detections = new List<CanvasLabel> { largeDetection };
|
||||
|
||||
// Act
|
||||
@@ -245,7 +245,7 @@ namespace Azaion.Annotator.Test;
|
||||
{
|
||||
// Arrange
|
||||
var originalSize = new Size(IMAGE_SIZE, IMAGE_SIZE);
|
||||
var largeTallDetection = new CanvasLabel(100, 150, 100, 100 + Constants.AI_TILE_SIZE + 200);
|
||||
var largeTallDetection = new CanvasLabel(100, 150, 100, 100 + Constants.AI_TILE_SIZE_DEFAULT + 200);
|
||||
var smallDetectionNearby = new CanvasLabel(largeTallDetection.Right + 15, largeTallDetection.Right + 35, 700, 720);
|
||||
|
||||
var detections = new List<CanvasLabel> { largeTallDetection, smallDetectionNearby };
|
||||
|
||||
Reference in New Issue
Block a user