PyO3/pyo3

Expand performance section of the guide

Aperta

#3310 aperta il 11 lug 2023

 (8 commenti) (4 reazioni) (0 assegnatari)Rust (668 fork)batch import
Good First Issue

Metriche repository

Star
 (10.152 stelle)
Metriche merge PR
 (Merge medio 9g 18h) (51 PR mergiate in 30 g)

Descrizione

  • Overhead of conversions (i.e. PyList vs Vec etc.)
  • String intern!
  • Vec<u8> becoming list[int] (and thus being very slow), usage of Cow<[u8]> as an alternative
  • #[pyo3(get)] deep-cloning non-Py data
  • dictionary dispatch, i.e. look-up based on type object identity

Guida contributor