Skip to content

[CLIP] cannot import name '_expand_mask' #603

@denis-ismailaj

Description

@denis-ismailaj

The _expand_mask function that is imported from transformers.models.clip.modeling_clip in models/blip_diffusion_models/modeling_ctx_clip.py does not exist anymore since this commit that is part of release v4.35.0.

It has since been replaced with transformers.modeling_attn_mask_utils._prepare_4d_attention_mask.

There is another closed issue ( #571 ) in this repo regarding this error, but there is not enough information to tell whether using transformers>=4.35 was the cause of that one too.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions