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
eac4aecc
Unverified
Commit
eac4aecc
authored
Jan 24, 2022
by
Nicolas Patry
Committed by
GitHub
Jan 24, 2022
Browse files
Remove old debug code leftover. (#15306)
parent
2390b2cf
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
1 addition
and
6 deletions
+1
-6
src/transformers/pipelines/automatic_speech_recognition.py
src/transformers/pipelines/automatic_speech_recognition.py
+1
-6
No files found.
src/transformers/pipelines/automatic_speech_recognition.py
View file @
eac4aecc
...
@@ -300,12 +300,7 @@ class AutomaticSpeechRecognitionPipeline(ChunkPipeline):
...
@@ -300,12 +300,7 @@ class AutomaticSpeechRecognitionPipeline(ChunkPipeline):
logits
=
outputs
[
"logits"
].
numpy
()
logits
=
outputs
[
"logits"
].
numpy
()
stride
=
outputs
.
get
(
"stride"
,
None
)
stride
=
outputs
.
get
(
"stride"
,
None
)
if
stride
is
not
None
:
if
stride
is
not
None
:
try
:
total_n
,
left
,
right
=
stride
total_n
,
left
,
right
=
stride
except
Exception
:
import
ipdb
ipdb
.
set_trace
()
# Total_n might be < logits.shape[1]
# Total_n might be < logits.shape[1]
# because of padding, that's why
# because of padding, that's why
# we need to reconstruct this information
# we need to reconstruct this information
...
...
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