Skip to content

Support for torch.linalg.lstsq operation #2084

@zack-dev-cm

Description

@zack-dev-cm

❓Question about torch.linalg.lstsq Operation Support

Summary

I am attempting to convert a PyTorch model that uses torch.linalg.lstsq to CoreML using coremltools, but it seems that this operation is not supported as well as other torch.linalg ops

Issue Details

When I try to convert my model, I get an error stating that torch.linalg is unsupported. This is causing significant issues as there doesn't seem to be a straightforward workaround.

Version

coremltools 7.1 Latest

Code Sample

ref, residuals, rank, singular_values = torch.linalg.lstsq(
        A_regul * weights_regul, b_regul * weights_regul)

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions