# annotation_sizes

Python API: `depthai_nodes.utils.annotation_sizes`

## Classes

### AnnotationSizes

Compute annotation dimensions from an image resolution.

Pixel sizes scale with image height or the sum of width and height. Relative font sizes and spacing use image height as their
reference.

#### Methods

##### init

```python
def __init__(width: int, height: int):
```

Set the image resolution used by size calculations.

Parameters

 * `width` (`int`): Image width in pixels.
 * `height` (`int`): Image height in pixels; must be nonzero for relative size calculations.

#### Attributes

##### aspect_ratio

Image width divided by image height.

##### border_thickness

Detection border thickness in pixels.

##### corner_size

Configured relative size of detection corners.

##### font_size

Font size in pixels, proportional to image height.

##### font_space

Text spacing equal to half the relative font size.

##### keypoint_thickness

Keypoint marker thickness in pixels.

##### relative_font_size

Font size divided by image height.
