boxes
get_centroids_heatmap(df, n_rows=9, n_cols=9)
Returns centroids heatmap.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
df |
DataFrame
|
DataFrame with annotations. |
required |
n_rows |
int
|
Number of rows. |
9
|
n_cols |
int
|
Number of columns. |
9
|
Returns:
Type | Description |
---|---|
np.ndarray
|
Centroids heatmap. With shape ( |
Source code in pyodi/plots/boxes.py
10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 |
|
plot_heatmap(heatmap, title='', show=True, output=None, output_size=(1600, 900))
Plots heatmap figure.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
heatmap |
np.ndarray
|
Heatmap (2D array) data to plot. |
required |
title |
str
|
Title of the figure. Defaults to "". |
''
|
show |
bool
|
Whether to show results or not. Defaults to True. |
True
|
output |
Optional[str]
|
Results will be saved under |
None
|
output_size |
Tuple[int, int]
|
Size of the saved images when output is defined. Defaults to (1600, 900). |
(1600, 900)
|
Returns:
Type | Description |
---|---|
go.Figure
|
Heatmap figure. |
Source code in pyodi/plots/boxes.py
33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 |
|