Skip to content

Commit

Permalink
Cleanup.
Browse files Browse the repository at this point in the history
  • Loading branch information
LaurentMazare committed Dec 20, 2024
1 parent e1c2911 commit 0f2edf4
Showing 1 changed file with 1 addition and 6 deletions.
7 changes: 1 addition & 6 deletions src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -81,12 +81,7 @@ impl FileReader {
fn decode(&mut self, start_sec: f64, duration_sec: f64, py: Python) -> PyResult<PyObject> {
let (data, _unpadded_len) =
self.inner.decode(start_sec, duration_sec, false).w_f(&self.path)?;
Ok(numpy::PyArray2::from_vec2(py, &data)
.unwrap()
.into_pyobject(py)
.unwrap()
.into_any()
.unbind())
Ok(numpy::PyArray2::from_vec2(py, &data)?.into_any().unbind())
}

/// Decodes the audio data from `start_sec` to `start_sec + duration_sec` and return the PCM
Expand Down

0 comments on commit 0f2edf4

Please sign in to comment.