Skip to content

[MPS] Add support for aten::unique_consecutive for MPS backend  #88487

@iam-lazycoder

Description

@iam-lazycoder

🐛 Describe the bug

classifier = pipeline("zero-shot-classification",
                      model="facebook/bart-large-mnli", device = torch.device("mps"))
candidate_labels = ['label1', 'label2', 'label3'] #list of labels to tag
classifier("SAMPLE TEXT INPUT" , candidate_labels)
NotImplementedError: The operator 'aten::unique_consecutive' is not current implemented for the MPS device. If you want this op to be added in priority during the prototype phase of this feature, please comment on https://github.com/pytorch/pytorch/issues/77764. As a temporary fix, you can set the environment variable `PYTORCH_ENABLE_MPS_FALLBACK=1` to use the CPU as a fallback for this op. WARNING: this will be slower than running natively on MPS.

Versions

NA

cc @kulinseth @albanD @malfet @DenisVieriu97 @razarmehr @abhudev

Metadata

Metadata

Assignees

No one assigned

    Labels

    module: mpsRelated to Apple Metal Performance Shaders frameworktriagedThis issue has been looked at a team member, and triaged and prioritized into an appropriate module

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions