Skip to content

About Code #7

@Jchim1102

Description

@Jchim1102

Thank you very much for your answers to the first two questions! However, I have a new question: Is this complete and correct code?
But when I run train.py, I get the following error:

"...model.py", line 106, in forward
_, class_embs = self.clip.get_text_embeddings(class_names)
ValueError: too many values ​​to unpack (expected 2)

When I try to remove the "_," it becomes:

def forward(self, image, image_aux, class_names):
class_embs = self.clip.get_text_embeddings(class_names)
return self.forward_pass(image, image_aux, class_embs)

Another error:
"...lib/python3.10/site-packages/torch/nn/modules/linear.py", line 114, in forward
return F.linear(input, self.weight, self.bias)
RuntimeError: mat1 and mat2 shapes cannot be multiplied (6912x512 and 768x640)

I did not modify any of the model's code!
./CGNet/model.py

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions