(self, value: torch.Tensor)
| 122 | |
| 123 | class MyExporter(OnnxExporter): |
| 124 | def convert_value(self, value: torch.Tensor) -> str: |
| 125 | if type(value) in {int, float}: return value |
| 126 | else: |
| 127 | value = convert_any_to_numpy(value, accept_none=True) |
| 128 | if value is None: return value # SOI config has Nona as its scale and |
| 129 | return value.tolist() |
| 130 | |
| 131 | def export(self, file_path: str, graph: BaseGraph, config_path: str, **kwargs): |
| 132 | # ------------------------------------------------------------ |
no test coverage detected