Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.python.announce > #2878 > unrolled thread

Pythran - 0.8.6

Started bySerge Guelton <serge.guelton@telecom-bretagne.eu>
First post2018-06-07 14:01 +0200
Last post2018-06-07 14:01 +0200
Articles 1 — 1 participant

Back to article view | Back to comp.lang.python.announce

This discussion starts older than the indexed window; earlier articles aren't shown. The article labeled Started by below is the oldest one visible, not the original post.


Contents

  Pythran - 0.8.6 Serge Guelton <serge.guelton@telecom-bretagne.eu> - 2018-06-07 14:01 +0200

#2878 — Pythran - 0.8.6

FromSerge Guelton <serge.guelton@telecom-bretagne.eu>
Date2018-06-07 14:01 +0200
SubjectPythran - 0.8.6
Message-ID<mailman.28.1528373765.22129.python-announce-list@python.org>
Hi there,

Pythran just released its 0.8.6 version. A quick reminder: Pythran is a
compiler for scientific Python, it can be used to turn Python kernels
as:


    #pythran export _brief_loop(float64[:,:], uint8[:,:], intp[:,:], int[:,:], int[:,:])
    def _brief_loop(image, descriptors, keypoints, pos0, pos1):

        for k in range(len(keypoints)):
            kr, kc = keypoints[k]
            for p in range(len(pos0)):
                pr0, pc0 = pos0[p]
                pr1, pc1 = pos1[p]
                descriptors[k,p] = image[kr + pr0, kc + pc0] < image[kr + pr1, kc + pc1]

In a native library that runs much faster.

It's available on pypi: https://pypi.org/project/pythran/
on conda-forge (linux and osx): https://anaconda.org/conda-forge/pythran
and on github: https://github.com/serge-sans-paille/pythran

As a fun fact, Pythran is now used as a mean to turn Python code into
pure native library used in C++ code base, without Python involved. Some
people even use SWIG to turn this code into native libraries called
from... Java through JNI :-)

Enjoy,

Serge

[toc] | [standalone]


Back to top | Article view | comp.lang.python.announce


csiph-web