Deleted articles cannot be recovered. Draft of this article would be also deleted. Are you sure you want to delete this article?

26 Aug 2015 Building Python modules with Go 1.5 tl;dr: with Go 1.5 you can build .so objects and import them as Python modules, running Go code (instead of C) directly from Python. Here's the code. The Go 1.5 release brings a number of nifty changes. The one we will be playing with today is the ability of the standard toolchain to build libraries (.so, .a) exporting a C ABI. (This is just one of a
Note You can sign up to my mailing list so that you remain in sync with any major updates to this book or my future projects! Preface¶ Python is an amazing language with a strong and friendly community of programmers. However, there is a lack of documentation on what to learn after getting the basics of Python down your throat. Through this book I aim to solve this problem. I would give you bits o
Pythonへの型アノテーション導入を目指すGuido van Rossum氏 mypy の型アノテーションの構文を Python に取り込もうとメーリングリストで提案したニュースが話題になりました。今夏に話題になったニュースを今冬にフォローするという季節外れ感ですが、ずっと興味はあって「あとで読む」状態になっていたのを調べてみました。 基本的には mypy のドキュメントから自分の興味のあるところをかいつまんで説明しています。分かりにくいところがあれば原文を参照してください。 Welcome to Mypy documentation! mypy とは mypy は Python の静的型チェッカー (static type checker) です。wikipedia:静的コード解析 や wikipedia:en:Lint (software) ツールの一種だと説明されています。 Pyt
システムの構築、新しい技術の習得、PythonやDevOpsなどに情熱を注ぐソフトウェア開発者です。現在はチューリッヒを拠点とするビッグデータのスタートアップで働いており、データ分析およびデータ管理ソリューションのためのPythonの技術を磨いています。 1 はじめに Python は開発時間を短縮できるという点で一般的に評価の高い言語です。しかし、Pythonを使って効率よくデータ分析をするには、思わぬ落とし穴があります。動的かつオープンソースのシステムであるという特徴は、初めは開発を容易にしてくれますが、大規模システムの破綻の原因になり得ます。ライブラリが複雑で実行時間が遅く、データの完全性を考慮した設計になっていないので、開発時間の短縮どころか、すぐに時間を使い果たしてしまう可能性があるのです。 この記事ではPythonやビッグデータで作業をする時に、最も時間を無駄にしがちな事柄につ
Open Community CallWe want to see all the cool things you’re doing with Jupyter, so we’re holding an open call with the community for people to chat, and share their creations and work. Think of it as a “virtual JupyterCon”: It’s a place to announce and share fun things happening in the Jupyter community.
雑にですが,知ってるサイトやチュートリアルをまとめたくなったのでまとめてみました.夏ですし. 適宜更新しています. 最終更新 2018年02月03日 チュートリアル 言語処理100本ノック 言語処理100本ノック 2015 東工大の岡崎先生が作られたチュートリアルです. 他大学の研究室でも利用されています. 簡単な内容からはじまるので,プログラミングの導入としてもいいと思います. NLPプログラミングチュートリアル Graham Neubig's Teaching Carnegie Mellon UniversityのGraham Neubig先生のチュートリアルです. Githubにサンプルコードが公開されています. 各チュートリアルにはテストがついているので,実装が正しいかを確かめることができます. 扱っているトピックが広いので,かなり勉強になると思います. ソフト 形態素解析器 日本
Pythonのfunctoolsでターミナルに色付きテキスト出力する関数をお手軽作成する By raimon, 2015-08-07(金), in category Python ターミナルの色付きテキスト出力 ターミナルの画面上に色付きテキストを出力するには、ANSI エスケープシーケンス: 色とカーソル操作で解説されている通り、 表示されないエスケープシーケンスは、\[\033[ と \] で囲んでやる必要があります。色のエスケープシーケンスの場合は 後ろに m\] をつけてやる必要があります。 と、エスケープシーケンス + 目的のカラーコードでテキストを囲んでやると実現できる。 これをPythonで素朴にやろうとすると print 関数を使うことになるだろう。 Fabricでの色付きテキスト出力関数の実装 Pythonで作られたデプロイ・構成管理に広く使われるツールFabricには、
ディープラーニング(深層学習)というのが流行っているそうです。すべての人類はディープラーニングによって実現されたAIに隷属する未来なんですってよ!!! こわーい。 そんなバラ色の技術、いっちょかみしておきたいですよね。 さて、オフィスで社長とダベっていたところ、「将棋プログラム面白そうだよね」という話になりました。お互将棋プログラムを作って闘わせようぜ、いぇー、と盛り上がり、勢いでコンピュータ将棋選手権に申し込みまでしてしまいました。 そんな経緯で、ディープラーニングをミリしら(=1ミリも知らない)な僕が、試しにディープラーニングを使って将棋のAIを書いてみたらいいやん、と思いついたのでした。将棋も、ハム将棋でハム8枚落ちで負けるレベルくらい。ダメじゃん。 ミリしらなので、「チェスで何かやってるヤツがいるだろう」とアタリをつけてググった結果、Erik Bernhardssonさんによる d
概要 Python で 抽象構文木 (Abstract Syntax Tree) を扱うのに、その名の通り ast モジュール が標準ライブラリとして提供されています。 PEP で AST について言及しているのは PEP 339 - Design of the CPython Compiler のようです。Python 2.5 で ast モジュールが追加され、2.6 でヘルパー関数が提供されたようです。余談ですが、2.6 の What's New によると、 The ast module provides an Abstract Syntax Tree representation of Python code, and Armin Ronacher contributed a set of helper functions that perform a variety of comm
Learn to Build, Deploy and Operate Python Applications You're knee deep in learning Python programming. The syntax is starting to make sense. The first few ahh-ha! moments hit you as you learn to use conditional statements, for loops and classes while coding with the open source libraries that make Python such an amazing programming ecosystem. Now you want to take your initial Python knowledge and
Electron as GUI of Python Applications 21 Jun 2015 important notice Do NOT need to read this post. Please checkout the updated post for a better solution and a better explanation. what Electron (formerly Atom Shell) is a desktop node.js-powered “shell”. It is designed by Github and used to build Atom Editor. Python is a simple and powerful programming language. This post is a note about how to use
Flask でアプリケーションを作る際のメモ - Memo の 2015 年版 ディレクトリ構造 . ├── __init__.py ├── app.py ├── configs │ ├── __init__.py │ └── settings.py ├── errors.py ├── extensions │ ├── __init__.py │ ├── injector.py │ └── permission.py ├── forms ├── i18n ├── models │ ├── __init__.py │ ├── db.py │ ├── entities │ └── mappers ├── static │ ├── css │ ├── fonts │ ├── img │ └── js ├── templates │ ├── admin │ └── frontend ├── tes
This is a simple benchmark for python async frameworks. Almost all of the frameworks are ASGI-compatible (aiohttp and tornado are exceptions on the moment). The objective of the benchmark is not testing deployment (like uvicorn vs hypercorn and etc) or database (ORM, drivers) but instead test the frameworks itself. The benchmark checks request parsing (body, headers, formdata, queries), routing, r
追記: 使用しているDjangoのバージョンをはじめ、いくつか古くなってきている点があります。DjangoCongress JP 2018で認証に関する発表を行ったのですが、ブログ記事も用意しています。そちらを参照してください nwpct1.hatenablog.com 追記終わり Djangoでユーザ認証をしたかったので調べてみると,DjangoではUserモデルがはじめから用意されているらしい.そこでDjangoの提供する機能をそのまま使ってログイン・ログアウトを実装してみた. さらに調べてみるとpython-social-authというライブラリを使えば、TwitterやFacebook,Google、Github等のアカウントを使ったOAuth認証が簡単に実装できるみたいなのでそれも試しておく. ソースコードはGithubで公開してます. https://github.com/c-
Did you know that Flask has its origins in an April fools joke that unexpectedly took off? Listen in this week to hear about the history, current state, and future of Flask with its creator Armin Ronacher. You'll learn how he's using Python as the backend for a set of major computer games. His thoughts on the future of web development and HTTP 2. And why Rust is an amazing new language you should
Django1.8で増えた機能でSecurityMiddlewareというものがあります。 何ができるのか把握しておきたかったので調べていました。 django.middleware.security.SecurityMiddleware コードはこのあたり。 django/security.py at stable/1.8.x · django/django · GitHub 以下の内容は、Django1.8のドキュメントとコードを元に記述しています。 概要 SecurityMiddlewareは、Djangoアプリケーションへのリクエスト、レスポンスに対していくつかのセキュリティ強化を施します。 具体的には以下のような機能があります。 HTTP Strict Transport Security (HSTS) ヘッダの付与 X-Content-Type-Options: nosniff
By Eric Reynolds and Felix Zumstein, Partners at Zoomer Analytics (Jun 25, 2015) ▼ Comments Tweet TL;DR Often, virtualenv is overkill for the basic task of installing project dependencies and keeping them isolated. We present a simple alternative consisting of: adding ./.pip to your PYTHONPATH using pip install -t .pip to install modules locally executing python from your project’s root directory
Windows 用に Python のバイナリパッケージを作成するときに知っておいたほうがいい基礎知識や便利情報をまとめて書いていきます。 Windows でのバイナリパッケージの重要性について Windows 上で Python を使っているユーザーは、 Python の拡張モジュールをビルドする環境を持っている可能性はとても低いです。 もともと Mac に比べてコンパイラをインストールしているユーザーが少ない上に、 Mac 版では OS のバージョンごとにコンパイラが固定されるのに対して、 Windows では OS ではなく Python のバージョンによってコンパイラのバージョンが決まるという事情もあり、自分で調べて Python の開発環境を揃えている人以外が適切なコンパイラをセットアップしている可能性はゼロに近いです。 一方で Windows では python.org が提供
リリース、障害情報などのサービスのお知らせ
最新の人気エントリーの配信
処理を実行中です
j次のブックマーク
k前のブックマーク
lあとで読む
eコメント一覧を開く
oページを開く