Skip to content

Commit

Permalink
👽 Remove _bound suffix from .to_pyarray_bounds
Browse files Browse the repository at this point in the history
PyO3 0.23 completes the removal of the "GIL Refs" API, so the "Bound" API functions which had been introduced with _bound suffixes are no longer needed. Xref https://pyo3.rs/v0.23.2/migration#gil-refs-feature-removed
  • Loading branch information
weiji14 committed Nov 28, 2024
1 parent 9a6de0e commit 5525637
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/python/adapters.rs
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ impl PyCogReader {
.map_err(|err| PyValueError::new_err(err.to_string()))?;

// Convert from ndarray (Rust) to numpy ndarray (Python)
Ok(array_data.to_pyarray_bound(py))
Ok(array_data.to_pyarray(py))
}

/// Get x and y coordinates as numpy.ndarray
Expand All @@ -80,7 +80,7 @@ impl PyCogReader {
.xy_coords()
.map_err(|err| PyValueError::new_err(err.to_string()))?;

Ok((x_coords.to_pyarray_bound(py), y_coords.to_pyarray_bound(py)))
Ok((x_coords.to_pyarray(py), y_coords.to_pyarray(py)))
}
}

Expand Down

0 comments on commit 5525637

Please sign in to comment.