Given an index in the value list, if value is `Uninitialized` or is a mutable object, like a Tensor List, calls `load` to load and initialize value into Interpreter's value_list. Args: `idx` : index in value lists that we want to load Returns: No returned v
(self, idx: int)
| 179 | return tensors |
| 180 | |
| 181 | def load_value(self, idx: int) -> None: |
| 182 | """ |
| 183 | Given an index in the value list, if value is `Uninitialized` or is a mutable object, |
| 184 | like a Tensor List, calls `load` to load and initialize value into Interpreter's value_list. |
| 185 | |
| 186 | Args: |
| 187 | `idx` : index in value lists that we want to load |
| 188 | |
| 189 | Returns: No returned values - value list is updated in place |
| 190 | """ |
| 191 | # if instance of any mutable object, load regardless of being initialized |
| 192 | if isinstance( |
| 193 | self.execution_plan.values[idx].val, (TensorList, OptionalTensorList) |
| 194 | ) or isinstance(self._value_list[idx], Uninitialized): |
| 195 | self.load_from_value_list(idx) |
| 196 | |
| 197 | def load_from_value_list(self, idx: int) -> None: # noqa |
| 198 | """ |