Language Selection

English French German Italian Portuguese Spanish

Development

Programming: Rust and Python Miscellany

Filed under
Development
  • This Week in Rust 300
  • Python String Interpolation with the Percent (%) Operator

    There are a number of different ways to format strings in Python, one of which is done using the % operator, which is known as the string formatting (or interpolation) operator. In this article we'll show you how to use this operator to construct strings with a template string and variables containing your data.

  • Your Guide to the CPython Source Code

    Are there certain parts of Python that just seem magic? Like how are dictionaries so much faster than looping over a list to find an item. How does a generator remember the state of the variables each time it yields a value and why do you never have to allocate memory like other languages? It turns out, CPython, the most popular Python runtime is written in human-readable C and Python code. This tutorial will walk you through the CPython source code.

    You’ll cover all the concepts behind the internals of CPython, how they work and visual explanations as you go.

  • Python 3.8 support in PyCharm

    The release of Python 3.8 brought new features to the Python coding realm. The language is evolving according to its community’s needs by addressing cases where new syntax or logic become necessary. From new ways of assigning expressions to restriction of usage of function declarations, calls, and variable assignations, this latest release presents new options to code. Of course, PyCharm couldn’t get behind, so we now support some of the major features coming with this new version.

    This article will walk you through the features currently supported by our latest PyCharm release. To try them out, get the latest version of PyCharm and download the current beta release of Python 3.8 from here. From there you will just need to switch to Python 3.8 as your interpreter in PyCharm (if you’re not sure how to switch the interpreter, jump into our documentation for help).

  • Python Arrays in a Nutshell

    Python arrays are homogenous data structure. They are used to store multiple items but allow only the same type of data. They are available in Python by importing the array module.

    Lists, a built-in type in Python, are also capable of storing multiple values. But they are different from arrays because they are not bound to any specific type.

    So, to summarize, arrays are not fundamental type, but lists are internal to Python. An array accepts values of one kind while lists are independent of the data type.

Programming: OpenPOWER Foundation, iOS and Android Localization Tool, First Python Program, Eclipse Vert.x Spring Boot

Filed under
Development
  • Open Source Developer Gain New Collaboration Opportunities on Open Hardware

    Live from Open Source Summit this week, we’re thrilled to share that the OpenPOWER Foundation is becoming a project hosted at The Linux Foundation. This includes a technical contribution of the POWER Instruction Set Architecture (ISA) and Source Design Implementations, including a softcore implementation of the POWER ISA.

    The OpenPOWER Foundation recognizes how increased collaboration across the open source ecosystem will advance open hardware technology and accelerate opportunity.

    Six years ago, IBM setup the OpenPOWER Foundation to widen the reach of their POWER technology. The goal from the start was to support Instruction Set Architecture and contributed Source Design Implementations required for data-driven HPC workloads like modelling and simulation, cloud services and also Artificial Intelligence (AI).

  • iOS and Android Localization Tool

    Localization is simply the process of translating your app into multiple languages.

    In situation like you need support multiple language, including API response messages and dynamic strings you need a list of localizable .strings file, and you need to localized it based on the Language you want ( e.g English, Chinese, Japanese ).

    Xcode has a built-in localizable file generator that generate your localizable .strings for each language you supported.

  • First Python Program

    Ok, really thrilled today.
    Patting myself on the back.

    I finally managed to write a program all on my ownsome. Kushal gave me a toy problem and I went around, scratched my head, did a lot of searching, a lot more headbanging, even more mistakes and then finally managed to write this.

    Am happy because this is how I imagined myself learning in the first place.
    Figuring out a problem someone has and then figuring out how to help them.

  • Reactive Spring Boot programming with Vert.x

    The latest bundle of Red Hat supported Spring Boot starters was recently released. In addition to supporting the popular Red Hat products for our Spring Boot customers, the Red Hat Spring Boot team was also busy creating new ones. The most recent technical preview added is a group of Eclipse Vert.x Spring Boot starters, which provide a Spring-native vocabulary for the popular JVM reactive toolkit.

    Let’s quickly go through the main concepts to get everybody on the same page before looking into an example.

    A reactive system as defined in the Reactive Manifesto is responsive, resilient, elastic, and message-driven. These properties guarantee easy replication, non-blocking communication with high system resources utilization and great fault tolerance. At the latest stage of software evolution, with cloud-first, low-latency, and highly data-intensive applications, reactive systems provide a great value for money.

    In our newest release, we have introduced a few Spring WebFlux extensions for Vert.x. With these extensions, you can build your application the way you’re used to—using WebFlux and Project Reactor—while network communications will be handled by the Vert.x servers and clients.

Programming: Datasets for Credit Risk Modeling, Qt Designer, Refactoring to Multiple Exit Points, LLVM Clang Compiler

Filed under
Development
  • Datasets for Credit Risk Modeling

    This tutorial outlines several free publicly available datasets which can be used for credit risk modeling. In banking world, credit risk is a critical business vertical which makes sure that bank has sufficient capital to protect depositors from credit, market and operational risks. During the process, its role is to work for bank in compliance to central bank regulations.

  • Embedding PyQtGraph (or any other custom PyQt5 widgets) from Qt Designer

    Qt Designer is a great tool for designing PyQt5 GUIs, allowing you to use the entire range of Qt5 widgets and layouts to construct your apps. As your applications get more complex however you may find yourself creating custom widgets, or using PyQt5 libraries such as PyQtGraph, who's widgets are not available within Designer.

    Helpfully, Qt Designer supports a mechanism for using placeholder widgets to represent your custom or external widgets in your design. This tutorial will walk you through the process of using placeholders to include a PyQtGraph plot in your app from within Qt Designer.

  • Refactoring to Multiple Exit Points

    Functions should have only a single entry point. We all agree on that. But some people also argue that functions should have a single exit that returns the value. More people don't seem to care enough about how their functions are organized. I think that makes functions a lot more complicated than they have to be. So let's talk about function organization and how multiple exit points can help.

  • Sony Continues Tuning AMD Jaguar Support Within The LLVM Clang Compiler

    Thanks to Sony using LLVM Clang as their default compiler toolchain for their PlayStation game console, they continue making improvements to the AMD Btver2/Jaguar code for optimized performance. The Jaguar APU is what's in the current PlayStation 4 while we've already seen contributions from Sony to improve the Zen CPU support ahead of their next-generation console.

    Just this week was the newest contribution to the Jaguar/Btver2 target code within the LLVM compiler stack. This most recent addition is fixing the latency and throughput of CMPXCHG instructions. These improvements should yield better generated code around those instructions.

Programming: Joget Operator, Python, LibreOffice, GNOME and KDE

Filed under
Development
  • Automating Low Code App Deployment on Red Hat OpenShift with the Joget Operator

    This is a guest post by Julian Khoo, VP Product Development and Co-Founder at Joget Inc. Julian has almost 20 years of experience in the IT industry, specifically in enterprise software development. He has been involved in the development of various products and platforms in application development, workflow management, content management, collaboration and e-commerce.

  • Python Histogram Plotting: NumPy, Matplotlib, Pandas & Seaborn

    In this course, you’ll be equipped to make production-quality, presentation-ready Python histogram plots with a range of choices and features.

    If you have introductory to intermediate knowledge in Python and statistics, then you can use this article as a one-stop shop for building and plotting histograms in Python using libraries from its scientific stack, including NumPy, Matplotlib, Pandas, and Seaborn.

  • PyCon 2020 Conference Site is here!

    Our bold design includes the Roberto Clemente Bridge, also known as the Sixth Street Bridge, which spans the Allegheny River in downtown Pittsburgh. The Pittsburgh Steelmark, was originally created for United States Steel Corporation to promote the attributes of steel: yellow lightens your work; orange brightens your leisure; and blue widens your world. The PPG Building, is a complex in downtown Pittsburgh, consisting of six buildings within three city blocks and five and a half acres. Named for its anchor tenant, PPG Industries, who initiated the project for its headquarters, the buildings are all of matching glass design consisting of 19,750 pieces of glass. Also included in the design are a fun snake, terminal window, and hardware related items.

    [...]

    As with any sponsorship, the benefits go both ways. Organizations have many options for sponsorship packages, and they all benefit from exposure to an ever growing audience of Python programmers, from those just getting started to 20 year veterans and every walk of life in between. If you're hiring, the Job Fair puts your organization within reach of a few thousand dedicated people who came to PyCon looking to sharpen their skills.

  • PyCoder’s Weekly: Issue #382 (Aug. 20, 2019)
  • Python Qt5 - the QTimer class.
  • [LibreOffice GSoC] Week 12 Report

    It was The last week of GSoC program. Raal was working on testing all the project and the generated files and I help him by solving some bugs or add anything.

  • Sajeer Ahamed: Review | GSoC 2019

    I've been working on GStreamer based project of Gnome Foundation. GStreamer is a pipeline-based multimedia framework that links together a wide variety of media processing systems to complete complex workflows. The framework is based on plugins that will provide various codec and other functionality. The plugins can be linked and arranged in a pipeline. And most of the plugins are written in C. Now the developers are in an attempt to convert them to Rust which is more robust and easily maintainable. My task is to be a part of this conversion and to help fix issues related to this.

  • KDE's Onboarding Sprint: Making it easier to setup a development environment

    Suse were generous enough to offer two spacious and fully equipped offices at their headquarters to host the KDE sprints. We owe a special thanks and a big KDE hug to the OpenSuse team and in particular Douglas DeMaio and Fabian Vogt for being incredible hosts.

  • Third month progress

    I am here presenting you with my final month GSoC project report. I will be providing the links to my work at the end of the section.

    Final month of the work period was much more hectic and tiring than the first couple of months. I had been busy more than I had anticipated. Nonetheless, I had to write code which I enjoyed writing : ) . In the first half of this work period, I was focused on completing the left-over QDBus communication from the phase 2, which I did successfully. But as when I thought my task was all over, I was faced with some regression in the code, which I utilised my rest half a month to fix it.

    [...]

    As I had said above in the intro, I was faced with some real difficulty during the second half of the work period. As soon as I finished up QDBus thing, a regression was caused (Which I should have noticed before, my bad), helper was no longer started by the main application. I spent rest of the days brain-storming the issue but due to shortage of time, could not fix it. I plan to try fixing it in the next few days before GSoC ends(26th August), if I successfully do that, I will update the status here as well .

Raspberry Pi gets MIT's Scratch 3 programming language for Raspbian

Filed under
Development
Hardware

Ever since Scratch 3 was released this January, a team at the Raspberry Pi Foundation has been working with MIT to develop an offline, installable version for the Raspberry Pi.

That offline version is now available, offering students and beginners an easy environment to begin coding with the language's visual 'code blocks', as well as paint and sound-editing tools.

Scratch 3 requires installing the latest version of Raspbian known as 'Buster', the latest version of Debian Linux that was released alongside the Raspberry Pi 4 in June.

Due to the memory requirements of Scratch 3, the Raspberry Pi Foundation is recommending it is installed on a Raspberry Pi 4 with at least 2GB of RAM. The 2GB model costs $45.

Read more

Also: GCC 10 Lands Support For -march=tigerlake & -march=cooperlake

The infrastructure is code: A story of COBOL and Go

Filed under
Development

But what about today? With the decline of mainframes and the rise of newer and more innovative languages designed for the web and cloud, where does COBOL sit?

As last week's episode of Command Line Heroes mentioned, in the late 1990s, Perl (as well as JavaScript and C++) was outpacing COBOL. And, as Perl's creator, Larry Wall stated then: "COBOL is no big deal these days since demand for COBOL seems to be trailing off, for some strange reason."

Read more

Programming Leftovers

Filed under
Development
  • Excellent Free Books to Learn Groovy

    Apache Groovy is a powerful, optionally typed and dynamic language, with static-typing and static compilation capabilities, for the Java platform aimed at improving developer productivity thanks to a concise, familiar and easy to learn syntax.

    It integrates seamlessly with any Java program, and immediately delivers to your application powerful features, including scripting capabilities, Domain-Specific Language authoring, runtime and compile-time meta-programming and functional programming.

    It’s both a static and dynamic language with features similar to those of Python, Ruby, Perl, and Smalltalk. It can be used as both a programming language and a scripting language for the Java Platform.

  • Top 9 Django Concepts - Part 2 : 5 Mins

    I will be covering 3 Django concepts, for those who had missed the first part of the 3 part series, you can head down to the Top 9 Django Concepts - Part 1

    The first concept is essential Django commands that you will be using when developing in Django.

    The second is the concept of using either a front-end like Vue, React or Angular web framework or using Django existing template system to build UI.

  • Get Current Date & Time in Python

    In this article, you will learn the datetime module supplies classes for manipulating dates and times in both simple and complex ways.

  • RcppQuantuccia 0.0.3

    RcppQuantuccia brings the Quantuccia header-only subset / variant of QuantLib to R. At the current stage, it mostly offers date and calendaring functions.

    This release was triggered by some work CRAN is doing on updating C++ standards for code in the repository. Notably, under C++11 some constructs such ptr_fun, bind1st, bind2nd, … are now deprecated, and CRAN prefers the code base to not issue such warnings (as e.g. now seen under clang++-9). So we updated the corresponding code in a good dozen or so places to the (more current and compliant) code from QuantLib itself.

today's howtos and programming bits

Filed under
Development
HowTos
  • How to access Website using command-line from the Terminal
  • How to Transfer Files with Rsync over SSH
  • Fedora 30 : Install the last version of PHP.
  • Security, UX, and Sustainability For The Python Package Index

    PyPI is a core component of the Python ecosystem that most developer's have interacted with as either a producer or a consumer. But have you ever thought deeply about how it is implemented, who designs those interactions, and how it is secured? In this episode Nicole Harris and William Woodruff discuss their recent work to add new security capabilities and improve the overall accessibility and user experience. It is a worthwhile exercise to consider how much effort goes into making sure that we don't have to think much about this piece of infrastructure that we all rely on.

  • Moving Conda Environments

    Conda is known as a package manager for Python and R packages produced by Anaconda, Inc. and conda-forge, the open-source community for conda Python packages. In addition to managing packages, Conda is also an environment manager. If you’re new to Python, environments create an isolated environment to manage dependencies in a project. Because the Python ecosystem of packages is both wide and deep, part of Conda’s job is to install packages that don’t conflict with each other.

    Once you have your project environment set up and your code written and tested, you may want to move it to another machine. For example, you would want to move a web application to server with a public address or copy a set of tools you frequently use to a USB drive. You might want to take a snapshot of your project environment as a backup.

  • Moving Code with Refactoring in Wing Pro

    In this issue of Wing Tips we explain how to quickly move functions, methods, classes, and other symbols around in Python code, using Wing Pro's Move Symbol refactoring operation.

    This operation takes care of updating all the points of reference for the symbol that is being moved. For example, if a function is moved from one module to another then Wing will update all the points of call for that function to import the module it has been moved into and invoke the function from there.

Programming: WebAssembly, Mozilla GFX, Qt and Python

Filed under
Development
  • WebAssembly for speed and code reuse

    Imagine translating a non-web application, written in a high-level language, into a binary module ready for the web. This translation could be done without any change whatsoever to the non-web application's source code. A browser can download the newly translated module efficiently and execute the module in the sandbox. The executing web module can interact seamlessly with other web technologies—with JavaScript (JS) in particular. Welcome to WebAssembly.

    As befits a language with assembly in the name, WebAssembly is low-level. But this low-level character encourages optimization: the just-in-time (JIT) compiler of the browser's virtual machine can translate portable WebAssembly code into fast, platform-specific machine code. A WebAssembly module thereby becomes an executable suited for compute-bound tasks such as number crunching.

    Which high-level languages compile into WebAssembly? The list is growing, but the original candidates were C, C++, and Rust. Let's call these three the systems languages, as they are meant for systems programming and high-performance applications programming. The systems languages share two features that suit them for compilation into WebAssembly. The next section gets into the details, which sets up full code examples (in C and TypeScript) together with samples from WebAssembly's own text format language.

  • Mozilla GFX: moz://gfx newsletter #47

    Hi there! Time for another mozilla graphics newsletter. In the comments section of the previous newsletter, Michael asked about the relation between WebRender and WebGL, I’ll try give a short answer here.

    Both WebRender and WebGL need access to the GPU to do their work. At the moment both of them use the OpenGL API, either directly or through ANGLE which emulates OpenGL on top of D3D11. They, however, each work with their own OpenGL context. Frames produced with WebGL are sent to WebRender as texture handles. WebRender, at the API level, has a single entry point for images, video frames, canvases, in short for every grid of pixels in some flavor of RGB format, be them CPU-side buffers or already in GPU memory as is normally the case for WebGL. In order to share textures between separate OpenGL contexts we rely on platform-specific APIs such as EGLImage and DXGI.

    Beyond that there isn’t any fancy interaction between WebGL and WebRender. The latter sees the former as a image producer just like 2D canvases, video decoders and plain static images.

  • The Titler Revamp: QML Producer in the making

    At the beginning of this month, I started testing out the new producer as I had a good, rough structure for the producer code, and was only facing a few minor problems. Initially, I was unclear about how exactly the producer is going to be used by the titler so I took a small step back and spent some time figuring out how kdenlivetitle worked, which is the producer in use.

    Initially, I faced integration problems (which are the ones you’d normally expect) when I tried to make use of the QmlRenderer library for rendering and loading QML templates – and most of them were resolved by a simple refactoring of the QmlRenderer library source code. To give an example, the producer traditionally stores the QML template in global variables which is taken as a character pointer argument (which is, again, traditional C) The QmlRenderer lib takes a QUrl as its parameters for loading the Qml file, so to solve this problem all I had to do was to overload the loadQml() method with one which could accommodate the producer’s needs – which worked perfectly fine. As a consequence, I also had to compartmentalise (further) the rendering process so now we have 3 methods which go sequentially when we want to render something using the library ( initialiseRenderParams( ) -> prepareRenderer( ) -> renderQml( ) )

    [...]

    The problem was resolved (thank you JB) finally and it was not due to OpenGL but it was simply because I hadn’t created an QApplication for the producer (which is necessary for qt producers). The whole month’s been a steep curve, definitely not easy, but, I enjoyed it!

    Right now, I have a producer which is, now, almost complete and with a little more tweaking, will be put to use, hopefully. I’m still facing a few minor issues which I hope to resolve soon and get a working producer. Once we get that, I can start work on the Kdenlive side. Let’s hope for the best!

  • How to Make a Discord Bot in Python

    In a world where video games are so important to so many people, communication and community around games are vital. Discord offers both of those and more in one well-designed package. In this tutorial, you’ll learn how to make a Discord bot in Python so that you can make the most of this fantastic platform.

  • Qt Visual Studio Tools 2.4 RC Released

    The Visual Studio Project System is widely used as the build system of choice for C++ projects in VS. Under the hood, MSBuild provides the project file format and build framework. The Qt VS Tools make use of the extensibility of MSBuild to provide design-time and build-time integration of Qt in VS projects — toward the end of the post we have a closer look at how that integration works and what changed in the new release.

    Up to this point, the Qt VS Tools extension managed its own project settings in an isolated manner. This approach prevented the integration of Qt in Visual Studio to fully benefit from the features of VS projects and MSBuild. Significantly, it was not possible to have Qt settings vary according to the build configuration (e.g. having a different list of selected Qt modules for different configurations), including Qt itself: only one version/build of Qt could be selected and would apply to all configurations, a significant drawback in the case of multi-platform projects.

    Another important limitation that users of the Qt VS Tools have reported is the lack of support for importing Qt-related settings from shared property sheet files. This feature allows settings in VS projects to be shared within a team or organization, thus providing a single source for that information. Up to now, this was not possible to do with settings managed by the Qt VS Tools.

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

Filed under
Development
  • 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 Smile

  • 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.

Syndicate content

More in Tux Machines

Type Title Author Replies Last Postsort icon
Story Android Leftovers Rianne Schestowitz 22/08/2019 - 12:23am
Story Intel's New OpenGL Driver Is Looking Really Great With The Upcoming Mesa 19.2 Rianne Schestowitz 22/08/2019 - 12:07am
Story Richard Brown: Changing of the Guard Roy Schestowitz 5 21/08/2019 - 11:52pm
Story OSS: OpenSMTPD, Connexta, Square and Google Roy Schestowitz 21/08/2019 - 11:42pm
Story Open Source platforms to now help students Roy Schestowitz 21/08/2019 - 11:30pm
Story today's howtos Roy Schestowitz 21/08/2019 - 10:39pm
Story Security Leftovers Roy Schestowitz 21/08/2019 - 9:44pm
Story Netrunner 19.08 – Indigo released Rianne Schestowitz 3 21/08/2019 - 9:31pm
Story Linux-driven modules to showcase new MediaTek AIoT SoCs Roy Schestowitz 21/08/2019 - 9:03pm
Story Devices: Raspberry Pi and More Roy Schestowitz 21/08/2019 - 8:19pm