Skip to content

Commit

Permalink
ensures int arguments to np.reshape; closes #383
Browse files Browse the repository at this point in the history
  • Loading branch information
tyarkoni committed Jan 16, 2017
1 parent d4c9c37 commit 814b776
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion moviepy/audio/io/readers.py
Original file line number Diff line number Diff line change
Expand Up @@ -119,7 +119,7 @@ def read_chunk(self,chunksize):
dt = {1: 'int8',2:'int16',4:'int32'}[self.nbytes]
result = np.fromstring(s, dtype=dt)
result = (1.0*result / 2**(8*self.nbytes-1)).\
reshape((len(result)/self.nchannels,
reshape((int(len(result)/self.nchannels),
self.nchannels))
#self.proc.stdout.flush()
self.pos = self.pos+chunksize
Expand Down

0 comments on commit 814b776

Please sign in to comment.