Add dunder method for Arrow C Data Interface to DataFrame and Column objects
Nessuno ha ancora preso questa issue.
Valutazione
- Difficoltà
- 5/5
- Tempo stimato
- Più di una settimana
- Idoneità per principianti
- 25/100
Direzione di ricerca
Leggi la documentazione di PyCapsule C Data Interface indicata e le discussioni su DataFrame interchange nelle issues 250 e 48. Poi esamina le definizioni degli oggetti di interscambio DataFrame e Column. Il lavoro è completato quando la decisione sul protocollo e i metodi Arrow opzionali sono specificati in modo coerente per entrambi gli oggetti, incluso il comportamento con più chunks.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Descrizione
The Python Arrow community is adding a public way to interchange data through the C Data Interface, using PyCapsule objects holding the C struct, similary as DLPack's python interface: http://crossbow.voltrondata.com/pr_docs/37797/format/CDataInterface/PyCapsuleInterface.html
We have DLPack support at the Buffer level, and similarly, I think it would be useful to add Arrow support at the DataFrame and Column level.
Concretely, I would propose adding an optional __arrow_c_schema__, __arrow_c_array__ and __arrow_c_stream__ methods to both the DataFrame and Column interchange objects. Those methods would be optional, with their presence indicating that this specific implementation of the interchange object supports the Arrow interface.
Consumers of the interchange protocol could then check for the presence of those methods, and try them first for an easier and faster conversion, and otherwise use the standard APIs through the Column and Buffer objects (example: pyarrow and polars interchanging data).
It might be a bit strange to add both the array and stream interface methods, but that is due to that the interchange protocol hasn't really made a distinction between a single chunk vs a chunked object (https://github.com/data-apis/dataframe-api/issues/250). But I think the array method could then raise an error if the DataFrame or Column still exists of more than 1 chunk.
This would address https://github.com/data-apis/dataframe-api/issues/48 but without being tied to a specific library implementation, but solely memory layout.
- Lingua principale
- Python
- Stelle
- 106
- Fork
- 22
- Metriche di merge delle PR
- Nessuna PR unita negli ultimi 30g
Preparare l'ambiente
Questo progetto non fornisce container di sviluppo, Dockerfile né guida per i contributori, quindi l'ambiente è a tuo carico: parti dal suo README e consulta la nostra guida al primo contributo per i passaggi generali.
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Altre issue di data-apis/dataframe-api
-
Difficoltà 5/5 Più di una settimana Idoneità per principianti 25/100
data-apis/dataframe-api#363 · 1 commento · 8 reazioni ·
-
Row ordering design choiceApertaAPI design
Difficoltà 5/5 Più di una settimana Idoneità per principianti 25/100
data-apis/dataframe-api#356 · 1 commento ·
-
Difficoltà 4/5 3-5 giorni Idoneità per principianti 25/100
data-apis/dataframe-api#355 ·
-
Difficoltà 5/5 Più di una settimana Idoneità per principianti 25/100
data-apis/dataframe-api#352 ·
-
Difficoltà 5/5 Più di una settimana Idoneità per principianti 25/100
data-apis/dataframe-api#351 ·
Tutte le issue di data-apis/dataframe-api
Issue simili
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 72/100
NousResearch/hermes-agent#136483 ·
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 88/100
I maintainer di solito rispondono entro 1 giorno
-
[BUG] LazyStackedTensorDictStore zeroes the last byte of a new key set on the last elementForse già presa @peterdsharpe l’ha presa oggi. Apertabug
Difficoltà 2/5 1-3 ore Idoneità per principianti 78/100
pytorch/tensordict#2307 ·
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 78/100
I maintainer di solito rispondono entro 1 giorno
-
GrokModel.generate/a_generate pass an OpenAI-style list-of-dicts to xai_sdk.chat.user(), so every call crashes with a protobuf TypeError before any network I/OForse già presa @Christian-Sidak l’ha presa oggi. Aperta
Difficoltà 2/5 1-3 ore Idoneità per principianti 70/100
confident-ai/deepeval#3436 · 1 commento ·
I maintainer di solito rispondono entro 1 giorno