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
64ec802e
Unverified
Commit
64ec802e
authored
Apr 21, 2023
by
Yusong Wu
Committed by
GitHub
Apr 21, 2023
Browse files
fix bug of CLAP dataloader (#22674)
fix bug of CLAP:
https://github.com/LAION-AI/CLAP/issues/62
parent
3db2e404
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
1 addition
and
1 deletion
+1
-1
src/transformers/models/clap/feature_extraction_clap.py
src/transformers/models/clap/feature_extraction_clap.py
+1
-1
No files found.
src/transformers/models/clap/feature_extraction_clap.py
View file @
64ec802e
...
...
@@ -194,7 +194,7 @@ class ClapFeatureExtractor(SequenceFeatureExtractor):
mel
,
size
=
[
chunk_frames
,
64
],
mode
=
"bilinear"
,
align_corners
=
False
,
antialias
=
False
)
mel_shrink
=
mel_shrink
[
0
][
0
].
numpy
()
mel_fusion
=
np
.
stack
([
mel_chunk_front
,
mel_chunk_middle
,
mel_chunk_back
,
mel_shrink
],
axis
=
0
)
mel_fusion
=
np
.
stack
([
mel_shrink
,
mel_chunk_front
,
mel_chunk_middle
,
mel_chunk_back
],
axis
=
0
)
return
mel_fusion
def
_get_input_mel
(
self
,
waveform
:
np
.
array
,
max_length
,
truncation
,
padding
)
->
np
.
array
:
...
...
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