blog page - 1/1¶
Issues with installation from source on Windows¶
2021-01-04
The installation may fail on Windows when the model is compiled from the source. I could not find a particular reason. It works when numpy is uninstalled before running pip install cpyquickhelper. Otherwise, this is the kind of error which appear:
…
cppyy: a new module for to C++ in python¶
Mixing pybind11 modules¶
2019-03-19
My scenario was the following: expose a C++ class in one C++ module exported with pybind11, then create a function in a another C++ module returning a result of this class. The solution for that is described in the following issue Return type that is implemented in another library with another set of python bindings, which links to this part of the documentation Custom type casters. and implemented in this module somewhere in cbenchmark_dot.cpp.
Branching¶
2019-02-04
I wanted to test some facts described in the following blog post: Why is it faster to process a sorted array than an unsorted array?. I ended it writing this notebook Measures branching in C++ from python which compares a couple of implementations of the same computation, a dot product.
Cython, Pythran, nuitka, numba¶
2018-08-05
I discovered than Pythran was now a possible backend for Cython: Pythran as a Numpy backend. On one benchmark, it increases the speed by 2. I recommend the reading of the following article: Optimizing your code with NumPy, Cython, pythran and numba which instigates the performance brought by the four following tool and gives some hints on how to write efficient code with these tools:
…
Exploration with pybind11 and ExtensionArray¶
2018-08-03
I tried the version of pybind11
to expose a dummy C++ object
WeightedDouble
,
to implement a couple of operators and to see
how it behaves into a dataframe.
…
Call C# from Python¶
2017-09-17
A couple of questions must be answers to do that.
…
blog page - 1/1 2018-08 (2) 2019-02 (1) 2019-03 (1) 2019-09 (1) 2021-01 (1)