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

Cython Wrapping A Class That Uses Another Library

I've got some C++ code dbscan.cpp and dbscan.h that work great standalone. Now I'm trying t… Read more Cython Wrapping A Class That Uses Another Library

Building Minimal Cython File With Python 3.3 (anaconda) Under Windows 7

When I try to build a minimal Cython file test.pyx with Python 3.3 (Anaconda 3) under windows 7, I … Read more Building Minimal Cython File With Python 3.3 (anaconda) Under Windows 7

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

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

Cython C++ Wrapper Operator() Overloading Error

Connected with my previous question. Using Cython to wrap a C++ class that uses OpenCV types as pa… Read more Cython C++ Wrapper Operator() Overloading Error

Tutorials On Optimizing Non-trivial Python Applications With C Extensions Or Cython

The Python community has published helpful reference material showing how to profile Python code, a… Read more Tutorials On Optimizing Non-trivial Python Applications With C Extensions Or Cython

Passing 3d Numpy Array From Cython To C++

I recently used cython to speedup an application, and now struggle with passing a 3D numpy array fr… Read more Passing 3d Numpy Array From Cython To C++

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 Dynamic Library Linking

I'm actually trying to link an existing C library to my Cython program. I have access to the en… Read more Cython Dynamic Library Linking

Estimating Determinant Using Lapack Wrapper For Lu Decomposition In Cython

I define the function that calculates the determinant of a matrix here. But sometimes I get the wro… Read more Estimating Determinant Using Lapack Wrapper For Lu Decomposition In Cython

Passing List Of Numpy Arrays To C Using Cython

I have a list list_of_arrays of 3D numpy arrays that I want to pass to a C function with the templa… Read more Passing List Of Numpy Arrays To C Using Cython

Importing Cython Generated *.so-module With Another Python-version Or On Another Os

How should a file myModule.cpython-35m-x86_64-linux-gnu.so be imported in python? Is it possible? I… Read more Importing Cython Generated *.so-module With Another Python-version Or On Another Os

Call Python Function In C Code

i written small code like addition for two numbers in python. addition.py def add(a,b): c=… Read more Call Python Function In C Code

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

Confusing Reference Ownership: How To Properly Deallocate (via Py_decref) Objects Of An Object?

I was analysing the following code, which compiles and runs correctly, but generates a memory leak.… Read more Confusing Reference Ownership: How To Properly Deallocate (via Py_decref) Objects Of An Object?

Why Cython Compiler Generates A So With Suffix 'cpython-35m-x86_64-linux-gnu.so'

#setup.py from distutils.core import setup from distutils.extension import Extension from Cytho… Read more Why Cython Compiler Generates A So With Suffix 'cpython-35m-x86_64-linux-gnu.so'

Writing Cython Extension: How To Access A C Struct Internal Data From Python?

Disclaimer: I took the following example from the Python Cookbook (O'Reilly). Let's say I h… Read more Writing Cython Extension: How To Access A C Struct Internal Data From Python?

Using Numpy.array In Cython

I want to rewrite a class in cython format and save it as demo.pyx. The input parameter for the cla… Read more Using Numpy.array In Cython

Are Executables Produced With Cython Really Free Of The Source Code?

I have read Making an executable in Cython and BuvinJ's answer to How to obfuscate Python code … Read more Are Executables Produced With Cython Really Free Of The Source Code?

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