Skip to content

Commit

Permalink
fix: fix an error in open_clip (#748)
Browse files Browse the repository at this point in the history
  • Loading branch information
XixinYang authored Nov 25, 2023
1 parent 8d3ce84 commit 9c6dc67
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions examples/open_clip/src/open_clip/model.py
Original file line number Diff line number Diff line change
Expand Up @@ -147,9 +147,9 @@ def __init__(
self.ln_final = text.ln_final
self.text_projection = text.text_projection
self.attn_mask = text.attn_mask
self.logit_scale = Parameter(ops.ones([]) * init_logit_scale)
self.logit_scale = Parameter(ops.ones(()) * init_logit_scale)
if init_logit_bias is not None:
self.logit_bias = Parameter(ops.ones([]) * init_logit_bias)
self.logit_bias = Parameter(ops.ones(()) * init_logit_bias)
else:
self.logit_bias = None

Expand Down

0 comments on commit 9c6dc67

Please sign in to comment.