Skip to content

Packages

Quickly generate word cloud Python module: wordcloud


Introduction

word-cloud is a very famous word in natural language processing domain. At first I thought it was just to calculate the frequency of the vocabulary and display the high-frequency words large.

But not only that, the shapes and the styles of characters are all learned not as simple as I thought.

I am a person who likes new things, so I came to study the wordcloud module in Python today and record my experience here.

Read More »Quickly generate word cloud Python module: wordcloud

Use Python PIL module to merge two images


Introduction

Recently, because I have been studying the interface of the program, I got many strange problems.

I want to record today is how to merge two pictures. I found that if I simply use the composite() function in PIL, the second picture will be overwritten by the first picture. So, I started to try convert the background of the second picture to transparent.

After converting the image to a transparent background, the result of the merging is quite natural to me.

I will start to introduce how to merge two pictures in below.

Read More »Use Python PIL module to merge two images

How to use Pickle module to store data in Python

Python is the most popular programming language!

Introduction

Hello! Today I want to record the “pickle” module in Python. The “pickle” module is very famous module in Python, its usage is like another Python package “Json”, it can compress the data and store it. If we want to load the data we store, we can easily call the “load()” function to restore our session.

Read More »How to use Pickle module to store data in Python

Using Python package “ujson” to increase Json processing speed

Python is the most popular programming language!

Introduction

Whatever programming language we used, we always selected Json format to store our data.

Json (JavaScript Object Notation) is a lightweight data-interchange format, and it is readable and suitable for storing data. But in Python, sometimes we have performance bottlenecks in reading Json files, especially when the files are too large.

Read More »Using Python package “ujson” to increase Json processing speed

[Python] Displaying Progress Bars Using the tqdm Package and Attempting to Implement Your Own Progress Bar

When we write Python code, sometimes we want to visualize the ‘progress bar’ to help us understand where our program is currently executing. For this need, instead of writing the progress bar ourselves, we can consider using a well-known progress bar module in Python—tqdm.

Read More »[Python] Displaying Progress Bars Using the tqdm Package and Attempting to Implement Your Own Progress Bar

Using “json” module to write and load Json file in Python

Display Python code on the screen

Introduction

Json format file is very easily to process, and many programming language support it. So this data format is quite suitable for joint access to a data and development between different programming languages.

Today I want to introduce how to use the Python package “json” to write and load a Json format file.

Read More »Using “json” module to write and load Json file in Python

[Python] Using package pytube to download YouTube videos


Introduction

Various electronic entertainments of modern people are inseparable from YouTube, whether it is to follow dramas, query tutorial, watch funny videos … we will watch it on YouTube platform. Saying watching YouTube is the most important thing for modern people.

Sometimes, we will need to download videos from YouTube. Of course, this matter itself is likely to violate intellectual property rights, so our use is limited to teaching and non-commercial use. The downloaded video must be deleted within a certain period of time.

Read More »[Python] Using package pytube to download YouTube videos

Use Python pacakge Pillow to convert font files to PNG images

Python is the most popular programming language!

Introduction

Today, I need to plot font files in PNG format and save it, which sounds like a rare requirement. After browsing on the Internet, I found that it can use ImageFont module of Python package Pillow to solved.

At the beginning, I wanted to use the Python package fontTools to solve the problem, but later I found that the Imagefont module in Pillow was better.

Read More »Use Python pacakge Pillow to convert font files to PNG images
Exit mobile version