Language Selection

English French German Italian Portuguese Spanish

Programming: Rust Turns 4, GCC, Go and Python

Filed under
Development
  • 4 years of Rust

    On May 15th, 2015, Rust was released to the world! After 5 years of open development (and a couple of years of sketching before that), we finally hit the button on making the attempt to create a new systems programming language a serious effort!

    It’s easy to look back on the pre-1.0 times and cherish them for being the wild times of language development and fun research. Features were added and cut, syntax and keywords were tried, and before 1.0, there was a big clean-up that removed a lot of the standard library. For fun, you can check Niko’s blog post on how Rust's object system works, Marijn Haverbeke’s talk on features that never made it close to 1.0 or even the introductory slides about Servo, which present a language looking very different from today.

    Releasing Rust with stability guarantees also meant putting a stop to large visible changes. The face of Rust is still very similar to Rust 1.0. Even with the changes from last year’s 2018 Edition, Rust is still very recognizable as what it was in 2015. That steadiness hides that the time of Rust’s fastest development and growth is now.

  • Three Ways of Storing and Accessing Lots of Images in Python

    Why would you want to know more about different ways of storing and accessing images in Python? If you’re segmenting a handful of images by color or detecting faces one by one using OpenCV, then you don’t need to worry about it. Even if you’re using the Python Imaging Library (PIL) to draw on a few hundred photos, you still don’t need to. Storing images on disk, as .png or .jpg files, is both suitable and appropriate.

    Increasingly, however, the number of images required for a given task is getting larger and larger. Algorithms like convolutional neural networks, also known as convnets or CNNs, can handle enormous datasets of images and even learn from them. If you’re interested, you can read more about how convnets can be used for ranking selfies or for sentiment analysis.

    ImageNet is a well-known public image database put together for training models on tasks like object classification, detection, and segmentation, and it consists of over 14 million images.

    Think about how long it would take to load all of them into memory for training, in batches, perhaps hundreds or thousands of times. Keep reading, and you’ll be convinced that it would take quite awhile—at least long enough to leave your computer and do many other things while you wish you worked at Google or NVIDIA.

  • A Linaro Developer Has Taken Up The Effort Of Converting GCC's SVN To Git

    The lengthy battle of converting the GNU Compiler Collection (GCC) to using a Git workflow from SVN might be getting closer to finally culminating... Linaro developer Maxim Kuvyrkov has jumped on the task of converting the GCC repository from SVN to Git and did so without much fuss.

    Eric S. Raymond has been working for what feels like ages on converting GCC SVN to Git using his "Reposurgeon" tool but given the massive size of the GCC code-base and long development history, it's been a slow process. There were roadblocks in his approach of converting the SVN history to Git that were blamed on high RAM prices and other obstacles. Most recently he was working on porting his tool to Golang but that it would take months to complete.

  • Friendlier tracebacks

    When beginners run programs that generate Python tracebacks, they are almost always confused by what the information shown and have no clue as to what this all means. More experienced programmers can sometimes extract enough information directly from tracebacks to figure out what what wrong, but they will often have to resort to inserting a few print calls and running their program again to truly figure out what went wrong and how to fix it. (A minority of programmers might eschew using print calls and use a debugger instead.)

    In order to make tracebacks more useful for them, some advanced programmers have designed tools to add more information so that simply looking at the enhanced traceback might be sufficient to diagnose properly the problem. These tools include better_exchook, infi.traceback, rich-traceback, stackprinter, as well as the beautiful better-exceptions, and many others including Python's own cgitb module. While there is no doubt that the additional information provided by these tools is useful for advanced programmers, it would likely only add to their confusion if it were used by beginners.

  • The Price of the Hallway Track

    There are many good reasons to not go to every talk possible when attending conferences. However increasingly it became hip to boast with not going to talks at all – encouraging others to follow suit. As a speaker, that rubs me the wrong way and I’ll try to explain why.

    This article started at PyCon US 2019, the biggest Python conference in the world with roughly 3,500 attendees. Over lunch on day one, I’ve noticed tweets encouraging people to not go to talks and instead do the infamous hallway track (= socializing in the hallways) or go to open spaces, and watch the videos later on YouTube. Sometimes even claiming that it doesn’t make any sense to go to talks in the first place.

  • Data Science Dojo Blog: Network Theory and Game of Thrones - A Perfect Combination

    Game of Thrones is arguably one of the biggest pop culture phenomena to hit the public consciousness in the last decade. Since the hype for the final season's arrival has gone down a bit, especially mine after episode three , I thought I could use this time to finally explore a side of Data Science that has always intrigued me - Network Theory, and combine it with a topic I am very invested in - Game of Thrones. Just to be clear I won't be making any claims or predictions about the plot of the show - No Spoilers. I just want to use Game of Thrones as a hopefully relatable context for discussing the analysis techniques.

    At a high level, Network Theory is the study of relationships between objects, more specifically it is a subfield of Graph Theory with extra attributes attached to the nodes and edges. If you're confused by these terms, don't worry I'll explain everything in a bit. For the rest, you might be familiar with graph theory and have not-so-fond memories associated with it, but bear with me for a while. I first learned basic graph theory in my university's algorithms course and, I'll be honest, I found absolutely nothing of interest in the entire topic. Sure, I could find the shortest path between two cities or find the best way to lay down routers in a computer network, but these topics never seemed fun to me. That is until I started exploring data science and learned about network analysis. That really opened my eyes to what the graph theory concepts were capable of. I encourage you to check out this video about exploring opposing factions and their effects on each other using graphs.

  • Go Baby Go

    I’m starting a new job next month and their language of choice is Go. Which means I have a good reason to finally get around to learning it (far too many years after I saw Marga talk about it at DebConf). For that I find I need a project - it’s hard to find the time to just do programming exercises, whereas if I’m working towards something it’s a bit easier. Naturally I decided to do something home automation related. In particular I bought a couple of Xiaomi Mijia Temperature/Humidity sensors a while back which also report via Bluetooth. I had a set of shell scripts polling them every so often to get the details, but it turns out they broadcast the current status every 2 seconds. Passively listening for that is a better method as it reduces power consumption on the device - no need for a 2 way handshake like with a manual poll. So, the project: passively listen for BLE advertisements, make sure they’re from the Xiaomi device and publish them via MQTT every minute.

    One thing that puts me off new languages is when they have a fast moving implementation - telling me I just need to fetch the latest nightly to get all the features I’m looking for is a sure fire way to make me hold off trying something. Go is well beyond that stage, so I grabbed the 1.11 package from Debian buster. That’s only one release behind current, so I felt reasonably confident I was using a good enough variant. For MQTT the obvious choice was the Eclipse Paho MQTT client. Bluetooth was a bit trickier - there were more options than I expected (including one by Paypal), but I settled on go-ble (sadly now in archived mode), primarily because it was the first one where I could easily figure out how to passively scan without needing to hack up any of the library code.

    With all those pieces it was fairly easy to throw together something that does the required steps in about 200 lines of code. That seems comparable to what I think it would have taken in Python, and to a large extent the process felt a lot closer to writing something in Python than in C.

  • Paul Ganssle: Time Zones In The Standard Library
  • Russell Keith-Magee: Python On Other Platforms
  • The 2019 Python Language Summit
  • What's an Engineering Workstation, in Your Opinion?

More in Tux Machines

Programming: Sanjog Sigdel's Work on LibreOffice and Python Picks

  • The Document Foundation/LibreOffice Community Member Monday: Sanjog Sigdel

    I’m currently a Graduate Student pursuing my MTech. in IT degree here in Kathmandu University, Dhulikhel, Nepal. Besides that, I am also a part-time instructor in a private college near the University: NIST College Banepa. I love knowing how new technologies work and also love exploring new places. Unitil now I have traveled almost 30 districts of Nepal via trekking, project monitoring and tours. I’ve been using Linux-based operating systems (mainly Ubuntu) since 2012. And I am also a FOSS activist/volunteer. I teach my students to use open source software and most of them are using Linux, LibreOffice, and Python programming in the Nano text editor :-)

  • Debugging Python Applications with the PDB Module

    In this tutorial, we are going to learn how to use Python's PDB module for debugging Python applications. Debugging refers to the process of removing software and hardware errors from a software application. PDB stands for "Python Debugger", and is a built-in interactive source code debugger with a wide range of features, like pausing a program, viewing variable values at specific instances, changing those values, etc. In this article, we will be covering the most commonly used functionalities of the PDB module.

  • Mike Driscoll: PyDev of the Week: Paul Ganssle

    This week we welcome Paul Ganssle (@pganssle) as our PyDev of the Week. Paul is the maintainer of the dateutil package and also a maintainer of the setuptools project. You can catch up with Paul on his website or check out some of his talks. Let’s take a few moments to get to know Paul better!

  • Image Process Plugin 1.2.0 for Pelican Released

    Image Process is a plugin for Pelican, a static site generator written in Python. Image Process let you automate the processing of images based on their class attribute. Use this plugin to minimize the overall page weight and to save you a trip to Gimp or Photoshop each time you include an image in your post. Image Process is used by this blog’s theme to resize the source images so they are the correct size for thumbnails on the main index page and the larger size they are displayed at on top of the articles.

  • Top 7 Compelling Reasons to Hire Ukrainian Developers

    Many people consider offshore development. They seek quality for a lower cost and look where to hire developers. Customers search online, read reviews, or ask for referrals to find the software development team that best fits their goals. Ukraine has become one of the top locations where customers across Europe, Asia, and North America go for developers to build their products from scratch.

  • How to Find and Hire a Python/Django Development Company

    Even though there are about 22 million developers in the world (according to a Nexten.io study), good Python/Django developers aren’t easy to find and can be quite expensive. But there are many job marketplaces for software development companies and individual Python developers. Where you can find profiles of software development companies and their projects, reviews and ratings from current and former clients.

Android Leftovers

Technical vision for Qt for Python

Exposing a huge framework such as Qt to another language is not an easy task and this was the main reason for the slow porting from the old PySide version in Qt 4 to Qt 5. Many developers hours were spent in adapting to new Qt 5 APIs, and more importantly, the binding generator tool such that everything can be handled properly. Now with Qt 6 things will be different, because the development of Qt for Python is progressing side-by-side to the C++ and QML stories in Qt 6. Hopefully, there will be a lot fewer surprises this time around. In fact, this effect can be seen with current 5.x releases, PySide2 is available almost at the same time as the Qt release, having in some cases a few days delays. Since the official release in Qt 5.12.0, the downloads of Qt for Python has been increasing day-by-day, which translates on the community adopting and enjoying the project. Read more Also: Qt 6 Will Bring Improvements To The Toolkit's Python Support

Red Hat: New PHP Builds, End-to-End Encryption for Kubernetes Applications, Interns

  • PHP version 7.2.22RC1 and 7.3.9RC1

    Release Candidate versions are available in testing repository for Fedora and Enterprise Linux (RHEL / CentOS) to allow more people to test them. They are available as Software Collections, for a parallel installation, perfect solution for such tests (for x86_64 only), and also as base packages. RPM of PHP version 7.3.9RC1 are available as SCL in remi-test repository and as base packages in the remi-test repository for Fedora 30 or remi-php73-test repository for Fedora 28-29 and Enterprise Linux. RPM of PHP version 7.2.22RC1 are available as SCL in remi-test repository and as base packages in the remi-test repository for Fedora 28-29 or remi-php72-test repository for Enterprise Linux.

  • Self-Serviced, End-to-End Encryption for Kubernetes Applications, Part 2: a Practical Example

    In part one of this series, we saw three approaches to fully automate the provisioning of certificates and create end-to-end encryption. Based on feedback from the community suggesting the post was a bit too theoretical and not immediately actionable, this article will illustrate a practical example. You can see a recording of the demo here.

  • The Tiger that interned at Red Hat

    From the start, Tiger just had the right idea about looking for a college. Instead of reading US World News’ rankings, basing his decisions on sports teams, or even aiming for the Ivy Leagues, Tiger set out to make his college search a data driven effort. He asked himself, first, where he wanted to work. For him, that was an almost typical answer for an aspiring young technology student: Google, Facebook, Red Hat and other big name tech firms. [...] Tiger's real name is Passawit Kaovilai, and he's now entering his third year at NC State. He said that many people in his native Thailand have nicknames, and that his translates well into any language, and is understood immediately. He was also born in the year of the tiger, so the name is a natural fit. Here at Red Hat, Tiger has taken on the duties of a technical marketing intern. That means he's been diving into Red Hat OpenShift 4 to help create documentation and learning tools for users in the field. That also means contributing to open source projects, and getting his handle out there on GitHub, however modestly.