Gets tensor details for every tensor with valid tensor details. Tensors where required information about the tensor is not found are not added to the list. This includes temporary tensors without a name. Returns: A list of dictionaries containing tensor information.
(self)
| 303 | return details |
| 304 | |
| 305 | def get_tensor_details(self): |
| 306 | """Gets tensor details for every tensor with valid tensor details. |
| 307 | |
| 308 | Tensors where required information about the tensor is not found are not |
| 309 | added to the list. This includes temporary tensors without a name. |
| 310 | |
| 311 | Returns: |
| 312 | A list of dictionaries containing tensor information. |
| 313 | """ |
| 314 | tensor_details = [] |
| 315 | for idx in range(self._interpreter.NumTensors()): |
| 316 | try: |
| 317 | tensor_details.append(self._get_tensor_details(idx)) |
| 318 | except ValueError: |
| 319 | pass |
| 320 | return tensor_details |
| 321 | |
| 322 | def get_input_details(self): |
| 323 | """Gets model input details. |