aboutsummaryrefslogtreecommitdiff
path: root/ethosu/vela/compiler_driver.py
diff options
context:
space:
mode:
Diffstat (limited to 'ethosu/vela/compiler_driver.py')
-rw-r--r--ethosu/vela/compiler_driver.py2
1 files changed, 2 insertions, 0 deletions
diff --git a/ethosu/vela/compiler_driver.py b/ethosu/vela/compiler_driver.py
index 7f8c4ca4..db669ac7 100644
--- a/ethosu/vela/compiler_driver.py
+++ b/ethosu/vela/compiler_driver.py
@@ -141,6 +141,8 @@ def compiler_driver(nng, arch, options, scheduler_options):
sg, permanent_storage, ignore_subgraph_input_output_tensors=True, lr_graph=lr_graph_flash
)
+ assert len(nng.subgraphs) > 1, "Error: No operators can be hardware accelerated; cancelling compilation"
+
# Allocate all Npu constant tensors to the first Npu subgraph since it is
# processed first during serialization into tensors
first_npu_sg = nng.subgraphs[1]