Skip to content

Commit

Permalink
Use generator expression instead of making a list
Browse files Browse the repository at this point in the history
  • Loading branch information
carlthome committed Apr 4, 2017
1 parent 3e23d5b commit be5eeb9
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion librosa/core/constantq.py
Original file line number Diff line number Diff line change
Expand Up @@ -556,7 +556,7 @@ def __trim_stack(cqt_resp, n_bins):
'''Helper function to trim and stack a collection of CQT responses'''

# cleanup any framing errors at the boundaries
max_col = min([x.shape[1] for x in cqt_resp])
max_col = min(x.shape[1] for x in cqt_resp)

cqt_resp = np.vstack([x[:, :max_col] for x in cqt_resp][::-1])

Expand Down

0 comments on commit be5eeb9

Please sign in to comment.