ChatGPT 中断 原文: PyCoder’s Weekly - Issue #570 pycoder

  • 230329 Zoom.Quiet(大妈) 用时 37 分钟 完成格式转抄.
  • 230329 Zoom.Quiet(大妈) 用时 13 分钟 完成快译


探讨/吐糟

Discussions None


文章/教程/嗯哼

Articles, Tutorials and Talks

  • 在 Django 禁止 1+N
    • ALEXANDER SCHEPANOVSKI The 1+N database anti-pattern is common: fetch some rows from the database then re-fetch specific rows to get all the items. An ORM can hide this away and make you not realize it is happening. This article talks about how to stop it in Django. With added meta-bonus: he links to how he attempted to write the article with ChatGPT. (是也乎: ORM 毕竟不是编译器, 最大的问题就是隐藏了问题… )
  • Deep Neural Nets: 33 年前和 33 年后
    • ANDREJ KARPATHY This article examines the original paper that proposed back propagation neural nets and relates what has changed and what is the same. Using that knowledge, it looks forward to what neural nets may be able to do decades from now. Includes accompanying code samples. (是也乎: 和芯片制造一样, 没有几十年的持续投入, 随便炼点儿土钢, 不顶用的… )
  • Python 和 No-async async
    • WILL MCGUGAN “A (reasonable) criticism of async is that it tends to proliferate in your code. In order to await something, your functions must be async all the way up the call-stack. Textual is an async framework, but doesn’t require the app developer to use the async.” Learn how Textual accomplishes async-agnosticism.
  • reduce(): 单一 Python 函数的强大功能
    • MARTIN HEINZ “While Python is not a pure functional programming language, you still can do a lot of functional programming in it. In fact, just one function - reduce() - can do most of it.” This article introduces you to reduce(). (是也乎:
from functools import reduce
import operator
# Signature:
reduce(function, iterable[, initializer])
# Factorial
reduce(lambda x, y: y*x, range(1, 6), 1)
reduce(operator.mul, range(1, 6))
(((((1 * 1) * 2) * 3) * 4) * 5)
# 120

没错瞬间变成 LISP 的法宝 )

  • 什么时候应该在 Python 中使用 .repr() 与 .str()?
    • REAL PYTHON In this tutorial, you’ll learn the difference between the string representations returned by .repr() vs .str() and understand how to use them effectively in classes that you define. (是也乎: <strong>repr</strong> 都是渊源的函数 )
  • 将 TOML 用于 .env 文件?
    • BRETT CANNON Using .env files to specify configuration environments can be handy, but problematic when it comes to multiple platforms. Some toolsets are starting to explore the use of TOML instead. (是也乎: 这才是趋势哪… .toml.env 就好 )
  • 开发者营销
    • ADAM HILL A few simple steps can make all the difference in whether your project gets noticed. This article is about Django projects, but most of the advice applies across all code bases.
  • 在只读 Docker 容器中运行 Flask 服务器
    • JON JAGGER Learn how to run a Python server inside a read-only Docker container and how to pre-bundle the SCSS and JS files in a separate step. (是也乎: 容器是个好想法, 但是, 用起来真心没有 BSD 的 jail 简洁; )
  • 高效 Python 程序员的 VSCode 快捷方式
    • RODRIGO GIRÃO SERRÃO Learn keyboard shortcuts that will make you a more efficient and productive Python programmer with VS Code.
  • 用 OpenAI 和 DALL·E 2 生成图像
    • IDOWU OMISOLA Learn how to use Python to interface with OpenAI’s API to do image generation.

好物/妙品/

Interesting Projects, Tools and Libraries, Projects & Code


📆🐍 活动/大会

Events, MeetUp 真的是全球线下活动组织中心


历史上的这周


DAMA

❤️ Happy Pythonic ;-(大妈私人无责任播报)

          _~^--~_
      \/ /  ☉ +  \ \/
        '_   ⏡   _'
        / '--~--' )
...act by ferris-actor v0.2.4 (built on 23.0303.201916)

PS

Happy Pythoning!

Copyright © 2023 PyCoder’s Weekly, All rights reserved.

PPS

不觉中蟒周刊快译已经到了第10+2个年头 开始有小伙伴加入承担 pythonisa 周刊的翻译, 从来没提醒过, 可就这么默默坚持下来了… 问为什么: [皱眉]每周新闻资讯 怎么能错过 看看有什么新东西 当有新的发现时: what f**k 还能这样玩? 还有这东西? 每周开彩蛋[吃瓜] 无法同意更多… 很多社区贡献看起来辛苦, 其实受益最多的, 就是主动承担者也. 所以++> 锈周刊 -> Weekly :: China


好文笔,感叹号年度配额: 2/3 投稿/反馈邮箱: [email protected] (邮件列表地址, 当成正常邮件发送邮件就好, 不用注册, 不用翻越…)

ZoomQuiet/大妈 就是四处 是也乎,( ̄▽ ̄) 的那个大妈:

私自嗯哼: ZoomQuiet (订阅号: ZoomQuiet42)
公开课程: 蟒营 (订阅号: Mainium)
历史吐糟: Chaos42 (订阅号 PythoniCamp)
as 创始组织者:
    PyChina (订阅号: PyChinaOrg)
    本地社区: 
        GDG珠海 (订阅号: GDG-ZhuHai)
        TFUG珠海 (订阅号: ZH_TFUG)