From 8511d900a88638cb04ced2db35b171a96f6f310c Mon Sep 17 00:00:00 2001 From: oahzxl Date: Mon, 12 Dec 2022 17:36:17 +0800 Subject: [PATCH] code style --- chunk_codegen.py | 11 ----------- 1 file changed, 11 deletions(-) diff --git a/chunk_codegen.py b/chunk_codegen.py index 96dcbfc0f..88d917809 100644 --- a/chunk_codegen.py +++ b/chunk_codegen.py @@ -1210,8 +1210,6 @@ class ChunkRegionSearch(object): return chunk_infos def _find_free_dim(self, input_trace, output_trace, start_idx, end_idx): - if start_idx == 71 and end_idx == 126: - print(1) start_traces = input_trace[start_idx] end_trace = output_trace[end_idx] end_node = self.node_list[end_idx] @@ -1347,15 +1345,6 @@ def _gen_chunk_slice_dim(chunk_dim, chunk_idx_name, shape): return new_shape -def _get_first_non_single_dim(shape): - for idx, i in enumerate(shape): - if i == 1: - continue - else: - return idx - raise RuntimeError("can not get first non single dim for shape", shape) - - def _gen_loop_start(chunk_input, chunk_output, chunk_ouput_dim, chunk_size=2): input_node = chunk_input[0] out_shape = _get_node_shape(chunk_output)