並び順

ブックマーク数

期間指定

  • から
  • まで

1 - 40 件 / 77件

新着順 人気順

python3 string format exampleの検索結果1 - 40 件 / 77件

  • Ubuntu 24.04 LTS サーバ構築手順書

    0 issue "letsencrypt.org" 0 issuewild "letsencrypt.org" 0 iodef "mailto:yourmail@example.jp" §OS再インストール 初期設定で期待通りの設定ができていない場合は、OSの再インストールをする。 さくらVPSのコントロールパネルから、OSを再インストールするサーバを選ぶ。 www99999ui.vs.sakura.ne.jp §OSのインストール操作 Ubuntu 24.04 LTS を選ぶ。 OSインストール時のパケットフィルタ(ポート制限)を無効にして、ファイアウォールは手動で設定することにする。 初期ユーザのパスワードに使える文字が制限されているので、ここでは簡単なパスワードにしておき、後ですぐに複雑なパスワードに変更する。 公開鍵認証できるように公開鍵を登録しておく。 §秘密鍵と公開鍵の作成 ク

      Ubuntu 24.04 LTS サーバ構築手順書
    • 浮動小数点型の算術とお近づきになりたい人向けの記事 - えびちゃんの日記

      お近づきになりたい人向けシリーズです。 いろいろなトピックを詰め込みましたが、「これら全部を知らないといけない」のようなつもりではなく、いろいろなことを知るきっかけになったらいいなという気持ちなので、あまり身構えずにちょっとずつ読んでもらえたらうれしい気がします。 まえがき 予備知識 規格 用語 精度という語について 記法 表現について 有限値の表現について エンコードについて 丸めについて よくある誤差や勘違いの例 0.1 = 1 / 10? 0.1 + 0.2 = 0.3? 整数の誤差 Rump’s Example 基本的な誤差評価 用語に関して 実数の丸め 有理数の丸め 基本演算の丸め 差について 複数回の演算 補題たち 桁落ちについて Re: Rump’s example 融合積和 数学関数に関する式の計算 誤差の削減に関して 総和計算 数学関数の精度について 比較演算について 雑

        浮動小数点型の算術とお近づきになりたい人向けの記事 - えびちゃんの日記
      • SaaS におけるテナントリソースへのリクエストルーティングを JWT を用いて実現する | Amazon Web Services

        Amazon Web Services ブログ SaaS におけるテナントリソースへのリクエストルーティングを JWT を用いて実現する みなさんこんにちは。ソリューションアーキテクトの福本です。 本投稿のテーマは Software as a Service(SaaS)におけるルーティングです。 SaaS ではテナントごとにサーバーなどのリソースが分離されていることがあります。そのため、各テナントに属するユーザーからのリクエストを適切なリソースへとルーティングする必要があります。 具体的なルーティングの話に入る前に、SaaS のテナント分離モデルについて説明をします。SaaS では、テナントの分離モデルとしてサイロ、プール、ブリッジモデルが存在します。また、ユーザーがサブスクライブしている利用プラン (ティア) によって、リソースの分離形態が変わるような、階層ベースの分離もあります。 サイ

          SaaS におけるテナントリソースへのリクエストルーティングを JWT を用いて実現する | Amazon Web Services
        • ぼくのMac環境 ver.のんピ | DevelopersIO

          何年後かの自分へ こんにちは、のんピ(@non____97)です。 業務で使用する新しいMacが届きました。 新しいMacを初期セットアップするにあたって「今の設定どうだったっけ...」と調べる時間が結構かかってしまいました ということで何年後かの自分がまた新しいMacに乗り換える際に手間取らないように、設定した内容を書き記しておきます。 移行先のMacの情報は以下の通りです。M1 Max、嬉しい。 # OSのバージョンの確認 > sw_vers ProductName: macOS ProductVersion: 12.4 BuildVersion: 21F79 # カーネルのバージョン確認 > uname -r 21.5.0 # CPUのアーキテクチャの確認 > uname -m arm64 # CPUの詳細確認 > sysctl -a machdep.cpu machdep.cpu.

            ぼくのMac環境 ver.のんピ | DevelopersIO
          • GPT in 60 Lines of NumPy | Jay Mody

            January 30, 2023 In this post, we'll implement a GPT from scratch in just 60 lines of numpy. We'll then load the trained GPT-2 model weights released by OpenAI into our implementation and generate some text. Note: This post assumes familiarity with Python, NumPy, and some basic experience with neural networks. This implementation is for educational purposes, so it's missing lots of features/improv

            • 缶つぶし機とソフトウェア移行技術 - Refactoring to Rust の読書感想文 - じゃあ、おうちで学べる

              はじめに ——あるいは、「知っている」と「理解している」の間 Rustのことは、知っていた。学習もしていた。実務でも使っていた。 でも、それは知っているつもりだった。 知ってるつもり 無知の科学 (ハヤカワ文庫NF) 作者:スティーブン スローマン,フィリップ ファーンバック早川書房Amazon 日々Rustで開発し、BoxとRcとArcを使い分け、tokio::spawnでタスクを生成し、?演算子を当たり前のように書いている。FFI?PyO3使えばいいでしょ。WebAssembly?wasm-bindgenがあるじゃない。技術的には、確かに「使える」レベルにはあった。 でも、心のどこかで感じていた違和感があった。 オートバイのエンジンを分解できる人と、エンジンが動く原理を理解している人は違う。コードが動くことと、なぜそう書くべきかを理解することも違う。私は前者だった。メカニックではあった

                缶つぶし機とソフトウェア移行技術 - Refactoring to Rust の読書感想文 - じゃあ、おうちで学べる
              • 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)
                • Announcing Amazon ECS deployment circuit breaker | Amazon Web Services

                  Containers Announcing Amazon ECS deployment circuit breaker Today, we announced the Amazon ECS deployment circuit breaker for EC2 and Fargate compute types. With this feature, Amazon ECS customers can now automatically roll back unhealthy service deployments without the need for manual intervention. This empowers customers to quickly discover failed deployments, while not having to worry about res

                    Announcing Amazon ECS deployment circuit breaker | Amazon Web Services
                  • Python is a Compiled Language

                    This blog post hopes to convince you that Python is a compiled language. And by “Python”, I don’t mean alternate versions of Python like PyPy, Mypyc, Numba, Cinder, or even Python-like programming languages like Cython, Codon, Mojo1—I mean the regular Python: CPython! The Python that is probably installed on your computer right now. The Python that you got when you searched “python” on Google and

                    • Harden-Runner detection: tj-actions/changed-files action is compromised - StepSecurity

                      IntroductionWe have concluded our investigation into the critical security incident involving the `tj-actions/changed-files` GitHub Action. The issue has been reported to GitHub, and an official CVE — CVE-2025-30066 — has been published to track the incident. You can find more details in GitHub Issue #2463. Based on our findings, the Action was compromised and posed a significant risk by exposing

                        Harden-Runner detection: tj-actions/changed-files action is compromised - StepSecurity
                      • The unreasonable effectiveness of f‍-‍strings and re.VERBOSE

                        ... in which we look at one or two ways to make life easier when working with Python regular expressions. tl;dr: You can compose verbose regular expressions using f‍-‍strings. Here's a real-world example – instead of this: 1pattern = r"((?:\(\s*)?[A-Z]*H\d+[a-z]*(?:\s*\+\s*[A-Z]*H\d+[a-z]*)*(?:\s*[\):+])?)(.*?)(?=(?:\(\s*)?[A-Z]*H\d+[a-z]*(?:\s*\+\s*[A-Z]*H\d+[a-z]*)*(?:\s*[\):+])?(?![^\w\s])|$)"

                        • Node.js — Node.js v24.0.0 (Current)

                          2025-05-06, Version 24.0.0 (Current), @RafaelGSS and @juanarbol We’re excited to announce the release of Node.js 24! This release brings several significant updates, including the upgrade of the V8 JavaScript engine to version 13.6 and npm to version 11. Starting with Node.js 24, support for MSVC has been removed, and ClangCL is now required to compile Node.js on Windows. The AsyncLocalStorage API

                            Node.js — Node.js v24.0.0 (Current)
                          • The Absolute Minimum Every Software Developer Must Know About Unicode in 2023 (Still No Excuses!) @ tonsky.me

                            If you combine this with the Unicode table, you’ll see that English is encoded with 1 byte, Cyrillic, Latin European languages, Hebrew and Arabic need 2, and Chinese, Japanese, Korean, other Asian languages, and Emoji need 3 or 4. A few important points here: First, UTF-8 is byte-compatible with ASCII. The code points 0..127, the former ASCII, are encoded with one byte, and it’s the same exact byt

                              The Absolute Minimum Every Software Developer Must Know About Unicode in 2023 (Still No Excuses!) @ tonsky.me
                            • Why I use attrs instead of pydantic

                              This post is an account of why I prefer using the attrs library over Pydantic. I'm writing it since I am often asked this question and I want to have something concrete to link to. This is not meant to be an objective comparison of attrs and Pydantic; I'm not interested in comparing bullet points of features, nor can I be unbiased since I'm a major contributor to attrs (at time of writing, second

                              • Node.js 16.x runtime now available in AWS Lambda | Amazon Web Services

                                AWS Compute Blog Node.js 16.x runtime now available in AWS Lambda This post is written by Dan Fox, Principal Specialist Solutions Architect, Serverless. You can now develop AWS Lambda functions using the Node.js 16 runtime. This version is in active LTS status and considered ready for general use. To use this new version, specify a runtime parameter value of nodejs16.x when creating or updating fu

                                  Node.js 16.x runtime now available in AWS Lambda | Amazon Web Services
                                • はじめての自然言語処理 Fusion-In-Decoder でクイズに答えるモデルを作る | オブジェクトの広場

                                  今回は Fusion-In-Decoder を使ってクイズに答えるモデルを作ります。以前から Wikipedia 等の外部情報を参照できるテキスト生成モデルを試してみたいと思っていました。Fusion-In-Decoder の発表は 2020 年なので少し前のモデルですが、T5 ベースで手軽に試せるサイズ感ですので、日本語で試してみましょう。 1. はじめに 今回紹介する Fusion-In-Decoder(以下、FiD )1 は Meta AI (当時は Facebook AI Research) が発表した Open Domain question Answering タスクを解くテキスト生成モデルです。 じつは、以前から外部情報を参照できるテキスト生成モデルを試してみたくて2、 Google の RETRO3 の論文を読んでたんです。 なのですが、外部情報のサイズ感が 1000 B

                                    はじめての自然言語処理 Fusion-In-Decoder でクイズに答えるモデルを作る | オブジェクトの広場
                                  • Advent of Code on the Nintendo DS

                                    It is December. That means annoying Christmas things are everywhere, including but not limited to the annual programming semi-competition known as Advent of Code. The problem with Advent of Code is that it is a waste of time. Most of the puzzles are in the realm of either string processing (somewhat applicable to programming), logic puzzles (not really applicable to most programming), or stupid go

                                    • AWS Step Function承認フローをAWS Step Functionsのワークフローから呼び出して多段階承認フローを作成する方法(AWS Systems Manager Automation & Amazon EventBridge編) - NRIネットコムBlog

                                      小西秀和です。 AI技術の急速な進化に伴い、従来の業務プロセスを見直す必要性が高まっています。 特に、多段階承認フローのあり方について、新しい視点からアプローチしたいと考え、この記事を執筆しました。 これまで多段階承認フローは、しばしば冗長で効率が悪いと批判されてきました。しかし同時に、専門知識や権限を持つ人間が最終判断を下す重要な場でもあります。 そこで私は次のような理由から、将来的に生成AIを多段階承認フローに組み込むことを見据え、AWS Step Functionsを活用した多段階承認フローシステムを試作してみました。 APIを介して承認フローをシステム化することで、人間と生成AIの間で意思決定プロセスを柔軟に切り替えられる 初期段階では人間が承認を行い、生成AIの能力が十分と判断された場合に段階的にAIへ移行できる 生成AIの判断に不安がある場合や、最終確認が必要な場合は、人間が承

                                        AWS Step Function承認フローをAWS Step Functionsのワークフローから呼び出して多段階承認フローを作成する方法(AWS Systems Manager Automation & Amazon EventBridge編) - NRIネットコムBlog
                                      • Python 3.14から追加された「t文字列」、何に使う? #こまPy|Atsushi Shibata

                                        みんなのPython 第5版、予約受付中です。Pythonにt文字列(template strings)が追加されます。 見た目はf文字列に似ていますが、最初にtを加えたリテラルで表記します。また、f文字列はその場で評価されますが、t文字列はTemplateオブジェクトになるのが大きな違いです。遅延評価・自動エスケープ・構造化ログなどの安全な処理を一貫して適用でき、f文字列では実現できなかったような処理が可能になります。 この記事では、簡単に機能の説明をしながら、具体的な利用方法を見てゆきます。Python 3.14から追加された可能性てんこ盛りの新機能を、便利にかしこく活用する方法について解説しましょう。 t文字列ってなに?Python 3.14で導入(string.templatelibモジュールが追加)。ステアリング・カウンシルは2025年4月10日にPEP 750を承認しました。

                                          Python 3.14から追加された「t文字列」、何に使う? #こまPy|Atsushi Shibata
                                        • "�[31m"?! ANSI Terminal security in 2023 and finding 10 CVEs

                                          This paper reflects work done in late 2022 and 2023 to audit for vulnerabilities in terminal emulators, with a focus on open source software. The results of this work were 10 CVEs against terminal emulators that could result in Remote Code Execution (RCE), in addition various other bugs and hardening opportunities were found. The exact context and severity of these vulnerabilities varied, but some

                                          • AWS Copilot をひと通り使ってみた - 本日も乙

                                            Amazon ECS のデプロイツールを調査した際に AWS Copilot をひと通り触ってみたのでそのメモです。 AWS Copilot とは Getting started コンセプト Application Environments Service Jobs Pipelines Manifest Advanced ドメインの設定 既存の VPC、サブネットをインポートする サービスの作成 デプロイ 本番環境の作成 パイプラインの作成 バックエンドサービスの作成 接続確認 データソースの追加 アドオン 単発の ECS タスクを実行 ECS タスクの定期実行 削除 長所 短所 まとめ 参考URL AWS Copilot とは Amazon ECS を簡単にデプロイツールで ECS CLI の後継です。2020年11月に GA になりました。 AWS Copilot のメリットは Doc

                                              AWS Copilot をひと通り使ってみた - 本日も乙
                                            • January 2024 (version 1.86)

                                              Version 1.106 is now available! Read about the new features and fixes from October. Update 1.86.2: The update addresses these issues. Update 1.86.1: The update addresses these issues. Downloads: Windows: x64 Arm64 | Mac: Universal Intel silicon | Linux: deb rpm tarball Arm snap Welcome to the January 2024 release of Visual Studio Code. There are many updates in this version that we hope you'll lik

                                                January 2024 (version 1.86)
                                              • Manus tools and prompts

                                                agent loop �� �p�� You are Manus, an AI agent created by the Manus team. You excel at the following tasks: 1. Information gathering, fact-checking, and documentation 2. Data processing, analysis, and visualization 3. Writing multi-chapter articles and in-depth research reports 4. Creating websites, applications, and tools 5. Using programming to solve various problems beyond development 6. Variou

                                                  Manus tools and prompts
                                                • ​Getting Started with Python

                                                  Python is a powerful programming language that provides many packages that we can use. Using the versatile Python programming language, we can develop the following: AutomationDesktop applicationAndroidWebIoT home automationData Science and the list goes on.In this article, our primary focus will be knowing how to start learning Python and the essentials required to be a data scientist. Below is t

                                                    ​Getting Started with Python
                                                  • Here’s how I use LLMs to help me write code

                                                    11th March 2025 Online discussions about using Large Language Models to help write code inevitably produce comments from developers who’s experiences have been disappointing. They often ask what they’re doing wrong—how come some people are reporting such great results when their own experiments have proved lacking? Using LLMs to write code is difficult and unintuitive. It takes significant effort

                                                      Here’s how I use LLMs to help me write code
                                                    • Bucket full of secrets – Terraform exfiltration | Mercari Engineering

                                                      Background At Mercari, we utilize many microservices developed across multiple different teams. Each team has ownership over not only their code, but also the infrastructure necessary to run their services. To allow developers to take ownership of their infrastructure we use HashiCorp Terraform to define the infrastructure as code. Developers can use Terraform native resources or custom modules pr

                                                        Bucket full of secrets – Terraform exfiltration | Mercari Engineering
                                                      • Scripts I wrote that I use all the time

                                                        In my decade-plus of maintaining my dotfiles, I’ve written a lot of little shell scripts. Here’s a big list of my personal favorites. Clipboard copy and pasta are simple wrappers around system clipboard managers, like pbcopy on macOS and xclip on Linux. I use these all the time. # High level examples run_some_command | copy pasta > file_from_my_clipboard.txt # Copy a file's contents copy < file.tx

                                                        • July 2025 (version 1.103)

                                                          Join a VS Code Dev Days event near you to learn about AI-assisted development in VS Code. Release date: August 7, 2025 Update 1.103.1: The update adds GPT-5 prompt improvements, support for GPT-5 mini, and addresses these issues. Update 1.103.2: The update addresses these issues. Downloads: Windows: x64 Arm64 | Mac: Universal Intel silicon | Linux: deb rpm tarball Arm snap Welcome to the July 2025

                                                            July 2025 (version 1.103)
                                                          • とほほのFlask入門 - とほほのWWW入門

                                                            Flaskとは インストール チュートリアル Hello world! デバッグモード ルーティング指定 @app.route() URL末尾のスラッシュ データを受け取る requestオブジェクト メソッド・パス情報 リクエストパラメータ その他のリクエスト情報 ファイルアップロード データを返却する レスポンスデータ HTTPステータス テンプレートファイル スタティックファイル レスポンスヘッダ Cookie リダイレクト URLを関数名で指定する その他ノウハウ エラーページのカスタマイズ JSONを扱う セッション ロギング 前処理・後処理 グローバルオブジェクト コンフィグ クラスメソッドを呼び出す 実装サンプル ログイン認証 REST-APIサンプル リンク Flaskとは 「フラスク」と呼ばれます。理科実験で使用する「フラスコ」と同じ単語です。 Pythonベースの軽量な

                                                            • Linux Executables Deployed as Stealth Windows Loaders

                                                              No Longer Just Theory: Black Lotus Labs Uncovers Linux Executables Deployed as Stealth Windows Loaders Executive Summary In April 2016, Microsoft shocked the PC world when it announced the Windows Subsystem for Linux (WSL). WSL is a supplemental feature that runs a Linux image in a near-native environment on Windows, allowing for functionality like command line tools from Linux without the over-he

                                                                Linux Executables Deployed as Stealth Windows Loaders
                                                              • davepeck.org

                                                                Template strings, also known as t-strings, have been officially accepted as a feature in Python 3.14, which will ship in late 2025. 🎉 I'm excited; t-strings open the door to safer more flexible string processing in Python. What's the big idea with t-strings? Since they were introduced in Python 3.6, f-strings have become a very popular way to format strings. They are concise, readable, and powerf

                                                                • Let's Write a Tree-Sitter Major Mode

                                                                  Let’s Write a Tree-Sitter Major Mode Creating a standard programming major mode presents significant challenges, with the intricate tasks of establishing proper indentation and font highlighting being among the two hardest things to get right. It's painstaking work, and it'll quickly descend into a brawl between the font lock engine and your desire for correctness. Tree-sitter makes writing many m

                                                                    Let's Write a Tree-Sitter Major Mode
                                                                  • TIL: eBPF is awesome

                                                                    A blog about programming, technology and open-source stuff. I was doing some research at work for tracing and observability for microservices, when I came across Pixielabs. This tool advertises that you can instantly troubleshoot applications without any instrumentation or special code inside the apps, which sounded ✨magical✨ to me. So naturally I wanted to know a little more about what enables th

                                                                    • AWS公式のECSハンズオンがとても良かった!! - Qiita

                                                                      はじめに お疲れ様です。矢儀 @yuki_ink です。 こちらのAWS公式ハンズオンをやってみました。 ECSとFargate/EC2を利用した環境構築から、CI/CDパイプラインを利用したデプロイまで、一通り体験できる素晴らしいハンズオンでした。 次のようなみなさんにおすすめです。 ECSを知識として知ってはいるが、実際に触ったことがない コンテナの何が優れているのか、実感を持っては理解できない CI/CDパイプラインでコンテナをデプロイしてみたい ハンズオンで構築する環境の構成イメージはこちら。 1. VS Code Serverの構築 このハンズオンでは、開発環境として Visual Studio Code Server (VS Code Server) を利用するとのことで、まず、CloudFormationでVS Code Serverを構築していきます。 ハンズオンページの

                                                                        AWS公式のECSハンズオンがとても良かった!! - Qiita
                                                                      • We Spent $20 To Achieve RCE And Accidentally Became The Admins Of .MOBI

                                                                        Welcome back to another watchTowr Labs blog. Brace yourselves, this is one of our most astounding discoveries. SummaryWhat started out as a bit of fun between colleagues while avoiding the Vegas heat and $20 bottles of water in our Black Hat hotel rooms - has now seemingly become a major incident. We recently performed research that started off "well-intentioned" (or as well-intentioned as we ever

                                                                          We Spent $20 To Achieve RCE And Accidentally Became The Admins Of .MOBI
                                                                        • Cloud DataflowでGCS→BQのパイプラインをPythonで試してみる | DevelopersIO

                                                                          はじめに データアナリティクス事業本部のkobayashiです。 GoogleCloudのETLサービスのDataflowを調査する機会があり、Google Cloud Storage(以降GCS)にあるCSVファイルをBigQueryにロードする処理をPythonスクリプトで試してみましたのでまとめます。 Dataflow  |  Google Cloud Cloud Storage Text to BigQuery DataflowはマネージドなApache Beam Runnerでプログラミング言語としてはJava,Python,Goを使うことができます。今回やろうとしている「Cloud Storage Text to BigQuery」に関してはGoogle提供のバッチテンプレートがありますが、このテンプレートはJavaで記述されているため使用せずPythonで実装してみます。 B

                                                                            Cloud DataflowでGCS→BQのパイプラインをPythonで試してみる | DevelopersIO
                                                                          • Node.js

                                                                            Notable Changes crypto update root certificates (Richard Lau) #40280 deps upgrade npm to 8.0.0 (npm team) #40369 update nghttp2 to v1.45.1 (thunder-coding) #40206 update V8 to 9.4.146.19 (Michaël Zasso) #40285 tools update certdata.txt (Richard Lau) #40280 Commits [34f3021ca3] - benchmark: add util.toUSVString()'s benchmark (Khaidi Chu) #40203 [f83b9bcb6f] - build: support Python 3.10.0 (FrankQiu)

                                                                              Node.js
                                                                            • A 2025 Survey of Rust GUI Libraries

                                                                              I did this in 2020 and then again in 2021, but I’m in the mood to look around again. Let’s look through Are We GUI Yet? and see what’s up these days. The task today is to have a text label and an input field that can change the text in the label. In React, for example, this is basically free: const Demo = () => { let [state, setState] = useState("Hello, world!"); return ( <div> <p>{state}</p> <inp

                                                                              • What's New in Emacs 28.1?

                                                                                Try Mastering Emacs for free! Are you struggling with the basics? Have you mastered movement and editing yet? When you have read Mastering Emacs you will understand Emacs. It’s that time again: there’s a new major version of Emacs and, with it, a treasure trove of new features and changes. Notable features include the formal inclusion of native compilation, a technique that will greatly speed up y

                                                                                • Node.js — Node.js v22.10.0 (Current)

                                                                                  Or if the package is only meant to be run on Node.js and wants to fallback to CJS on older versions that don't have require(esm): { "type": "module", "exports": { // On new version of Node.js, both require() and import get the ESM version "module-sync": "./index.js", // On older version of Node.js, where "module-sync" and require(esm) are // not supported, use the CJS version to avoid dual-package

                                                                                    Node.js — Node.js v22.10.0 (Current)