Python Weekly - Python Weekly - Issue 663

View this email in your browser

Python Weekly

Welcome to issue 663 of Python Weekly. Let's get straight to the links this week.
Articles, Tutorials and Talks

From Boring Object-Oriented to INSANE Functional Code 
This video demonstrates that there's a place for both object-oriented and functional code. In Python, these two approaches can be combined effectively, allowing you to leverage the strengths of each for the best results.

Approximating sum types in Python with Pydantic
The article demonstrates how to approximate sum types in Python using Pydantic's tagged unions feature, providing a way to represent complex data structures with type safety. It explains the concept of sum types, shows how to implement them using Pydantic models, and discusses the benefits and limitations of this approach in Python programming.

Are Function Calls Still Slow in Python? An Analysis of Recent Optimizations in CPython
How costly it is to call functions and builtins in your python code? Does inlining help? How have the recent CPython releases improved performance in these areas?

FlexAttention: The Flexibility of PyTorch with the Performance of FlashAttention 
FlexAttention is a new PyTorch API that allows implementing various attention variants using idiomatic PyTorch code, which is then lowered into optimized FlashAttention kernels through torch.compile. It provides a flexible score_mod function for modifying attention scores and a mask_mod function for leveraging sparsity, enabling researchers to easily experiment with different attention mechanisms while maintaining high performance.

Crawling Pages with Infinite Scroll using Scrapy and Playwright
This post provides a detailed guide on how to scrape infinite scroll websites using Scrapy and Playwright in Python. It covers the setup process, explains how to implement a custom downloader middleware to handle JavaScript rendering, and demonstrates how to extract data from dynamically loaded content, offering a practical solution for web scraping challenges posed by modern web applications.

CSVs Are Kinda Bad. DSVs Are Kinda Good.
The article argues that CSVs (Comma-Separated Values) are problematic due to various edge cases involving delimiters, quotes, and newlines, and proposes using Delimiter-Separated Values (DSV) with ASCII control characters as a more robust alternative. It demonstrates how DSVs can handle complex data without escaping or quoting issues, but acknowledges that the lack of widespread tool support for this format is a significant drawback.

Automating Boolean-Based SQL Injection with Python
How to be efficiently lazy at finding hidden gems in predictable places – Database Edition.

Cloudflare R2 x Django. Static Files. User uploads, css, images, js and more. Production-ready. 
The video covers setting up and managing Django files, including static and user-uploaded files, using Cloudflare's R2 object storage. It emphasizes best practices for configuring environment variables, securing API keys, and managing static and media files in Django with advanced validation and customization options.

Django: create sub-commands within a management command 

Optimizing PyTorch Docker images: how to cut size by 60%


Interesting Projects, Tools and Libraries

Deep-Live-Cam
Real time face swap and one-click video deepfake with only a single image.

pgai
Bring AI models closer to your PostgreSQL data.

emval
emval is a blazingly fast Python email validator written in Rust.

DeltaDB
DeltaDB is a lightweight, fast, and scalable database built on polars and deltalake. 

Unstract
No-code LLM Platform to launch APIs and ETL Pipelines to structure unstructured documents.

LinkedIn_AIHawk
LinkedIn_AIHawk is a tool that automates the jobs application process on LinkedIn. Utilizing artificial intelligence, it enables users to apply for multiple job offers in an automated and personalized way.

AgentK
An autoagentic AGI that is self-evolving and modular.

llm_aided_ocr
Enhance Tesseract OCR output for scanned PDFs by applying Large Language Model (LLM) corrections.

EDSL
Design, conduct and analyze results of AI-powered surveys and experiments. Simulate social science and market research with large numbers of AI agents and LLMs.


Upcoming Events and Webinars

Virtual: PyMunich Meetup August 2024
There will be following talks
  • Creating Domain Specific Languages with Python
  • Code Detective: Uncovering Complexity with Python’s Importlib and AST

PyLadies Oslo Meetup August 2024
There will be following talks
  • Containerizing and running a Python-based GenAI App
  • Hosting a Streamlit App on AWS
Our Other Newsletters
Programmer Weekly - A free weekly newsletter for programmers.

Founder Weekly - A free weekly newsletter for entrepreneurs featuring best curated content, must read articles, how to guides, tips and tricks, resources, events and more.
 
Copyright © 2024 Python Weekly, All rights reserved.
You are receiving our weekly newsletter because you signed up at http://www.PythonWeekly.com.

Our mailing address is:
Python Weekly
Brooklyn
Brooklyn, NY 11209

Add us to your address book


Want to change how you receive these emails?
You can update your preferences or unsubscribe from this list.

Older messages

Python Weekly - Issue 662

Thursday, August 8, 2024

View this email in your browser Python Weekly Welcome to issue 662 of Python Weekly. Let's get straight to the links this week. Articles, Tutorials and Talks FINALLY Python is Getting Rid of the

Python Weekly - Issue 661

Thursday, August 1, 2024

View this email in your browser Python Weekly Welcome to issue 661 of Python Weekly. Let's get straight to the links this week. From Our Sponsor Get Your Weekly Dose of Programming A weekly

Python Weekly - Issue 660

Thursday, July 25, 2024

View this email in your browser Python Weekly Welcome to issue 660 of Python Weekly. Let's get straight to the links this week. From Our Sponsor Get Your Weekly Dose of Programming A weekly

Python Weekly - Issue 659

Thursday, July 18, 2024

View this email in your browser Python Weekly Welcome to issue 659 of Python Weekly. Let's get straight to the links this week. News Binary secret scanning helped us prevent (what might have been)

Python Weekly - Issue 658

Thursday, July 11, 2024

View this email in your browser Python Weekly Welcome to issue 658 of Python Weekly. Let's get straight to the links this week. Articles, Tutorials and Talks PySkyWiFi: completely free,

You Might Also Like

Charted | Global Economic Confidence in 2025, by Country 🌎

Wednesday, December 25, 2024

While emerging markets in Asia have the strongest confidence in the global economy looking ahead, European countries are most pessimistic. View Online | Subscribe | Download Our App FEATURED STORY

Top Tech Deals 🎅 Sony Headphones, iPhone Cases, 4K Projector, and More!

Wednesday, December 25, 2024

The season of giving is upon us. How-To Geek Logo December 25, 2024 Top Tech Deals: Sony Headphones, iPhone Cases, 4K Projector, and More! The season of giving is upon us. Happy Holidays! If you're

Why the Race to AGI is Humanitys Defining Moment

Wednesday, December 25, 2024

Top Tech Content sent at Noon! Boost Your Article on HackerNoon for $159.99! Read this email in your browser How are you, @newsletterest1? 🪐 What's happening in tech today, December 25, 2024? The

Iran's Charming Kitten Deploys BellaCPP: A New C++ Variant of BellaCiao Malware

Wednesday, December 25, 2024

THN Daily Updates Newsletter cover The Data Science Handbook, 2nd Edition ($60.00 Value) FREE for a Limited Time Practical, accessible guide to becoming a data scientist, updated to include the latest

Software Testing Weekly - Issue 251

Wednesday, December 25, 2024

GitHub Copilot is free! 🤖 View on the Web Archives ISSUE 251 December 25th 2024 COMMENT Welcome to the 251st issue! In case you missed it — GitHub Copilot is free! The free version works with Visual

Daily Coding Problem: Problem #1647 [Medium]

Tuesday, December 24, 2024

Daily Coding Problem Good morning! Here's your coding interview problem for today. This problem was asked by Square. In front of you is a row of N coins, with values v 1 , v 1 , ..., v n . You are

Sentiment Analysis, Topological Sort, Web Security, and More

Tuesday, December 24, 2024

Exploring Modern Sentiment Analysis Approaches in Python #661 – DECEMBER 24, 2024 VIEW IN BROWSER The PyCoder's Weekly Logo Exploring Modern Sentiment Analysis Approaches in Python What are the

🤫 Do Not Disturb Mode Is My Secret to Sanity — 8 Gadgets I Want To See Nintendo Make

Tuesday, December 24, 2024

Also: The Best Christmas Movies to Watch on Netflix, and More! How-To Geek Logo December 24, 2024 Did You Know Their association with the Christmas season might make you think poinsettias hail from a

😱 AzureEdge.net DNS Retiring Jan. 2025, 🚀 Microsoft Phi-4 AI Outperforms, 🔒 Microsoft Secure Future Initiative

Tuesday, December 24, 2024

Blog | Advertise | View Online Your trusted source for Cloud, AI and DevOps guidance with industry expert Chris Pietschmann! Phi-4: Microsoft's New Small Language Model Outperforms Giants in AI

Mapped | The Top Health Insurance Companies by State 🏥

Tuesday, December 24, 2024

In 13 US states, a single company dominates the health insurance market, holding at least half of the total market share. View Online | Subscribe | Download Our App Presented by: Global X ETFs Power