diff options
Diffstat (limited to 'ethosu/vela/high_level_command_stream_generator.py')
-rw-r--r-- | ethosu/vela/high_level_command_stream_generator.py | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/ethosu/vela/high_level_command_stream_generator.py b/ethosu/vela/high_level_command_stream_generator.py index 01fab0e8..871a0486 100644 --- a/ethosu/vela/high_level_command_stream_generator.py +++ b/ethosu/vela/high_level_command_stream_generator.py @@ -238,6 +238,7 @@ def generate_high_level_command_stream_for_pass(strat, passes, block_configs, id y_step = y_dim weight_box = None + scale_box = None for start in range(y_start, y_dim, y_step): end = min(start + y_step, y_dim) @@ -299,6 +300,10 @@ def generate_high_level_command_stream_for_pass(strat, passes, block_configs, id if ifm_y_present >= ifm_y_needed: break + if scale_tensor is not None and scale_tensor.purpose == TensorPurpose.FSBias and scale_box is None: + scale_box = Box([0] * len(scale_tensor.shape), list(scale_tensor.shape)) + yield from dma_if_necessary(ps, scale_box, scale_tensor) + if weight_tensor is not None and weight_box is None: weight_box = Box.make_weight_box( weight_tensor.shape, npu_block_type, weights_transposed=weight_tensor.weight_transpose_depthwise |