Isn't this solved by julia? I think scientific community should use a more functional language rather than language like python tbh
Or by modern Fortran, which has had array operations since the 1990 standard? There are functional elements such as PURE functions and the FORALL construct.
Pythran: Crossing the Python Frontier [pdf]
21–30 of 70 posts
Re: Pythran: Crossing the Python Frontier [pdf]
#22Isn't this solved by julia? I think scientific community should use a more functional language rather than language like python tbh
just as soon as someone who knows C/C++ ports numpy and scipy and pandas. and gensim and nltk and sounddevice. and tensorflow and scikit-learn and keras....
Re: Pythran: Crossing the Python Frontier [pdf]
#23Earlier quoted context omitted.
I believe the input should be a numpy array of floats which has a shape attribute
(shameful author here) One should read def rosen_explicit_loop(x): s = 0. n = x.shape[0] for i in range(0, n - 1): s += 100. * (x[i + 1] - x[i] ** 2.) ** 2. + (1 - x[i]) ** 2 return s (edited)
n = x.shape[0]Re: Pythran: Crossing the Python Frontier [pdf]
#24Isn't this solved by julia? I think scientific community should use a more functional language rather than language like python tbh
Re: Pythran: Crossing the Python Frontier [pdf]
#25Isn't this solved by julia? I think scientific community should use a more functional language rather than language like python tbh
just as soon as someone who knows C/C++ ports numpy and scipy and pandas. and gensim and nltk and sounddevice. and tensorflow and scikit-learn and keras....
Re: Pythran: Crossing the Python Frontier [pdf]
#26Isn't this solved by julia? I think scientific community should use a more functional language rather than language like python tbh
Re: Pythran: Crossing the Python Frontier [pdf]
#27Earlier quoted context omitted.
Could you elaborate more on the advantages of a functional language?
Scientific work should strive to be functional by definition (identical input == identical output), so I could see why a programing language should reflect that.
Any stochastic process will have variability for a given set of inputs. I think there are more fields within the umbrella of Science where purely functional programming isn't an achievable ideal--let alone a desirable one--than there are where this is a good fit.
You can make the argument that all programming should be functional on its own if you want, and I'm open to that. But this it's pretty sketchy to me to just shoehorn all scientific work into a category of work that should definitionally be functional.
There are huge numbers of scientists who do not agree with that at all.
Re: Pythran: Crossing the Python Frontier [pdf]
#28Isn't this solved by julia? I think scientific community should use a more functional language rather than language like python tbh
Or by modern Fortran, which has had array operations since the 1990 standard? There are functional elements such as PURE functions and the FORALL construct.
Re: Pythran: Crossing the Python Frontier [pdf]
#29Does anyone know how this compares to existing Python-to-C++ transpilers like Cython or Shedskin?
Shedskin and Pythran look somewhat similar to me (disclaimer: I've contributed quite a bit to Shedskin but have never used Pythran so far), except in Shedskin you don't even need annotations like with Pythran (the downside being the finer control you have of the native types used is through the transpiler options). Also, Shedskin development is not much active these days — to say the least — and there's zero support for Python 3, while Pythran is under fairly active development has beta support for Python 3.
If you're interested in Python / native implementations, you might be interested by Nuitka as well: http://nuitka.net/