| Line | Branch | Exec | Source |
|---|---|---|---|
| 1 | // SPDX-FileCopyrightText: 2026 Arm Limited and/or its affiliates <open-source-office@arm.com> | ||
| 2 | // | ||
| 3 | // SPDX-License-Identifier: Apache-2.0 | ||
| 4 | |||
| 5 | #ifndef KLEIDICV_MORPHOLOGY_MORPHOLOGY_H | ||
| 6 | #define KLEIDICV_MORPHOLOGY_MORPHOLOGY_H | ||
| 7 | |||
| 8 | #include "kleidicv/ctypes.h" | ||
| 9 | #include "kleidicv/morphology/workspace.h" | ||
| 10 | #include "kleidicv/utils.h" | ||
| 11 | |||
| 12 | namespace KLEIDICV_TARGET_NAMESPACE { | ||
| 13 | |||
| 14 | 1432 | inline bool morphology_is_implemented(size_t width, size_t height, | |
| 15 | size_t kernel_width, size_t kernel_height, | ||
| 16 | size_t channels) KLEIDICV_STREAMING { | ||
| 17 |
2/2✓ Branch 0 taken 16 times.
✓ Branch 1 taken 1416 times.
|
1432 | if (channels > KLEIDICV_MAXIMUM_CHANNEL_COUNT) { |
| 18 | 16 | return false; | |
| 19 | } | ||
| 20 | |||
| 21 |
4/4✓ Branch 0 taken 1376 times.
✓ Branch 1 taken 40 times.
✓ Branch 2 taken 16 times.
✓ Branch 3 taken 1360 times.
|
1416 | if (width < kernel_width - 1 || height < kernel_height - 1) { |
| 22 | 56 | return false; | |
| 23 | } | ||
| 24 | |||
| 25 | 1360 | return true; | |
| 26 | 1432 | } | |
| 27 | |||
| 28 | } // namespace KLEIDICV_TARGET_NAMESPACE | ||
| 29 | |||
| 30 | #endif // KLEIDICV_MORPHOLOGY_MORPHOLOGY_H | ||
| 31 |