aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRickard Bolin <rickard.bolin@arm.com>2023-06-14 16:05:47 +0000
committerRickard Bolin <rickard.bolin@arm.com>2023-06-14 16:05:47 +0000
commit8da4f954d32b6395c93ff72123211f40f52cc136 (patch)
treec4f4649841e2094809384094bea7155634250c8a
parent8e525ca8aad4a52b80c1986c5067b9b74fb3e321 (diff)
downloadethos-u-vela-8da4f954d32b6395c93ff72123211f40f52cc136.tar.gz
MLBEDSW-7734: Update Sized import from collections
Update import of Sized from collections to collections.abc to work with Python 3.10 Change-Id: Iae281db9402331972ad13660d04523608b23614d Signed-off-by: Rickard Bolin <rickard.bolin@arm.com>
-rw-r--r--ethosu/vela/utils.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/ethosu/vela/utils.py b/ethosu/vela/utils.py
index 386ba35..6a36897 100644
--- a/ethosu/vela/utils.py
+++ b/ethosu/vela/utils.py
@@ -26,7 +26,7 @@ def progress_print(
enabled: bool,
message: str,
progress_counter: int = -1,
- progress_total: int | collections.Sized = 0,
+ progress_total: int | collections.abc.Sized = 0,
progress_granularity: float = 0.20,
):
"""Print progress information.
@@ -67,7 +67,7 @@ def progress_print(
context_str += ": " if message else ""
display_total = progress_total
# If a sized collection is provided, extract its size to use as progress total
- if isinstance(progress_total, collections.Sized):
+ if isinstance(progress_total, collections.abc.Sized):
progress_total = len(progress_total)
display_total = progress_total - 1