Skip to content Skip to sidebar Skip to footer
Showing posts with the label Python C Extension

Python C Extension: Pyeval_getlocals() Returns Null

I need to read local variables from Python in C/C++. When I try to PyEval_GetLocals, I get a NULL. … Read more Python C Extension: Pyeval_getlocals() Returns Null

How To Package A Python C Extension Such That It Is A Submodule Of A Normal Python Module?

I wrote a python library with two parts: A Python C extension A Python wrapper for the Python C ex… Read more How To Package A Python C Extension Such That It Is A Submodule Of A Normal Python Module?

Obtaining Address Of Custom Data-type In C From Python Using Ctypes

I have a vector struct in C with the following fields, struct vector { unsigned char* data; … Read more Obtaining Address Of Custom Data-type In C From Python Using Ctypes

Implementing Nb_inplace_add Results In Returning A Read-only Buffer Object

I'm writing an implementation of the in-place add operation. But, for some reason, I sometimes … Read more Implementing Nb_inplace_add Results In Returning A Read-only Buffer Object

Obtaining Address Of Custom Data-type In C From Python Using Ctypes

I have a vector struct in C with the following fields, struct vector { unsigned char* data; … Read more Obtaining Address Of Custom Data-type In C From Python Using Ctypes