Python has had awesome string formatters for many years but the documentation on them is far too theoretic and technical. With this site we try to show you the most common use-cases covered by the old and new style string formatting API with practical examples. All examples on this page work out of the box with with Python 2.7, 3.2, 3.3, 3.4, and 3.5 without requiring any additional libraries. Fur
Here is a short bash script that you may use to install NumPy on Maya’s internal Python binary. If you want to use NumPy functions in Maya, this would be useful. #!/usr/bin/env bash # Before installing separate Python packages for MayaPy, check whether MayaPy just can use # the system-wide packages in your `site-packages` directory. You can check it by # inserting the following command in the begi
about Antimony is a computer-aided design (CAD) tool from a parallel universe in which CAD software evolved from Lisp machines rather than drafting tables. demo foundations Antimony is built on three mostly-orthogonal axes: A framework for tracking information flow through directed acyclic graphs A geometry engine for doing CSG A standard library of shapes and transforms Graph engine Solid modelin
pandas でそこそこ大きいデータを扱う場合、その処理速度が気になってくる。公式ドキュメントではパフォーマンス向上のために Cython や Numba を使う方法を記載している。 Enhancing Performance — pandas 0.16.2 documentation が、軽く試したいだけなのに わざわざ Cythonや Numba を使うのは手間だし、かといってあまりに遅いのも嫌だ。そんなとき、pandas 本来のパフォーマンスをできるだけ維持するためのポイントを整理したい。 pandas に限らず、パフォーマンス改善の際にはボトルネックの箇所によってとるべき対策は異なる。pandas では速度向上/エッジケース処理のために データの型や条件によって内部で処理を細かく分けており、常にこうすれば速くなる! という方法を出すのは難しい。以下はこの前提のうえで、内部実装からみ
The other day I saw an awesome post about using pythons magic methods in order to improve API’s and make them more pythonic. After applying some of his suggestions to his current project I started thinking about ways to make python apis even more pythonic. The Problem My problem was that I had database models but the api for using them was not as clean as I would have liked. To illustrate this sit
I wrote this letter tonight to the NumPy mailing list --- a list I have been actively participating in for nearly 15 years. Hello all, There is a lot happening in my life right now and I am spread quite thin among the various projects that I take an interest in. In particular, I am thrilled to publicly announce on this list that Continuum Analytics has received DARPA funding (to the tune of at
Pythonの有名なWebスクレイピングフレームワークのScrapyがバージョン1.0になりました。*1 0.24からの主要な変更点は下記のとおりです。 SpiderでItemの代わりにdictを返せるようになった Spiderごとにsettingsを設定できるようになった Twistedのloggingの代わりにPythonのloggingを使うようになった CrawlerのコアAPIがリファクタリングされた いくつかのモジュール配置場所が変更された 他にも数多くの変更点がリリースノートに記載されています。 Scrapy 1.0の感想 大きな機能の追加よりも、APIの整理と安定性の向上がメインのようです。これまではバージョンを重ねるごとに便利になっていくものの、あまりAPIが安定していない印象でしたが、APIを安定させた区切りのリリースと言えるでしょう。1.0というメジャーバージョンに到
当サイトはPython2系入門篇の管理人が運営しています。 当サイトに掲載されているコンテンツ(文書やプログラム等)を利用したことにより発生したいかなる損失・損害につきまして当サイトは一切の責任と義務を負いません。 これらの利用は自己責任でお願いします。 お問い合わせはこちらのメールフォームからお願いします。
引き続き、 R の可視化を Python に持ってくるシリーズ。R には以下のようなパッケージがあり、地図上へのリーフレット配置やコロプレス図の描画がカンタンにできる。それぞれの概要はリンク先を。 {leaflet}: リーフレット配置 Leaflet for R - Introduction (英語) {choroplethr}: コロプレス図の描画 choroplethrで大阪市のコロプレス図を描く - Technically, technophobic. これを Python でやりたい。調べてみると folium というパッケージが上記 両方をサポートしているようなので使ってみる。 github.com インストール pip で。 pip install folium 準備 以降の操作は Jupyter Notebook から行う。まずはパッケージをロードする。 import nu
2015年10月12日のスプリントをもってPyCon JP 2015が無事終了しました。 2日間のカンファレンス来場者は昨年の545名から今年は602名まで増え、 昨年に引き続き過去最大の来場者数を更新し大変な盛り上がりとなりました。 ご参加いただいた皆様本当にありがとうございました。 発表資料、Blogもまとめてありますので、ぜひぜひ御覧ください!! こんにちは、プログラムチームの的場です。 PyConJP 2015では、パネルディスカッションを開催します。 ここでは、パネルディスカッションについて紹介いたします。 今回のパネルディスカッションのテーマは、「いま求められるコミュニティの多様性と未来」です。 パネルディスカッションのイベントページでも記載しているのですが、プログラミング界隈では、様々な種類のコミュニティ活動が広がっています。 個人的な印象を言うと、プログラミング界隈のコミュ
最近pythonを触り始めたのですが、散布図をアニメーションさせる方法が分からなかったので調べてみました。 散布図はmatplotlib.plt.scatter(x,y)で作成する事が出来ます。 また、アニメーションをさせる方法は二通りのやり方があるようです。 animation.ArtistAnimation 事前に用意してあるデータを描画 animation.FuncAnimation 随時データを更新する そこで円周上の点を一度ずつ移動させるというアニメーションをArtistAnimationとFuncAnimationの2つの方法で試してみました。 実行結果はどちらも次のようなものになります。 animation.ArtistAnimationの場合 事前にplt.scatterの戻り値をlistに保存しておき、animation.ArtistAnimationの第二引数に渡すと
リリース、障害情報などのサービスのお知らせ
最新の人気エントリーの配信
処理を実行中です
j次のブックマーク
k前のブックマーク
lあとで読む
eコメント一覧を開く
oページを開く