Searched refs:weights (Results 1 – 12 of 12) sorted by relevance
/cmsis-nn-latest/Tests/UnitTest/ |
D | fully_connected_settings.py | 137 def generate_data(self, input_data=None, weights=None, biases=None) -> None: argument 166 if weights is not None: 167 weights = tf.reshape(weights, fc_weights_format) 169 weights = self.get_randomized_data(fc_weights_format, 177 … generated_json = self.generate_json_from_template(weights, bias_data=biases, bias_buffer=2) 180 weights_size = weights.numpy().size 190 if weights is not None: 191 weights = tf.reshape(weights, fc_weights_format) 193 weights = self.get_randomized_data(fc_weights_format, 202 … generated_json = self.generate_json_from_template(weights, bias_data=biases, bias_buffer=2) [all …]
|
D | conv_settings.py | 205 def generate_data(self, input_data=None, weights=None, biases=None) -> None: argument 226 if weights is not None: 227 weights = tf.reshape(weights, w_shape) 229 weights = self.get_randomized_data(w_shape, 240 weights = np.append(weights, [0]) 300 temp = np.reshape(weights, (len(weights) // 2, 2)).astype(np.uint8) 302 weights = tf.convert_to_tensor(temp) 307 None, weights, int8_time_weights=True, bias_data=biases, bias_buffer=3) 309 generated_json = self.generate_json_from_template(weights, int8_time_weights=False, 323 if weights is not None: [all …]
|
D | lstm_settings.py | 97 … def generate_data(self, input_data=None, weights=None, hidden_weights=None, biases=None) -> None: argument 113 if weights is not None: 114 weights = tf.reshape(weights, [self.number_inputs, number_cells * number_w_b]) 116 weights = self.get_randomized_data([self.number_inputs, number_cells * number_w_b], 167 print("Updating weights", model.layers[1 + time_major_offset].weights[0].name) 168 model.layers[1 + time_major_offset].weights[0].assign(weights) 169 print("Updating hidden weights", model.layers[1 + time_major_offset].weights[1].name) 170 model.layers[1 + time_major_offset].weights[1].assign(hidden_weights) 171 print("Updating bias", model.layers[1 + time_major_offset].weights[2].name) 172 model.layers[1 + time_major_offset].weights[2].assign(biases) [all …]
|
D | model_extractor.py | 228 weights = tensors[weights_index] 230 weights_data_index = weights['buffer'] 240 filter_shape = weights['shape'] 273 def generate_data(self, input_data=None, weights=None, biases=None) -> None: argument
|
D | svdf_settings.py | 149 …def generate_data(self, input_data=None, weights=None, biases=None, time_data=None, state_data=Non… argument 168 if weights is not None: 169 weights_feature_data = tf.reshape(weights, [self.number_filters, self.input_size])
|
D | softmax_settings.py | 116 def generate_data(self, input_data=None, weights=None, biases=None) -> None: argument
|
D | test_settings.py | 426 def generate_data(self, input_data=None, weights=None, biases=None) -> None: argument
|
D | README.md | 163 | fully_connected | x | x | New version only supports int4 packed weights
|
/cmsis-nn-latest/Tests/UnitTest/RefactoredTestGen/Lib/ |
D | op_fully_connected.py | 82 weights = np.random.randint(minval, maxval, size=shapes["weight_shape"]) 84 uneven = weights.size % 2 86 weights = np.append(weights, 0) 88 temp = np.reshape(weights, (weights.size // 2, 2)).astype(np.uint8) 89 weights = 0xff & ((0xf0 & (temp[:, 1] << 4)) | (temp[:, 0] & 0xf)) 90 tensors["input_weights"] = weights
|
D | op_conv.py | 88 weights = Lib.op_utils.generate_tf_tensor( 94 conv_layer.set_weights([weights, bias]) 96 conv_layer.set_weights([weights])
|
D | op_lstm.py | 68 model.layers[1 + time_major_offset].weights[0].assign(input_weights) 71 model.layers[1 + time_major_offset].weights[1].assign(hidden_weights) 74 model.layers[1 + time_major_offset].weights[2].assign(biases)
|
/cmsis-nn-latest/ |
D | README.md | 41 * int4 weights + int8 activations
|