Skip to content

Commit

Permalink
fix: vitclip16 requires 224 input size
Browse files Browse the repository at this point in the history
  • Loading branch information
beniz committed Mar 7, 2023
1 parent d83f040 commit 8b8bb67
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions options/base_options.py
Original file line number Diff line number Diff line change
Expand Up @@ -898,6 +898,14 @@ def _after_parse(self, opt, set_device=True):
"Bounding box class selection requires --data_sanitize_paths"
)

# vitclip16 projector only works with input size 224
if opt.D_proj_network_type == "vitclip16":
if opt.D_proj_interp != 224:
warnings.warn(
"ViT-B/16 (vitclip16) projector only works with input size 224, setting D_proj_interp to 224"
)
opt.D_proj_interp = 224

self.opt = opt

return self.opt
Expand Down

0 comments on commit 8b8bb67

Please sign in to comment.