學習貴在使用方法,能夠獨立解決問題◎
所以遲遲不提
【派生火焰生態系】
The Blaze ecosystem is a set of libraries that help users store, describe, query and process data. It is composed of the following core projects:
- Blaze: An interface to query data on different storage systems
- Dask: Parallel computing through task scheduling and blocked algorithms
- Datashape: A data description language
- DyND: A C++ library for dynamic, multidimensional arrays
- Libndtypes: A C/C++ library for a low-level version of Datashape
- Ndtypes-python: Python bindings for libndtypes
- Odo: Data migration between different storage systems
【概觀】
Overview
Blaze Abstracts Computation and Storage
Several projects provide rich and performant data analytics. Competition between these projects gives rise to a vibrant and dynamic ecosystem. Blaze augments this ecosystem with a uniform and adaptable interface. Blaze orchestrates computation and data access among these external projects. It provides a consistent backdrop to build standard interfaces usable by the current Python community.
【安裝】
pi@raspberrypi:~ ipython3 Python 3.5.3 (default, Jan 19 2017, 14:11:04) Type "copyright", "credits" or "license" for more information. IPython 5.1.0 -- An enhanced Interactive Python. ? -> Introduction and overview of IPython's features. %quickref -> Quick reference. help -> Python's own help system. object? -> Details about 'object', use 'object??' for extra details. In [1]: from blaze import * /usr/local/lib/python3.5/dist-packages/blaze/server/server.py:17: ExtDeprecationWarning: Importing flask.ext.cors is deprecated, use flask_cors instead. from flask.ext.cors import cross_origin In [2]: 帳戶 = Symbol('帳戶', 'var * {"編號": int, "開戶人": string, "金額": int ...: }') In [3]: 壞帳 = 帳戶[帳戶.金額 < 0].開戶人 In [4]: L = [[1, 'Alice', 100], ...: [2, 'Bob', -200], ...: [3, 'Charlie', 300], ...: [4, 'Denis', 400], ...: [5, 'Edith', -500]] In [5]: list(compute(壞帳,L)) Out[5]: ['Bob', 'Edith'] In [6]:
─ 改自《【鼎革‧革鼎】︰ RASPBIAN STRETCH 《三‧戊》》
因有新舊版本『相容性』問題也︰
List to Postgres fails with “AttributeError: ‘DiGraph object has no attribute ‘edge'” #588
You need to downgrade your networkx to <2.0 until this is fixed |
※ 註︰
Install
NetworkX requires Python 2.7, 3.4, 3.5, or 3.6. If you do not already have a Python environment configured on your computer, please see the instructions for installing the full scientific Python stack.
Note
If you are on Windows and want to install optional packages (e.g., scipy
), then you will need to install a Python distribution such as Anaconda, Enthought Canopy, Python(x,y), WinPython, orPyzo. If you use one of these Python distribution, please refer to their online documentation.
Below we assume you have the default Python environment already configured on your computer and you intend to install networkx
inside of it. If you want to create and work with Python virtual environments, please follow instructions on venv and virtual environments.
First, make sure you have the latest version of pip
(the Python package manager) installed. If you do not, refer to the Pip documentation and install pip
first.
Install the released version
Install the current release of networkx
with pip
:
sudo pip3 install networkx==1.11
蓋不知『降級』者,恐無法
Quickstart
This quickstart is here to show some simple ways to get started created and manipulating Blaze Symbols. To run these examples, import blaze as follows.
>>> from blaze import *
Blaze Interactive Data
Create simple Blaze expressions from nested lists/tuples. Blaze will deduce the dimensionality and data type to use.
>>> t = data([(1, 'Alice', 100), ... (2, 'Bob', -200), ... (3, 'Charlie', 300), ... (4, 'Denis', 400), ... (5, 'Edith', -500)], ... fields=['id', 'name', 'balance']) >>> t.peek() id name balance 0 1 Alice 100 1 2 Bob -200 2 3 Charlie 300 3 4 Denis 400 4 5 Edith -500
哩!眼下假借
/blaze-tutorial
forked from mrocklin/blaze-tutorial
Blaze Tutorial
This repository contains notebooks and data for a tutorial for Blaze a library to compute on foreign data from within Python.
This is a work in progress.
Outline
- Motivation – (nbviewer)
Into
We present most Blaze fundamentals while discussing the simpler topic of data migration using the into
project.
Blaze Queries
探索影響範圍?
有興趣的讀者何不自己嘗試呦☆
dhirschfeld commented Jun 6, 2018