Skip to content Skip to sidebar Skip to footer
Showing posts with the label Cython

Does Python Bytearray Use Signed Integers In The C Representation?

I have written a small Cython tool for in-place sorting of structures exposing the buffer protocol … Read more Does Python Bytearray Use Signed Integers In The C Representation?

Cython Parallel Openmp For Black Scholes With Numpy Integrated, Serial Code 10m Options 3.5s, Parallel?

Here is the Black (Black Scholes less the dividend) option pricing model for options on futures wri… Read more Cython Parallel Openmp For Black Scholes With Numpy Integrated, Serial Code 10m Options 3.5s, Parallel?

Cython - Iterate Through Map

I was wondering if this was possible to iterate through a map directly in Cython code, ie, in the .… Read more Cython - Iterate Through Map

Options For Callback From Python To C++

Hello i've been trying to call a python user-defined callback from c++ using cython for a while… Read more Options For Callback From Python To C++

Calling Blas / Lapack Directly Using The Scipy Interface And Cython

There was a post on this here: https://gist.github.com/JonathanRaiman/f2ce5331750da7b2d4e9 which sh… Read more Calling Blas / Lapack Directly Using The Scipy Interface And Cython

Force Compiler When Running Python Setup.py Install

Is there a way to explicitly force the compiler for building Cython extensions when running python … Read more Force Compiler When Running Python Setup.py Install

Can't Redirect Error Stream From Cython

The SFML library that I'm trying to cythonize defines this function below that allows to change… Read more Can't Redirect Error Stream From Cython

How Do I Use The Correct Dll Files To Enable 3rd Party C Libraries In A Cython C Extension?

I have a C function that involves decompressing data using zstd. I am attempting to call that funct… Read more How Do I Use The Correct Dll Files To Enable 3rd Party C Libraries In A Cython C Extension?

Fastest Way To Parse Json Strings Into Numpy Arrays

I have huge json objects containing 2D lists of coordinates that I need to transform into numpy arr… Read more Fastest Way To Parse Json Strings Into Numpy Arrays

Renamed .c Files To .cpp, Importing Cython Library Fails

I had a working Cython program which wrapped some C libraries and custom C code. Recently, I had to… Read more Renamed .c Files To .cpp, Importing Cython Library Fails

Passing/returning Cython Memoryviews Vs Numpy Arrays

I am writing Python code to accelerate a region properties function for labeled objects in a binary… Read more Passing/returning Cython Memoryviews Vs Numpy Arrays

Cython: Understanding What The Html Annotation File Has To Say?

After compiling the following Cython code, I get the html file that looks like this: import numpy a… Read more Cython: Understanding What The Html Annotation File Has To Say?

Cython Buffer Declarations For Object Members

I want to have a Cython 'cdef' object with a NumPy member, and be able to use fast buffer a… Read more Cython Buffer Declarations For Object Members

Skip Numpy __new__ In Ndarray Subclass (or Possibly Overriding/defining Classes In C Or Cython)

Ultimate goal: have isinstance(MyClass(), np.ndarray) and issubclass(MyClass, np.ndarray) both retu… Read more Skip Numpy __new__ In Ndarray Subclass (or Possibly Overriding/defining Classes In C Or Cython)

Pep-484 Type Annotations With Own Types

PEP-484 provides semantics for type annotations. These are geared very much towards a) documentatio… Read more Pep-484 Type Annotations With Own Types

Calling C++ Code From Python Using Cython Whith The Distutilis Approach

I am trying to call a c++ code from a python script using cython. I already managed to work with an… Read more Calling C++ Code From Python Using Cython Whith The Distutilis Approach

Pass A Cython Allocated Buffer To Python

I am aware of this post about passing over Cython malloc'ed data to Python. I however wonder if… Read more Pass A Cython Allocated Buffer To Python

Passing And Returning Numpy Arrays To C++ Methods Via Cython

There are lots of questions about using numpy in cython on this site, a particularly useful one bei… Read more Passing And Returning Numpy Arrays To C++ Methods Via Cython

Undefined Symbol In Cython Module When Using Mlpack

I met the problem 'undefined symbol' when using mlpack in Cython. Here is my test case: cde… Read more Undefined Symbol In Cython Module When Using Mlpack

Cython Fatal Error: Python.h No Such File Or Directory

I have been using Cython to compile my Python files into C files and then use MinGW to create an ex… Read more Cython Fatal Error: Python.h No Such File Or Directory