Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
chenpangpang
transformers
Commits
658e5d8f
"git@developer.sourcefind.cn:chenpangpang/transformers.git" did not exist on "9cf4a8b45668cbcb1bb10ad61d9a9c2c27ab9890"
Unverified
Commit
658e5d8f
authored
Nov 23, 2022
by
Younes Belkada
Committed by
GitHub
Nov 23, 2022
Browse files
make daily CI happy (#20410)
parent
81c46679
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
1 deletion
+2
-1
src/transformers/models/owlvit/modeling_owlvit.py
src/transformers/models/owlvit/modeling_owlvit.py
+2
-1
No files found.
src/transformers/models/owlvit/modeling_owlvit.py
View file @
658e5d8f
...
@@ -1475,9 +1475,10 @@ class OwlViTForObjectDetection(OwlViTPreTrainedModel):
...
@@ -1475,9 +1475,10 @@ class OwlViTForObjectDetection(OwlViTPreTrainedModel):
# Loop over query images
# Loop over query images
best_class_embeds
=
[]
best_class_embeds
=
[]
best_box_indices
=
[]
best_box_indices
=
[]
pred_boxes_device
=
pred_boxes_as_corners
.
device
for
i
in
range
(
query_image_features
.
shape
[
0
]):
for
i
in
range
(
query_image_features
.
shape
[
0
]):
each_query_box
=
torch
.
tensor
([[
0
,
0
,
1
,
1
]])
each_query_box
=
torch
.
tensor
([[
0
,
0
,
1
,
1
]]
,
device
=
pred_boxes_device
)
each_query_pred_boxes
=
pred_boxes_as_corners
[
i
]
each_query_pred_boxes
=
pred_boxes_as_corners
[
i
]
ious
,
_
=
box_iou
(
each_query_box
,
each_query_pred_boxes
)
ious
,
_
=
box_iou
(
each_query_box
,
each_query_pred_boxes
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment