Python Advent Calendar 2013 の14日目です。 今日は、テストコードを書くときに便利なモジュール factory_boy を紹介します。 なお、この記事のサンプルコードは以下の環境で動作確認しています。 Python 3.3.3(2.7でも動くように書いています)factory_boy 2.2.1SQLAlchemy 0.8.4SQLite3インストール#インストールは、pipコマンド一発でできます: pip install factory-boy 今回はSQLAlchemyも使うので、以下のコマンドでインストールしておきましょう: pip install sqlalchemy 基本的な使い方#以下のコードをjojo.py という名前で保存してください: import factory from factory.alchemy import SQLAlchemyMo
Please take a few minutes to complete the Django Developers Survey 2023. Your feedback will help guide future efforts. 設計思想¶ このドキュメントでは、 Django の開発者たちがフレームワークの構築に取り入れ ている根本的な設計思想についていくつか解説します。それによって、 Django の これまでの経緯に説明を与えつつ、将来への指針にしたいと思います。 疎結合¶ Django スタックの基本的な目標は、疎結合と高い凝集度 を実現することです。フレームワークの各レイヤーは絶対に必要でない限り、相手をお互いに「知る」べきではありません。 For example, the template system knows nothing about web requests,
Source code: Lib/enum.py An enumeration: is a set of symbolic names (members) bound to unique values can be iterated over to return its canonical (i.e. non-alias) members in definition order uses call syntax to return members by value uses index syntax to return members by name Enumerations are created either by using class syntax, or by using function-call syntax: >>> from enum import Enum >>> #
Product Plan out projects with the new Dropbox Paper timelines feature By Philip Rose Published on October 25, 2018 Coordinating projects is hard work. Not only does everyone need to be clear on overall goals, but people also need tasks assigned and project status kept up to date. And if you can’t handle these basics, it’s easy for projects to go off the rails. That pain—the pain of coordinating a
Puppeteer is a Node library which provides a high-level API to control headless Chrome or Chromium over the DevTools Protocol. It can also be configured to use full (non-headless) Chrome or Chromium. The Chrome DevTools team maintains the library, but we'd love your help and expertise on the project. See Contributing. What can I do? Most actions you can take manually in the browser can be done wit
Chainer(チェイナー)は、ニューラルネットワークの計算および学習を行うためのオープンソースのソフトウェアライブラリである。バックプロパゲーション(誤差逆伝播法)に必要なデータ構造をプログラムの実行時に動的に生成する特徴があり[4]、複雑なニューラルネットワークの構築を必要とするディープラーニング(深層学習)で用いられる[3][1]。Python 2.x系および3.x系から利用でき[要出典]、GPUによる演算をサポートしている[3][5]。株式会社Preferred Networks(PFN)からリリースされている[5][1]。2019年12月5日、開発元のPFNはフレームワーク開発を終了してChainerはメンテナンスフェーズへ移行すること、自社はChainerからFacebookが主導するPyTorchに順次移行することを発表した[1]。 Chainerは"define-by-ru
Released Chainer/CuPy v5.0.0 By Seiya Tokui Oct 25, 2018 In Announcement We have released Chainer and CuPy v5.0.0 today! This is a major release that introduces several new features. The following is a list of selected updates. Full updates can be found in the release notes: Chainer, CuPy. Static subgraph optimization (experimental). By applying the @static_graph decorator to the static part of yo
大手IT企業のアマゾン・ドット・コムとグーグルを傘下に置く持ち株会社は、先月までの3か月間の決算を発表し、好調な広告事業やクラウドサービス事業に支えられて、ともに大幅な増収、増益となりました。 これは主力のネット通販のほか、インターネット経由でデータの保存などを行うクラウドサービスの事業が好調だったためです。 一方、グーグルを傘下に置く持ち株会社のアルファベットの先月までの3か月間の決算は、売り上げが前の年の同じ時期に比べて21%増えて、337億4000万ドル(およそ3兆7000億円)でした。 また最終的な利益は91億9200万ドル(1兆円余り)となり、36%増えました。 主力の広告事業が好調だったほか、こちらもクラウドサービスの事業の伸びに支えられました。注目の大手IT企業の決算は、来週、フェイスブックやアップルの発表が相次ぎます。
リリース、障害情報などのサービスのお知らせ
最新の人気エントリーの配信
j次のブックマーク
k前のブックマーク
lあとで読む
eコメント一覧を開く
oページを開く