Yifan Shen
Yifan Shen
In [ExecuTorch PR 1802](https://github.com/pytorch/executorch/pull/1802), the const handling are changed: Some buffers are no longer available in `ExportedProgram.state_dict` However, CoreMLTools EXIR converter does rely on `ExportedProgram.state_dict` to retrieve all constants 🤦...
This is the root cause to many issues. When symbolic shape is involved in `torch.listconstruct`, instead of a CoreML tensor, we simply return the list as is ``` def _array_construct(context,...
This toy model fails to export in ExecuTorch ``` model = ModuleWrapper( function=nn.functional.scaled_dot_product_attention, kwargs={ "attn_mask": None, "is_causal": True, }, ) ``` due to ``` def assert_functional_graph(fx_g: torch.fx.Graph) -> int: placeholders...
This toy model fails in ExecuTorch ``` class IndexModel(torch.nn.Module): def __init__(self, axis): super().__init__() self.axis = axis def forward(self, x, y): index = y > 0.5 if self.axis == 0: return...
This toy model fails in ExecuTorch ``` class M(torch.nn.Module): def forward(self, float_arr, int_arr): dynamic_index = int_arr[1] float_arr[dynamic_index] = 12.95 return float_arr ``` due to ``` E torch._dynamo.exc.UserError: Consider annotating your...
## 🐞Describing the bug This simple model can be converted but gives incorrect result ``` class IndexPutModel(torch.nn.Module): def forward(self, x, position, val): y = x.clone() y[:, position] = val return...
Very weird, that some EXIR index put models fail only on neural network backend. Probably some neural network backend specific graph pass are wrong
This toy model fails in ExecuTorch ``` class IndexModel(torch.nn.Module): def forward(self, x): if len(shape) == 2: return x[:, :] elif len(shape) == 4: return x[:] ``` It contains only a...
## 🌱 Describe your Feature Request When we look at how CoreMLTools PyTorch converter deal with PyTorch data types in [utils.py](https://github.com/apple/coremltools/blob/main/coremltools/converters/mil/frontend/torch/utils.py#L19-L24) ``` NUM_TO_TORCH_DTYPE = { ... 2: torch.int16, 3: torch.int32,...
When we try to partition certain models on to Core ML delegation, we were hit by ``` ValueError: Rank-0 (input None) is unsupported ``` This is because Core ML does...