並び順

ブックマーク数

期間指定

  • から
  • まで

1 - 40 件 / 90件

新着順 人気順

python if name main command line argumentsの検索結果1 - 40 件 / 90件

  • 2024年のPythonプログラミング - Uzabase for Engineers

    ソーシャル経済メディア「NewsPicks」で推薦や検索などのアルゴリズム開発をしている北内です。Pythonは頻繁に新機能や便利なライブラリが登場し、ベストプラクティスの変化が激しい言語です。そこで、2024年2月時点で利用頻度の高そうな新機能、ライブラリ、ツールなどを紹介したいと思います。 この記事では広く浅く紹介することに重点を置き、各トピックについては概要のみを紹介します。詳細な使用方法に関しては各公式サイト等での確認をおすすめします。なお、本記事ではOSとしてmacOSを前提としています。 環境構築 Pythonの環境構築はpyenvとPoetryの組み合わせがもっとも標準的でしょう。 以下の手順でpyenvとPythonをインストールできます。 brew install pyenv # Bashの場合 echo 'eval "$(pyenv init -)"' >> ~/.ba

      2024年のPythonプログラミング - Uzabase for Engineers
    • Chromium にコントリビュートするための周辺知識 | blog.jxck.io

      Intro Chromium にコントリビュートするためには、ソースコードを理解する以外にも、もろもろ必要な周辺知識がある。 ドキュメントはかなり整備されている方ではあるが、そのドキュメントにたどり着くのが難しい場合もある。 レビュアーなどが親切に教えてくれるものをローカルにメモしているが、それも散らばってきたため、ここにまとめることにする。 まずは初期状態で公開するが、どんどん更新していき、長くなっても分割しないで追記を繰り返そうと考えている。 関連サイト 始めて取り組もうとすると、まずどこを見ればわからないところから始まる。 似たようないくつかのサイトがあり、使い分けがされているからだ。 code search https://source.chromium.org/chromium/chromium/src コードをインタラクティブに検索するためのサイト Workspace 風の U

        Chromium にコントリビュートするための周辺知識 | blog.jxck.io
      • プロと読み解く Ruby 3.1 NEWS - クックパッド開発者ブログ

        技術部の笹田(ko1)と遠藤(mame)です。クックパッドで Ruby (MRI: Matz Ruby Implementation、いわゆる ruby コマンド) の開発をしています。お金をもらって Ruby を開発しているのでプロの Ruby コミッタです。 本日 12/25 に、ついに Ruby 3.1.0 がリリースされました(Ruby 3.1.0 リリース )。今年も Ruby 3.1 の NEWS.md ファイルの解説をします。NEWS ファイルとは何か、は以前の記事を見てください。 プロと読み解く Ruby 2.6 NEWS ファイル - クックパッド開発者ブログ プロと読み解くRuby 2.7 NEWS - クックパッド開発者ブログ プロと読み解くRuby 3.0 NEWS - クックパッド開発者ブログ 本記事は新機能を解説することもさることながら、変更が入った背景や苦労な

          プロと読み解く Ruby 3.1 NEWS - クックパッド開発者ブログ
        • OpenAI APIを使ってgit commitメッセージやコードレビューをAIに任せましょう! - GMOインターネットグループ グループ研究開発本部

          2024.09.27 OpenAI APIを使ってgit commitメッセージやコードレビューをAIに任せましょう! 次世代システム研究室の Y.I です。 OpenAI API を活用してちょっと便利なコマンドを作成したのでご紹介します。作成したものは、「自動Git Commitメッセージ生成」と「コードレビュー」機能です。LangChainやVectorDBなどを利用しなくても、発想次第で便利な機能を作れますので1例としてご覧ください。 機能紹介 Pythonで以下の機能を実現しています。 Git commitメッセージの自動生成 Gitの変更履歴に基づき、適切な日本語のcommitメッセージを生成します。 コードレビューの自動化 Gitの変更履歴に基づき、コードに問題がないかやパフォーマンス改善の提案を行います。 openai apiのtokenを環境変数から取り込み 簡易的ですが

            OpenAI APIを使ってgit commitメッセージやコードレビューをAIに任せましょう! - GMOインターネットグループ グループ研究開発本部
          • プロと読み解くRuby 3.4 NEWS - STORES Product Blog

            プロと読み解くRuby 3.4 NEWS テクノロジー部門技術基盤グループの笹田(ko1)と遠藤(mame)です。Ruby (MRI: Matz Ruby Implementation、いわゆる ruby コマンド) の開発をしています。お金をもらって Ruby を開発しているのでプロの Ruby コミッタです。 本日 12/25 に、恒例のクリスマスリリースとして、Ruby 3.4.0 がリリースされました(Ruby 3.4.0 リリース )。今年も STORES Product Blog にて Ruby 3.4 の NEWS.md ファイルの解説をします(ちなみに、STORES Advent Calendar 2024 の記事になります。他も読んでね)。NEWS ファイルとは何か、は以前の記事を見てください。 プロと読み解く Ruby 2.6 NEWS ファイル - クックパッド開発者

              プロと読み解くRuby 3.4 NEWS - STORES Product Blog
            • LogLog Games

              The article is also available in Chinese. Disclaimer: This post is a very long collection of thoughts and problems I've had over the years, and also addresses some of the arguments I've been repeatedly told. This post expresses my opinion the has been formed over using Rust for gamedev for many thousands of hours over many years, and multiple finished games. This isn't meant to brag or indicate su

              • 第752回 RISC-VのシングルボードコンピューターであるVisionFive 2を使ってみる | gihyo.jp

                今回はStarFive Technology製のRISC-Vシングルボードコンピューター(SBC)であるVisionFive 2にDebianをインストールして、その性能を計測してみましょう。 RISC-VとVisionFive 2 RISC-V(りすく・ふぁいぶ)は今もっとも熱い命令セットアーキテクチャーです。2010年頃に生まれたRISC-Vは、オープンな規格という強みを活かしてどんどんエコシステムを構築し、今では様々な企業がRISC-Vに本格的に手を出す状況になっています。AMD64/Intel 64やARMには性能も普及度合いもまだまだ及びませんが、今の勢いを維持できれば近い将来その状況は変わってくるでしょう。 本連載でも2018年ぐらいから、RISC-Vの記事を何度か取り上げていました。 第505回:「オープン規格の新しい命令セットアーキテクチャRISC-V入門 ツールチェインを

                  第752回 RISC-VのシングルボードコンピューターであるVisionFive 2を使ってみる | gihyo.jp
                • How to create a Python package in 2022

                  Photo by Claudio Schwarz on Unsplash. How to create a Python package? In order to create a Python package, you need to write the code that implements the functionality you want to put in your package, and then you need to publish it to PyPI. That is the bare minimum. Nowadays, you can also set up a variety of other things to make your life easier down the road: continuous testing of your package;

                    How to create a Python package in 2022
                  • Gamedev in Lisp. Part 1: ECS and Metalinguistic Abstraction - cl-fast-ecs by Andrew

                    Gamedev in Lisp. Part 1: ECS and Metalinguistic Abstraction In this series of tutorials, we will delve into creating simple 2D games in Common Lisp. The result of the first part will be a development environment setup and a basic simulation displaying a 2D scene with a large number of physical objects. It is assumed that the reader is familiar with some high-level programming language, has a gener

                      Gamedev in Lisp. Part 1: ECS and Metalinguistic Abstraction - cl-fast-ecs by Andrew
                    • June 2022 (version 1.69)

                      Update 1.69.1: The update addresses these issues. Update 1.69.2: The update addresses these issues. Downloads: Windows: x64 Arm64 | Mac: Universal Intel silicon | Linux: deb rpm tarball Arm snap Welcome to the June 2022 release of Visual Studio Code. There are many updates in this version that we hope you'll like, some of the key highlights include: 3-way merge editor - Resolve merge conflicts wit

                        June 2022 (version 1.69)
                      • The Roc Programming Language

                        Examples Roc is a young language. It doesn't even have a numbered release yet, just nightly builds! However, it can already be used for several things if you're up for being an early adopter— with all the bugs and missing features which come with that territory. Here are some examples of how it can be used today. Command-Line Interfaces main! = |args| Stdout.line!("Hello!") You can use Roc to crea

                        • Golang Mini Reference 2022: A Quick Guide to the Modern Go Programming Language (REVIEW COPY)

                          Golang Mini Reference 2022 A Quick Guide to the Modern Go Programming Language (REVIEW COPY) Harry Yoon Version 0.9.0, 2022-08-24 REVIEW COPY This is review copy, not to be shared or distributed to others. Please forward any feedback or comments to the author. • feedback@codingbookspress.com The book is tentatively scheduled to be published on September 14th, 2022. We hope that when the release da

                          • AST vs. Bytecode: Interpreters in the Age of Meta-Compilation

                            233 AST vs. Bytecode: Interpreters in the Age of Meta-Compilation OCTAVE LAROSE, University of Kent, UK SOPHIE KALEBA, University of Kent, UK HUMPHREY BURCHELL, University of Kent, UK STEFAN MARR, University of Kent, UK Thanks to partial evaluation and meta-tracing, it became practical to build language implementations that reach state-of-the-art peak performance by implementing only an interprete

                            • June 2023 (version 1.80)

                              Update 1.80.1: The update addresses these issues. Update 1.80.2: The update addresses this security issue. Downloads: Windows: x64 Arm64 | Mac: Universal Intel silicon | Linux: deb rpm tarball Arm snap Welcome to the June 2023 release of Visual Studio Code. There are many updates in this version that we hope you'll like, some of the key highlights include: Accessibility improvements - Accessible V

                                June 2023 (version 1.80)
                              • Kalyn: a self-hosting compiler for x86-64

                                Over the course of my Spring 2020 semester at Harvey Mudd College, I developed a self-hosting compiler entirely from scratch. This article walks through many interesting parts of the project. It’s laid out so you can just read from beginning to end, but if you’re more interested in a particular topic, feel free to jump there. Or, take a look at the project on GitHub. Table of contents What the pro

                                • February 2021 (version 1.54)

                                  Join a VS Code Dev Days event near you to learn about AI-assisted development in VS Code. Update 1.54.1: The update addresses an issue with an extension dependency. Update 1.54.2: The update addresses these issues. Update 1.54.3: The update addresses this issue. Downloads: Windows: x64 Arm64 | Mac: Universal Intel silicon | Linux: deb rpm tarball Arm snap Welcome to the February 2021 release of Vi

                                    February 2021 (version 1.54)
                                  • July 2022 (version 1.70)

                                    Join a VS Code Dev Days event near you to learn about AI-assisted development in VS Code. Update 1.70.1: The update addresses these issues. Update 1.70.2: The update addresses these issues. Update 1.70.3: This update is only available for Windows 7 users and is the last release supporting Windows 7. Downloads: Windows: x64 Arm64 | Mac: Universal Intel silicon | Linux: deb rpm tarball Arm snap Welc

                                      July 2022 (version 1.70)
                                    • A Walk with LuaJIT

                                      The following is a chronicle of implementing a general purpose zero-instrumentation BPF based profiler for LuaJIT. Some assumptions are made about what this entails and it may be helpful to read some of our other work in this area. One major change from prior efforts is that instead of working with the original Parca unwinder we are now working with the OpenTelemetry eBPF profiler. If you missed t

                                        A Walk with LuaJIT
                                      • AWS CLIをAWS IAM Identity Center(SSO)で認証させるには? | DevelopersIO

                                        AWS OrganizationsのAWS IAM Identity Center(旧AWS Single Sign-On;AWS SSO)を利用すると、Organizations配下のAWSアカウントにSSOできます。 本記事では、同機能をAWS CLIから利用する方法を紹介します。 AWS IAM Identity Centerの詳細は次のブログを参照ください。 AWSアクセスポータルとIAMロールの2つのセッションの詳細は次のブログを参照ください。 なお、本記事ではAWS Identity Center directoryでユーザー管理しているものとします。 ポイント IAM Identity CenterにはAWS CLI v2が対応。v1は未対応 設定ファイルはAWS CLIだけでなくAWS SDK全般で流用可能 IAM Identity Centerはリージョナル・サービス I

                                          AWS CLIをAWS IAM Identity Center(SSO)で認証させるには? | DevelopersIO
                                        • Wasm core dumps and debugging Rust in Cloudflare Workers

                                          Wasm core dumps and debugging Rust in Cloudflare Workers2023-08-14 A clear sign of maturing for any new programming language or environment is how easy and efficient debugging them is. Programming, like any other complex task, involves various challenges and potential pitfalls. Logic errors, off-by-ones, null pointer dereferences, and memory leaks are some examples of things that can make software

                                            Wasm core dumps and debugging Rust in Cloudflare Workers
                                          • How to improve Python packaging, or why fourteen tools are at least tw

                                            There is an area of Python that many developers have problems with. This is an area that has seen many different solutions pop up over the years, with many different opinions, wars, and attempts to solve it. Many have complained about the packaging ecosystem and tools making their lives harder. Many beginners are confused about virtual environments. But does it have to be this way? Are the current

                                            • 0.8.0 Release Notes ⚡ The Zig Programming Language

                                              Tier 4 Support § Support for these targets is entirely experimental. If this target is provided by LLVM, LLVM may have the target as an experimental target, which means that you need to use Zig-provided binaries for the target to be available, or build LLVM from source with special configure flags. zig targets will display the target if it is available. This target may be considered deprecated by

                                              • Zig in 30 minutes

                                                test.md A half-hour to learn Zig This is inspired by https://fasterthanli.me/blog/2020/a-half-hour-to-learn-rust/ Basics the command zig run my_code.zig will compile and immediately run your Zig program. Each of these cells contains a zig program that you can try to run (some of them contain compile-time errors that you can comment out to play with) You'll want to declare a main() function to get

                                                  Zig in 30 minutes
                                                • Real-world gen AI use cases from the world's leading organizations | Google Cloud Blog

                                                  AI is here, AI is everywhere: Top companies, governments, researchers, and startups are already enhancing their work with Google's AI solutions. Published April 12, 2024; last updated October 9, 2025. A year and a half ago, during Google Cloud Next 24, we published this list for the first time. It numbered 101 entries. It felt like a lot at the time, and served as a showcase of how much momentum b

                                                    Real-world gen AI use cases from the world's leading organizations | Google Cloud Blog
                                                  • Lean for JavaScript Developers — overreacted

                                                    Lean for JavaScript DevelopersSeptember 2, 2025 This is my opinionated syntax primer for the Lean programming language. It is far from complete and may contain inaccuracies (I’m still learning Lean myself) but this is how I wish I was introduced to it, and what I wish was clarified. Why Lean? This post assumes you’re already eager to learn a bit of Lean. For motivation, I humbly submit to you two

                                                      Lean for JavaScript Developers — overreacted
                                                    • The Go Programming Language and Environment – Communications of the ACM

                                                      Go is a programming language created at Google in late 2007 and released as open source in November 2009. Since then, it has operated as a public project, with contributions from thousands of individuals and dozens of companies. Go has become a popular language for building cloud infrastructure: Docker, a Linux container manager, and Kubernetes, a container deployment system, are core cloud techno

                                                      • Node.js

                                                        2023-10-17, Version 21.0.0 (Current), @RafaelGSS and @targos We're excited to announce the release of Node.js 21! Highlights include updates of the V8 JavaScript engine to 11.8, stable fetch and WebStreams, a new experimental flag to change the interpretation of ambiguous code from CommonJS to ES modules (--experimental-default-type), many updates to our test runner, and more! Node.js 21 will repl

                                                          Node.js
                                                        • PowerShell: the object-oriented shell you didn’t know you needed

                                                          PowerShell is an interactive shell and scripting language from Microsoft. It’s object-oriented — and that’s not just a buzzword, that’s a big difference to how the standard Unix shells work. And it is actually usable as an interactive shell. Getting Started PowerShell is so nice, Microsoft made it twice. Specifically, there concurrently exist two products named PowerShell: Windows PowerShell (5.1)

                                                          • 0.10.0 Release Notes ⚡ The Zig Programming Language

                                                            Tier 4 Support § Support for these targets is entirely experimental. If this target is provided by LLVM, LLVM may have the target as an experimental target, which means that you need to use Zig-provided binaries for the target to be available, or build LLVM from source with special configure flags. zig targets will display the target if it is available. This target may be considered deprecated by

                                                            • So, What's So Special About The Mill Scala Build Tool?

                                                              So, What's So Special About The Mill Scala Build Tool? Mill is a Scala build tool that offers an alternative to the venerable SBT toolchain. Mill aims for simplicity by reusing concepts you are already familiar with, borrowing ideas from Functional Programming and modern tools like Bazel. Feedback from users of Mill is often surprisingly positive, with people saying it is "intuitive" or feels "jus

                                                              • Go 言語が生成するバイナリについて

                                                                Go 言語で実装されたツールを運用したり解析する側の視点から、Go 言語が生成するバイナリについて気になることを調べた。 $ cat /etc/os-release NAME="Amazon Linux" VERSION="2023" $ go version go version go1.20.6 linux/amd64 シングルバイナリ基本的に Go 言語では、コンパイルするとシングルバイナリが生成される。たとえば次のようなファイルを用意し、 package main import "fmt" func main() { fmt.Println("hello world") } ビルドすると、次のようにスタティックリンクされたバイナリが生成される。 $ go build main.go $ file main main: ELF 64-bit LSB executable, x86-6

                                                                  Go 言語が生成するバイナリについて
                                                                • Blogged Answers: My Experience Modernizing Packages to ESM

                                                                  Random musings on React, Redux, and more, by Redux maintainer Mark "acemarke" Erikson This is a post in the Blogged Answers series. Details on the painful experiences and hard-earned lessons I've learned migrating the Redux packages to ESM Table of Contents 🔗︎ Introduction Redux Packages Background Packages and Configurations Issue History Early Attempts Migrating to Vitest Initial Alpha Testing

                                                                    Blogged Answers: My Experience Modernizing Packages to ESM
                                                                  • CUDAなんてない!Ryzen + RADEONのAMD環境でもStable

                                                                    いま一部で話題のStable Diffusion。 ちょっと前から出ているMidjourneyと同じく、「画像生成AIが言葉から連想して絵を書いてくれる」というツール。 今はツールだけど、そのうち色々なアプリ、サービスのいち機能に自然な形で組み込まれると思います。 それが自分のPCでも動くらしい! それなら無駄にありあまるGPUパワー(というほどでもないけど)を使ってみたい!! と思い立ち触ってみたけれど、基本NVIDIA=CUDA推奨。 誰かRADEON=AMDでやってる奴いるでしょ! と思ったら意外と日本の記事が出てこなくて苦労しましたとさ。 バイブル基本この動画の通りにやっただけです。 が、これ系の知識が全く無かったので何回もやり直しました。 初めて動いた時は声がでたレベル。 当環境&必要なものCPU:AMD Ryzen 9 5900XGPU:AMD RADEON 6800XTMEM

                                                                      CUDAなんてない!Ryzen + RADEONのAMD環境でもStable
                                                                    • Node.js

                                                                      const watcher = fs.watch(testDirectory, { recursive: true }); watcher.on('change', function (event, filename) {}); Contributed by Yagiz Nizipli in #45098 Other notable changes deps update ICU to 72.1 (Michaël Zasso) #45068 doc add lukekarrys to collaborators (Luke Karrys) #45180 add anonrig to collaborators (Yagiz Nizipli) #45002 lib drop fetch experimental warning (Matteo Collina) #45287 util (SE

                                                                        Node.js
                                                                      • Boring Python: code quality

                                                                        Boring Python: code quality December 19, 2022 Django, Python This is the second in a series of posts I intend to write about how to build, deploy, and manage Python applications in as boring a way as possible. In the first post in the series I gave a definition of what I mean by “boring”, and it’s worth revisiting: I don’t mean “reliable” or “bug-free” or “no incidents”. While there is some overla

                                                                          Boring Python: code quality
                                                                        • Attacking UNIX Systems via CUPS, Part I

                                                                          Hello friends, this is the first of two, possibly three (if and when I have time to finish the Windows research) writeups. We will start with targeting GNU/Linux systems with an RCE. As someone who’s directly involved in the CUPS project said: From a generic security point of view, a whole Linux system as it is nowadays is just an endless and hopeless mess of security holes waiting to be exploited

                                                                            Attacking UNIX Systems via CUPS, Part I
                                                                          • GIMP - Development version: GIMP 2.99.12 Released

                                                                            GIMP 2.99.12 is a huge milestone towards GIMP 3.0. Many of the missing pieces are getting together, even though it is still a work in progress. As usual, issues are expected and in particular in this release which got important updates in major areas, such as canvas interaction code, scripts, but also theming… “CMYK space invasion”, by Jehan (based on GPLv3 code screencast), Creative Commons by-sa

                                                                              GIMP - Development version: GIMP 2.99.12 Released
                                                                            • 【GROMACS】Umbrella samplingによるMD simulation 【In silico創薬】【SMD】 - LabCode

                                                                              Windows 11 Home, 13th Gen Intel(R) Core(TM) i7-13700, 64 ビット オペレーティング システム、x64 ベース プロセッサ, メモリ:32GB Umbrella Samplingの概要と目的Umbrella Samplingは、分子がめったに起こさないような状態変化(たとえば、タンパク質同士が離れるなど)を詳しく調べるための計算手法です。通常の分子動力学(MD)では、エネルギー的に安定な状態にとどまりやすく、重要な変化が起こる確率が低いため、十分な情報が得られません。 たとえば、タンパク質AとBがくっついている状態から、少しずつ離れていく様子を観察したいとき、まずAとBを少しずつ引き離すSteered Molecular Dynamics(SMD)などのシミュレーションで、さまざまな距離の構造を取得します。その中から、0.5nm、0.7

                                                                              • prompts.chat

                                                                                Welcome to the “Awesome ChatGPT Prompts” repository! While this collection was originally created for ChatGPT, these prompts work great with other AI models like Claude, Gemini, Hugging Face Chat, Llama, Mistral, and more. ChatGPT is a web interface created by OpenAI that provides access to their GPT (Generative Pre-trained Transformer) language models. The underlying models, like GPT-4o and GPT-o

                                                                                • Rust on MIPS64 Windows NT 4.0

                                                                                  Introduction Some part of me has always been fascinated with coercing code to run in weird places. I scratch this itch a lot with my security research projects. These often lead me to writing shellcode to run in kernels or embedded hardware, sometimes with the only way being through an existing bug. For those not familiar, shellcode is honestly hard to describe. I don’t know if there’s a very form

                                                                                    Rust on MIPS64 Windows NT 4.0