Date: Mon, 26 Oct 2020 18:00:00 -0400
<div class="wp-block-jetpack-markdown"><h3>Summary</h3> <p>Python and Java are two of the most popular programming languages in the world, and have both been around for over 20 years. In that time there have been numerous attempts to provide interoperability between them, with varying methods and levels of success. One such project is JPype, which allows you to use Java classes in your Python code. In this episode the current lead developer, Karl Nelson, explains why he chose it as his preferred tool for combining these ecosystems, how he and his team are using it, and when and how you might want to use it for your own projects. He also discusses the work he has done to enable use of JPype on Android, and what is in store for the future of the project. If you have ever wanted to use a library or module from Java, but the rest of your project is already in Python, then this episode is definitely worth a listen.</p> <h3>Announcements</h3> <ul> <li>Hello and welcome to Podcast.__init__, the podcast about Python and the people who make it great.</li> <li>When you’re ready to launch your next app or want to try a project you hear about on the show, you’ll need somewhere to deploy it, so take a look at our friends over at Linode. With the launch of their managed Kubernetes platform it’s easy to get started with the next generation of deployment and scaling, powered by the battle tested Linode platform, including simple pricing, node balancers, 40Gbit networking, dedicated CPU and GPU instances, and worldwide data centers. Go to <a href="https://www.pythonpodcast.com/linode?utm_source=rss&utm_medium=rss">pythonpodcast.com/linode</a> and get a $60 credit to try out a Kubernetes cluster of your own. And don’t forget to thank them for their continued support of this show!</li> <li>You listen to this show to learn and stay up to date with the ways that Python is being used, including the latest in machine learning and data analysis. For more opportunities to stay up to date, gain new skills, and learn from your peers there are a growing number of virtual events that you can attend from the comfort and safety of your home. Go to <a href="https://www.pythonpodcast.com/conferences?utm_source=rss&utm_medium=rss">pythonpodcast.com/conferences</a> to check out the upcoming events being offered by our partners and get registered today!</li> <li>Your host as usual is Tobias Macey and today I’m interviewing Karl Nelson about JPype, a language bridge that lets you use Java classes in your Python programs</li> </ul> <h3>Interview</h3> <ul> <li>Introductions</li> <li>How did you get introduced to Python?</li> <li>Can you start by giving an overview of what JPype is? <ul> <li>What was your motivation for becoming such a regular contributor to the project?</li> </ul> </li> <li>Why might someone want to be able to call into the Java ecosystem from a Python program?</li> <li>There have been a number of other projects aiming to combine the capabilities of Java and Python, such as Jython and PyJNIus. What are the relative tradeoffs between the different options? <ul> <li>Many of those other projects have stalled or stopped altogether. What about JPype has allowed it to survive for so long?</li> </ul> </li> <li>Can you explain how JPype is implemented? <ul> <li>How has the design and implementation of the project evolved since it was first implemented?</li> <li>How do the relative language versions influence the compatibility of programs on either side of the bridge?</li> </ul> </li> <li>What is involved in creating a project that uses JPype? <ul> <li>How are dependencies, packaging, distribution, etc. handled across the Java and Python portions of the code?</li> </ul> </li> <li>What are some of the ways that JPype can be used for Android applications?</li> <li>What are some of the sharp edges or pitfalls that users of JPype should be aware of?</li> <li>What are some of the most interesting, innovative, or unexpected ways that you have seen JPype used?</li> <li>What have you found to be the most interesting or challenging aspects of building JPype?</li> <li>When is JPype the wrong choice?</li> <li>What is in store for the future of the project?</li> </ul> <h3>Keep In Touch</h3> <ul> <li><a href="https://github.com/Thrameos?utm_source=rss&utm_medium=rss" rel="noopener" target="_blank">Thrameos</a> on GitHub</li> <li><a href="https://www.linkedin.com/in/karl-nelson-6119b68/?utm_source=rss&utm_medium=rss" rel="noopener" target="_blank">LinkedIn</a></li> </ul> <h3>Picks</h3> <ul> <li>Tobias <ul> <li><a href="https://en.wikipedia.org/wiki/Hiking?utm_source=rss&utm_medium=rss" rel="noopener" target="_blank">Hiking</a></li> <li><a href="https://www.alltrails.com/?utm_source=rss&utm_medium=rss" rel="noopener" target="_blank">All Trails</a></li> <li><a href="https://www.hikingproject.com/?utm_source=rss&utm_medium=rss" rel="noopener" target="_blank">The Hiking Project</a></li> </ul> </li> <li>Karl <ul> <li><a href="https://leagueoflegends.fandom.com/wiki/Summoner%27s_Rift?utm_source=rss&utm_medium=rss" rel="noopener" target="_blank">Summoner’s Rift</a></li> </ul> </li> </ul> <h3>Links</h3> <ul> <li><a href="https://jpype.readthedocs.io/en/latest/?utm_source=rss&utm_medium=rss" rel="noopener" target="_blank">JPype</a></li> <li><a href="https://en.wikipedia.org/wiki/Java_(programming_language)?utm_source=rss&utm_medium=rss" rel="noopener" target="_blank">Java</a></li> <li><a href="https://talvi.net/a-brief-overview-of-python-java-bridges-in-2020.html?utm_source=rss&utm_medium=rss" rel="noopener" target="_blank">Overview of Python to Java bridges</a></li> <li><a href="https://www.llnl.gov/?utm_source=rss&utm_medium=rss" rel="noopener" target="_blank">Lawrence Livermore National Lab</a></li> <li><a href="https://en.wikipedia.org/wiki/Gtkmm?utm_source=rss&utm_medium=rss" rel="noopener" target="_blank">GTK–</a></li> <li><a href="https://www.gnome.org/?utm_source=rss&utm_medium=rss" rel="noopener" target="_blank">Gnome</a></li> <li><a href="https://www.perl.org/?utm_source=rss&utm_medium=rss" rel="noopener" target="_blank">Perl</a></li> <li><a href="https://en.wikipedia.org/wiki/C%2B%2B?utm_source=rss&utm_medium=rss" rel="noopener" target="_blank">C++</a></li> <li><a href="https://www.mathworks.com/products/matlab.html?utm_source=rss&utm_medium=rss" rel="noopener" target="_blank">Matlab</a></li> <li><a href="https://en.wikipedia.org/wiki/Java_Native_Interface?utm_source=rss&utm_medium=rss" rel="noopener" target="_blank">Java Native Interface (JNI)</a></li> <li><a href="https://www.scipy.org/?utm_source=rss&utm_medium=rss" rel="noopener" target="_blank">SciPy</a></li> <li><a href="https://numpy.org/?utm_source=rss&utm_medium=rss" rel="noopener" target="_blank">NumPy</a></li> <li><a href="https://matplotlib.org/?utm_source=rss&utm_medium=rss" rel="noopener" target="_blank">Matplotlib</a></li> <li><a href="https://www.jython.org/?utm_source=rss&utm_medium=rss" rel="noopener" target="_blank">Jython</a></li> <li><a href="https://pyjnius.readthedocs.io/en/stable/?utm_source=rss&utm_medium=rss" rel="noopener" target="_blank">PyJNIus</a></li> <li><a href="https://www.py4j.org/?utm_source=rss&utm_medium=rss" rel="noopener" target="_blank">Py4J</a></li> <li><a href="https://github.com/ninia/jep?utm_source=rss&utm_medium=rss" rel="noopener" target="_blank">Jep</a></li> <li><a href="https://www.ruby-lang.org/en/?utm_source=rss&utm_medium=rss" rel="noopener" target="_blank">Ruby</a></li> <li><a href="https://www.oracle.com/technical-resources/articles/java/javareflection.html?utm_source=rss&utm_medium=rss" rel="noopener" target="_blank">Reflection</a></li> <li><a href="https://ant.apache.org/ivy/?utm_source=rss&utm_medium=rss" rel="noopener" target="_blank">Ivy</a></li> <li><a href="https://maven.apache.org/?utm_source=rss&utm_medium=rss" rel="noopener" target="_blank">Maven</a></li> <li><a href="https://en.wikipedia.org/wiki/Java_Database_Connectivity?utm_source=rss&utm_medium=rss" rel="noopener" target="_blank">JDBC</a></li> <li><a href="https://kivy.org/#home?utm_source=rss&utm_medium=rss" rel="noopener" target="_blank">Kivy</a></li> <li><a href="https://www.android.com/?utm_source=rss&utm_medium=rss" rel="noopener" target="_blank">Android</a></li> <li><a href="https://docs.python.org/3/reference/datamodel.html#slots?utm_source=rss&utm_medium=rss" rel="noopener" target="_blank">Python Slots</a></li> <li><a href="https://www.pypy.org/?utm_source=rss&utm_medium=rss" rel="noopener" target="_blank">PyPy</a></li> <li><a href="https://asm.ow2.io/?utm_source=rss&utm_medium=rss" rel="noopener" target="_blank">Java ASM</a></li> <li><a href="http://arrow.apache.org/?utm_source=rss&utm_medium=rss" rel="noopener" target="_blank">Arrow Columnar Memory Format</a></li> <li><a href="https://developers.google.com/protocol-buffers?utm_source=rss&utm_medium=rss" rel="noopener" target="_blank">Protocol Buffers</a></li> <li><a href="https://www.graalvm.org/?utm_source=rss&utm_medium=rss" rel="noopener" target="_blank">GraalVM</a></li> </ul> <p>The intro and outro music is from Requiem for a Fish <a href="http://freemusicarchive.org/music/The_Freak_Fandango_Orchestra/?utm_source=rss&utm_medium=rss" rel="noopener" target="_blank">The Freak Fandango Orchestra</a> / <a href="http://creativecommons.org/licenses/by-sa/3.0/?utm_source=rss&utm_medium=rss" rel="noopener" target="_blank">CC BY-SA</a></p> </div> <img alt="" height="0" src="https://analytics.boundlessnotions.com/piwik.php?idsite=1&rec=1&url=https%3A%2F%2Fwww.pythonpodcast.com%2Fjpype-java-python-bridge-episode-286%2F&action_name=Power+Up+Your+Java+Using+Python+With+JPype+-+Episode+286&urlref=https%3A%2F%2Fwww.pythonpodcast.com%2Ffeed%2F&utm_source=rss&utm_medium=rss" style="border: 0; width: 0; height: 0;" width="0" />