v1_checks
Functions to check content of ROI tables.
are_ROI_table_columns_valid(*, table)
¶
Verify some validity assumptions on a ROI table.
This function reflects our current working assumptions (e.g. the presence of some specific columns); this may change in future versions.
PARAMETER | DESCRIPTION |
---|---|
table |
AnnData table to be checked
TYPE:
|
Source code in fractal_tasks_core/roi/v1_checks.py
119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 |
|
check_valid_ROI_indices(list_indices, ROI_table_name)
¶
Check that list of indices has zero origin on each axis.
See fractal-tasks-core issues #530 and #554.
This helper function is meant to provide informative error messages when ROI tables created with fractal-tasks-core up to v0.11 are used in v0.12. This function will be deprecated and removed as soon as the v0.11/v0.12 transition advances.
Note that only FOV_ROI_table
and well_ROI_table
have to fulfill this
constraint, while ROI tables obtained through segmentation may have
arbitrary (non-negative) indices.
PARAMETER | DESCRIPTION |
---|---|
list_indices |
Output of |
ROI_table_name |
Name of the ROI table.
TYPE:
|
RAISES | DESCRIPTION |
---|---|
ValueError
|
If the table name is |
Source code in fractal_tasks_core/roi/v1_checks.py
28 29 30 31 32 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 68 69 70 71 72 73 74 75 76 77 78 |
|
is_ROI_table_valid(*, table_path, use_masks)
¶
Verify some validity assumptions on a ROI table.
This function reflects our current working assumptions (e.g. the presence of some specific columns); this may change in future versions.
If use_masks=True
, we verify that the table is a valid
masking_roi_table
as of table specifications V1; if this check fails,
use_masks
should be set to False
upstream in the parent function.
PARAMETER | DESCRIPTION |
---|---|
table_path |
Path of the AnnData ROI table to be checked.
TYPE:
|
use_masks |
If
TYPE:
|
RETURNS | DESCRIPTION |
---|---|
Optional[bool]
|
Always |
Source code in fractal_tasks_core/roi/v1_checks.py
81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 |
|