[JAVA] Python Minor Environment Retsuden-How many Python environments do you know? ~

What is a Python minor environment?

When I was talking about Python in the company, I was talking about something like "There are a lot of Python environments, right?" And lightly saying something like "Yes, that's right", but surprisingly. There are few pages that summarize this "minor environment", so I tried to summarize the Python execution environment as far as I know. Here are some caveats.

--Allows not perfect as Python --Including Python transpiler --Including Python runtime environment

I will talk with a loose binding. Such a minor Python environment often doesn't work even with accurate Python. Or you may wonder, "What is Python?" When Python is converted to another language. We also handle things that "feel like Python is working". However, I hope you can see it, thinking that it is also the size of the skirt of Python (thing like space CQC).

CPython

image.png

https://www.python.org/ Number of articles on Qiita: 11075

It's not a minor environment at all, and it's completely the original home, so I don't think it's necessary to explain, but the first one I'll introduce is official. Please forgive me. For the time being, what is called "Python" usually refers to this CPython. It's very common, and you can be sure that it will come in if you install Python normally.

Jython

image.png

http://www.jython.org/ Number of articles on Qiita: 56

Yes. Python written in Java. It runs on the JVM. This is because the Python interpreter is built in Java, so you can run it in the form of jython filename.py. It's quite a bit squishy, but when I try it, it's surprisingly fun. Because you can use basic Java libraries, and GUI libraries such as Swing and AWT, you can dynamically arrange buttons on the interpreter of Python's interactive environment. Quite quite. It can make a metamorphic behavior. Surprisingly, development seems to be progressing, and it supports Python 2.7.

IronPython

image.png

http://ironpython.net/ Number of articles on Qiita: 31

Python that runs on Windows, Mono environment, and .Net Framework. It seems that it is implemented in C #. I've tried to touch it a long time ago, and now I can use IronPython in Visual Studio! There was a story like this, but since it could only be done with paid Visual Studio, it may be a Python execution environment that you do not touch after all. It's been around for quite some time, and it's been around since the .Net Framework compatible product called Mono came out, so I think it was a relatively old processing system.

Unladen Swallow

image.png

https://code.google.com/archive/p/unladen-swallow/ Number of articles on Qiita: 5

Personally, I read "Anladen Swaro" **. Around 2010, there was a story like "Let's make Python faster!", And it was a Python implementation system that came out at that time. Looking at it now, it was an aggressive attempt to compile JIT using LLVM as the back end. Development stopped without being incorporated into the original Python ... I didn't know much about it, but I introduced it because there was an interesting reading material.

Unladen Swallow memoirs

Stackless Python(Stackless)

image.png

https://bitbucket.org/stackless-dev/stackless/wiki/Home Number of articles on Qiita: 2

This is a Python implementation that I have rarely used (described later), but I see it in various places. The feature is that the stack does not depend on the C language call stack, but I have not received much benefit. It's rare to have a service with bitbucket. Moreover, it seems that development is still in progress.

Portable Python

image.png

http://portablepython.com/ Number of articles on Qiita: 1

It was a Python that was handy for me personally. What is convenient is that Python works just by placing one directory on a USB memory, and no internet environment is required. Normally, Python requires setting environment variables and installing it on the host PC, but since the development environment can be carried as it is, it was good to be able to write Python anywhere. However, now that I have an environment where I can write simple Python on the Web such as ideone, I don't need it anymore. Perhaps because of that, Portable Python itself is also closed? It looks like ... I think this backend was Stackless Python.

As you can see from the download page,

http://portablepython.com/wiki/PortablePython2.7.6.1/

It was also convenient that there was a library that could be used quite a bit just by downloading one.

pypy

image.png

http://pypy.org/ Number of articles on Qiita: 82

Python execution environment made with python. There used to be a jit library for python called psyco, which is the successor to it. In the past, I used to introduce psyco and pypy to maximize speed, but at that time I stopped because ctypes could not be used. Nowadays, I don't ask for speed, and sometimes I use a machine learning library that is natively extended by C, so there is not much merit in introducing it, so I still do not use it ...

PyMite(python-on-a-chip)

image.png

https://github.com/dwhall/p14p Number of articles on Qiita: ** 0 **

I heard a rumor that it was a Python implementation system to some extent, and it was an urban legend that "there is Python that runs on AVR", so I investigated it. It seems that it actually works, but it seems to be quite old ... I have never moved it, and I think that Arduino is better than touching AVR live, so I will not touch it in the future think···

tinypy

image.png

https://github.com/philhassey/tinypy/tree/master Number of articles on Qiita: ** 0 **

I do not know about this. I knew it for the first time by looking at the list of python implementations on wikipedia. In the explanation of wikipedia, it says that it is for embedded use, but it seems to be a mistake. Roughly speaking, it seems to be a processing system with py2exe and a binary size minimization function, and in the example, the one using pygame is presented, and the game made with pygame is built so that it becomes a binary of 64k or less. It seems. It's a minor, but I remember tcc (tiny c compiler) ...

Brython

image.png

http://www.brython.info/ Number of articles on Qiita: 7

A Python implementation using Javascript, which I personally think is a representative of Python. Python that runs in a browser. I think it's crazy, but if you look at the official code below, you can see how crazy it is.


<html>
<head>
<script src="/brython.js"></script>
</head>
<body onload="brython()">
<script type="text/python">
from browser import document, alert

def echo(ev):
    alert(document["zone"].value)

document['mybutton'].bind('click',echo)
</script>
<input id="zone"><button id="mybutton">click !</button>
</body>
</html>

** I'm not a translator. Python really works in a browser and you can actually write it live. ** ** Moreover, it makes me angry when I move more than I expected. Instead, the movement is light. Obviously, it's slow.

Grumpy image.png

https://github.com/google/grumpy Number of articles on Qiita: 9

It's not an exaggeration to say that it's a minor Python transpiler that Google makes. The code is converted from Python to Go, and you can build it! The substitute. Actually, it is quite a color thing that you can also use the Go library from Python. I've benchmarked speed with Go, Python, and Grumpy before, so check out that article as well.

Go, Python and Grumpy Speed Benchmarks-How Fast is Google's Transpiler? ~

Pythonista image.png

http://omz-software.com/pythonista/ Number of articles on Qiita: 113

Python execution environment that runs on iOS. As I recently learned, it seems that not only can Python be written with an iPhone application, but scripts can be output as a standalone application. There is a charge, but it's $ 9.99, so it's not expensive. A dish that you want to touch a little.

Scripting Layer for Android (SL4A) image.png

https://github.com/damonkohler/sl4a Number of articles on Qiita: 3

Python environment on Android. Development seems to have stopped now. A long time ago, I hated writing Java and wanted to write an app in Python. The one I looked up thinking. A long time ago, the coil of the iPhone charger was terrible, and it seems that the smartphone is panting. There is a video like this, and I want to panting my smartphone too! I thought, I made an app.

[My Android] I made an app that makes my smartphone panting when charged [Panting]

This app was built in Python with SL4A. SL4A is difficult to touch the native UI, only WebView is touched, but the value of the accelerometer etc. was relatively easy to get, so I did it with this.

kivy image.png

https://kivy.org/#home Number of articles on Qiita: 92

The coat color is a little different, but Kivy is introduced because it is a library using Python. A long time ago, I wanted to make something like a multi-touch keyboard under Windows 8.

Multitouch Music Board on Windows 8

At that time, there were few Python libraries that could take multi-touch, and Kivy was the only option. So, Kivy and MIDI library. And the video above was made with a software synth. The reason why we are taking up the environment here is that it is a very powerful environment that can output Linux, Windows, Mac, RasPi, Android, iOS with one code. (It is called an environment in the sense that it is built into the output application.)

Ren'Py

image.png

https://www.renpy.org/ Number of articles on Qiita: 2

This is a visual novel engine that can be written in Python. You can write almost the same code as Python, but it's a pretty interesting implementation with the addition of an extension syntax optimized for visual novels. It seems that this can be output to Linux, Windows, Mac, Android, iOS, Chrome OS with a similar feeling.

A long time ago

I want to be a steamed cheese bread!

I made a dung sound novel for Android, and used it there. It's really a sound novel. Because there is no picture (I couldn't draw).

Shed Skin image.png

https://shedskin.github.io/ Number of articles on Qiita: ** 0 **

It's a fairly dominor category. A transpiler that converts Python to C ++. I used to use it a long time ago, but I remember throwing it because I couldn't transpile it at all. It will not be maintained anymore. I thought, but it seems that it is still maintained. Suge

StacklessPSP

image.png

https://code.google.com/archive/p/pspstacklesspython/downloads Number of articles on Qiita: ** 0 **

A Python implementation that I personally love. A Python binary that runs on the PSP (Playstat on Portable). This was a very exciting implementation for a PSP remodeler at the time. However, I didn't actually use it that much. It's really annoying to use, isn't it? I just want to move it a little

  1. Connect PSP to PC via USB
  2. Put the sauce
  3. Disconnect the PSP from the PC
  4. Launch Stackless PSP

I was doing something like that, but since this takes time, I threw it out on the way.

pyNES image.png

https://gutomaia.net/pyNES/ Number of articles on Qiita: ** 0 **

Let's make a NES game with Python. It is an attempt. Is it okay to put this in the Python processing system ...? I thought, but I will introduce it because it is interesting. Python doesn't really run on the NES, but there are functions suitable for writing NES games. Is correct.

Summary

The platform of the development environment and the execution environment are different (can be changed)

Python implementations other than CPython

Other than C language

C language

Transpiler system (from Python to another language)

Other

At the end

There is no such thing! I don't have this! I think there are also things like. Anaconda! ?? Jupyter! ?? Like. Basically, the implementation of CPython is omitted, and the ones that have other characteristics are narrowed down. It also pulls out the built-in CPython environment. For example, Blender, Maya, Metasequoia. If you start putting it so far, it will be quite difficult.

I checked it earlier, but there are other people who are looking into such a minor Python environment.

Can you say that? Python Name ~

Read this article,

** "I want to do it!" "I'll call it in Python" ** ** "I want to do AVR!" "I'll call it in Python" ** ** "I want to do a web front end!" "I'll call it in Python" ** ** "I want to make a smartphone app!" "I'll call it with Python" **

You will be able to throw a fucking lip. I think this article covers everything from the weakest to the relatively strong Python execution environment minor world, so please tell me if there is any other emotional Python execution environment. I'm going to step on a land mine. Thank you!

Recommended Posts

Python Minor Environment Retsuden-How many Python environments do you know? ~
How much do you know the basics of Python?
Python | What you can do with Python
How many types of Python do you have in Windows 10? I had 5 types.
How many types of Python do you have on your macOS? I had 401 types.
You should know if you use Python! 10 useful libraries