Please open Telegram to view this post
VIEW IN TELEGRAM
Please open Telegram to view this post
VIEW IN TELEGRAM
PySnooper – инструмент для дебаггинга проектов на Python без использования print
Never use print for debugging again.
Вы просто добавляете декоратор к интересующей вас функции и вы получите целый журнал «воспроизведения» вашей функции, включая то, какие строки выполнялись и когда, и когда именно были изменены локальные переменные
• GitHub
https://yangx.top/pythonl?boost
Never use print for debugging again.
Вы просто добавляете декоратор к интересующей вас функции и вы получите целый журнал «воспроизведения» вашей функции, включая то, какие строки выполнялись и когда, и когда именно были изменены локальные переменные
• GitHub
https://yangx.top/pythonl?boost
GitHub
GitHub - cool-RR/PySnooper: Never use print for debugging again
Never use print for debugging again. Contribute to cool-RR/PySnooper development by creating an account on GitHub.
Please open Telegram to view this post
VIEW IN TELEGRAM
Please open Telegram to view this post
VIEW IN TELEGRAM
Please open Telegram to view this post
VIEW IN TELEGRAM
You can use python-barcode to generate different types of objects.
Как создать штрих-код с помощью Python?
Вы можете использовать python-barcode для генерации различных типов объектов.
Сначала установите модуль barcode с помощью pip:
pip install python-barcode
Мы создадим штрихкод
ISBN-13.
Этот модуль поддерживает множество других типов штрихкодов.Мы сгенерируем PNG-изображение штрихкода. Для просмотра изображения мы будем использовать модуль pillow. Установить pillow можно, выполнив команду:
pip install pillow
Мы передаем 12-значное число в виде строки.
• Githib
@pythonl
Please open Telegram to view this post
VIEW IN TELEGRAM
Please open Telegram to view this post
VIEW IN TELEGRAM
Please open Telegram to view this post
VIEW IN TELEGRAM
Please open Telegram to view this post
VIEW IN TELEGRAM
Script that helps you to detect SQL injection
"Error based
" by sending multiple requests with 14 payloads and checking for 152 regex patterns for different databases.Python-скрипт, позволяющий обнаружить SQL-инъекции путем отправки нескольких запросов и проверки regex-шаблонами для различных баз данных.
• Github
@pythonl
Please open Telegram to view this post
VIEW IN TELEGRAM
Please open Telegram to view this post
VIEW IN TELEGRAM
Простой скрипт по управлению файлами на пк с помощью Python 🦸♂
@pythonl
Please open Telegram to view this post
VIEW IN TELEGRAM
This media is not supported in your browser
VIEW IN TELEGRAM
If you want to effortlessly animate your matplotlib plot in Python, use gif.
Если вы хотите без особых усилий анимировать график
matplotlib
в Python, используйте библиотеку gif.Следующая анимация создана с помощью gif.
pip install gif
import gif
from random import randint
from matplotlib import pyplot as plt
x = [randint(0, 100) for _ in range(100)]
y = [randint(0, 100) for _ in range(100)]
# (Optional) Set the dots per inch resolution to 300
gif.options.matplotlib["dpi"] = 300
# Decorate a plot function with @gif.frame
@gif.frame
def plot(i):
xi = x[i*10:(i+1)*10]
yi = y[i*10:(i+1)*10]
plt.scatter(xi, yi)
plt.xlim((0, 100))
plt.ylim((0, 100))
# Construct "frames"
frames = [plot(i) for i in range(10)]
# Save "frames" to gif with a specified duration (milliseconds) between each frame
gif.save(frames, 'example.gif', duration=50)
• Github
@pythonl
Please open Telegram to view this post
VIEW IN TELEGRAM
Please open Telegram to view this post
VIEW IN TELEGRAM
Please open Telegram to view this post
VIEW IN TELEGRAM