Articles, news, and tips on Django and Python, page 2

Getting Started with Django Channels

In this tutorial, we will use Django Channels to create a real-time application that updates a list of users as they log in and out.

Python Chat Tutorial with Django and React

This tutorial will explain how to build a chat application with Python, Django and React.

Styling Django Forms with django-crispy-forms

По умолчанию в Django не предусмотрено никаких методов стилизации форм, из-за чего приходится тратить много сил и драгоценного времени, чтобы красиво оформить форму. django-crispy-forms решает эту проблему.

Celery Integration With Django

In this article, we will explore the benefits and limitations of using Celery to build robust and efficient applications. We will examine the use cases for Celery, including its ability to improve the performance of web applications through asynchronous task execution.

Guide: Type Hinting in Python

Since version 3.5, Python supports type hints: code annotations that, through additional tooling, can check if you’re using your code correctly.

Image Segmentation with Python

In this article we look at an interesting data problem – making decisions about the algorithms used for image segmentation, or separating one qualitatively different part of an image from another.

Introduction to Artificial Neural Networks in Python

The Artificial Neural Network (ANN) is an attempt at modeling the information processing capabilities of the biological nervous system. The human body is made up of trillions of cells, and the nervous system cells – called neurons – are specialized to carry “messages” through an electrochemical process.

Pandas Pivot: A Guide with Examples

Python’s Pandas library is one of the most popular tools in the data scientist’s toolbelt. Data scientists use Pandas to explore, clean, and understand datasets.

The Quickest Ways to Sort Pandas DataFrame Values

Pandas is a popular open source library used for data analysis. It’s written in Python, and it has a most ambitious mission. Per its own description in GitHub, Pandas “aims to be the fundamental high-level building block for doing practical, real world data analysis in Python. Additionally, it has the broader goal of becoming the most powerful and flexible open source data analysis/manipulation tool available in any language.”

Preparing Your Django Application for Production

Getting started with Django is quick and easy. By default Django comes configured for a local development environment, and while you can create elaborate web applications that work on your local machine, at some point you’ll want to get your web application production-ready.

Django REST Framework: Get Started Fast

If you’re not interested in the nuts and bolts of the Django REST Framework (DRF), just jump to the tutorial bit to know how to get your API off the ground in five minutes or less. Afterwards, come back and check out the details of how each part of the DRF tutorial is put together and what additional features and functionality you can get from DRF.

Pandas Merge, Join, and Concat: How To and Examples

Python’s Pandas library is a popular library for cleaning, manipulating, and interpreting large amounts of data. In an earlier post, we looked at the foundational structure in Pandas—the DataFrame. If you’re unfamiliar with Pandas DataFrames, take a look at that post to understand the basics.

Tutorial: Building a RESTful API with Flask

In this tutorial, we’ll be learning and creating RESTful APIs with Flask. To follow along with this tutorial, you should already have a good grasp of Python, Flask, and SQLAlchemy.

Django Forms: Working with Forms in Python

Dealing with HTML forms in a web application can be a complicated task: ideally, you’d have a standard way of rendering input fields and processing the inputted data. Django forms provide you with a framework that does just that. Django comes with some standard ways of rendering forms with inputs of various types.

Using Django Static Files and Templates: Django Tutorial Part 2

Django is made up of a few core components that we touched on in the last Django tutorial: Django Models make up the structure and behavior of data in a Django project, Django Views process incoming requests and provide responses, and Django Templates are populated with data and then rendered to the browser from the view response.

Using the Python Write to File Function

How can developers and clients benefit from data being in a file format when there are so many other options out there? Why not just use a simple HTML page with AJAX requests and tables to display the data? In this blog post, let me show you why using Python to construct files is productive way of of creating and filling them with data.

Web Scraping with Scrapy: Advanced Examples

Web scraping is one of the tools at a developer’s disposal when looking to gather data from the internet. While consuming data via an API has become commonplace, most of the websites online don’t have an API for delivering data to consumers.

Easily Install Django 4.2: A Quick Guide

The goal of this article is to get you started using Django to build a web application as quickly as possible, and set you on the road to a production-ready application. For demonstration purposes, we’ll be creating a simple blog for our company called Foo.

Flask SQLAlchemy Tutorial

In this article, we’re going to learn the basics of SQLAlchemy by creating a data-driven web application using Flask, a Python framework. We’ll build a minimal Flask app that keeps track of your book collection.

What is Web Scraping?

Some websites and platforms offer application programming interfaces (APIs) which we can use to access information in a structured way, but others might not. While APIs are certainly becoming the standard way of interacting with today’s popular platforms, we don’t always have this luxury when interacting with most of the websites on the internet.