Hello Serge, Do you mean pieces of code you wrote in Python using Numpy that you want to transform to Smalltalk code using PolyMath?
It’s kind of the other way around of this project. :-) Julien --- Julien Delplanque Doctorant à l’Université de Lille 1 http://juliendelplanque.be/phd.html Equipe Rmod, Inria Bâtiment B 40, avenue Halley 59650 Villeneuve d'Ascq Numéro de téléphone: +333 59 35 86 40 > Le 10 janv. 2018 à 14:07, Serge Stinckwich <serge.stinckw...@gmail.com> a > écrit : > > Thank you Julien for this very interesting piece of code. > What I need at the moment is a way to transform semi-automatically Numpy code > to PolyMath code ... > > On Mon, Jan 1, 2018 at 8:22 PM, Julien <julien.delplan...@inria.fr > <mailto:julien.delplan...@inria.fr>> wrote: > Hello, > > My new year main resolution: stop keeping my side-projects for me. > > It’s been like 1 year that I created these two projects, one coming from a > refactoring of the other. > Now it is time to take time to announce them. > > I initially come from Python world and during my bachelor & master, I really > liked to use matplotlib to plot data using Python. > > So I wanted to be able to use this Python module from Pharo. I did it by > generating Python 3 code from Pharo and making Python 3 executing it. So, > first I implemented everything in MatplotLibBridge package and then I split > it in two package in order to be able to eventually create bridges to other > Python 3 modules. > > So, Python3Generator [1] is made for generating programatically Python 3 code > from Pharo. Basically, it allows you to easily build a Python 3 AST, to > serialize it in Python 3 source code and eventually to execute it. For now > you can transfer data from Pharo to Python (e.g. providing arguments to > functions that are Pharo’s objects) but you can not retrieve data stored in > Python variable from Pharo (but it should be possible, just I don’t need to > do that for my bridge to matplotlib). Some examples are provided on the > github’s README. > > MatplotLibBridge [2] is made for creating plots using matplotlib [3] from > Pharo. There is a bunch of examples of what you can do on the README. The two > features from matplotlib I like the most are: 1. You can generate your plot > in a lot of file formats (png, pdf, svg, ps, etc…) 2. It allows to embed > LaTeX mathematical formulae everywhere in the plot (which can be really > cool). All the possible plots in matplotlib are not available in Pharo’s side > because I build parts of the bridge when I need them but it is not hard to > do. I someone is interested in a plot type not available yet, please tell me. > > So, it is announced, if someone want to do something with those, please do it! > > Happy new year. > > Regards, > > Julien > > [1]: https://github.com/juliendelplanque/Python3Generator > <https://github.com/juliendelplanque/Python3Generator> > [2]: https://github.com/juliendelplanque/MatplotLibBridge > <https://github.com/juliendelplanque/MatplotLibBridge> > [3]: https://matplotlib.org <https://matplotlib.org/> > > --- > Julien Delplanque > Doctorant à l’Université de Lille 1 > http://juliendelplanque.be/phd.html <http://juliendelplanque.be/phd.html> > Equipe Rmod, Inria > Bâtiment B 40, avenue Halley 59650 > <https://maps.google.com/?q=40,+avenue+Halley+59650%C2%A0Villeneuve%C2%A0d'Ascq&entry=gmail&source=g> > Villeneuve > <https://maps.google.com/?q=40,+avenue+Halley+59650%C2%A0Villeneuve%C2%A0d'Ascq&entry=gmail&source=g> > d'Ascq > <https://maps.google.com/?q=40,+avenue+Halley+59650%C2%A0Villeneuve%C2%A0d'Ascq&entry=gmail&source=g> > Numéro de téléphone: +333 59 35 86 40 <tel:+33%203%2059%2035%2086%2040> > > > > -- > Serge Stinckwich > UMI UMMISCO 209 (IRD/UPMC/UY1) > "Programs must be written for people to read, and only incidentally for > machines to execute." > http://www.doesnotunderstand.org/ <http://www.doesnotunderstand.org/>