mirror of
https://github.com/openai/CLIP.git
synced 2026-11-05 01:37:26 +00:00
[GH-ISSUE #386] Missing of a type conversion in model.py #333
Labels
No labels
pull-request
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
openai/CLIP#333
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @GXZlegend on GitHub (Sep 12, 2023).
Original GitHub issue: https://github.com/openai/CLIP/issues/386
There seems to miss a type conversion in the forward process of
VisionTransformer, inclip/model.py. The direct forward pass without pre-conversion (Line 342) would cause error of type mismatch.As a reference, in Line 146 there is an explicit type conversion in
ModifiedResNet.Is it possible to add conversion
x = x.type(self.conv1.weight.dtype)between Line 223-224?