【鼎革‧革鼎】︰ Raspbian Stretch 《三‧辛》

甲骨文止

《説文解字》:止,下基也。象艸木出有址,故以止爲足。凡止之屬皆从止。

大學》講︰知止而後有定,定而後能靜,靜而後能安,安而後能慮,慮而後能得。

一件事如果沒有它發生之理,那它能夠發生的嗎?假使那事果然都不發生,又如何能夠得到那個發生之理?這就是『事、理不二』的道理,發生之事蘊有發生之理,發生之理緣起發生之事。那『空山樹倒』是否是發生了一件事呢?假使有人砍了你的『櫻桃樹』又是不是發生了一件事的呢??

易繫辭》說:艮,東北之卦也,萬物之所成終而所成始也,故曰成言乎艮。又說:終萬物始萬物者莫盛乎艮 。

艮:艮其背,不獲其身,行其庭,不見其人,無咎。

彖曰艮,止也。 時止則止時行則行動靜不失其時其道光明。 艮其止,止其所也。 上下敵應,不相與也。 是以不獲其身 ,行其庭不見其人,無咎也。

象曰:兼山,艮﹔君子以思不出其位

初六:艮其趾,無咎,利永貞。
象曰:艮其趾,未失正也。

六二:艮其腓,不拯其隨,其心不快。
象曰:不拯其隨,未退聽也。

九三艮其限,列其夤,厲薰心。
象曰:艮其限,危薰心也。

六四:艮其身,無咎。
象曰:艮其身,止諸躬也。

六五:艮其輔,言有序,悔亡。
象曰:艮其輔,以中正也。

上九:敦艮,吉。
象曰敦艮之吉,以厚終也

論語《里仁》子曰:『參乎!吾道一以貫之。』曾子曰:『唯。』子出。門人問曰:『何謂也?』曾子曰:『夫子之道,忠恕而已矣。

以及

老子第三十九章中講︰

得一者得一以得一以得一以得一以萬物得一以侯王得一以為天下貞其致之天無恐裂地無恐發神無恐歇谷無恐竭萬物無恐滅侯王無貞高恐蹶。故貴以賤為本高以下為基。是以侯王自謂孤寡不穀,此非以賤為本耶?非乎?人之所惡 ,唯孤寡不穀,而侯王以為稱。故致譽無譽不欲琭琭如玉,珞珞如石

正是《》於《》之『學問』大道。希望人們知道所謂『道德』之名,實在說的是『得到』── 得道── 的啊!!

如果說『氣候』持續變遷,有朝一日,假使乾坤都『無路』可走,人又該往向『何方』的呢??

─── 《○ 《止》何處!?

 

放眼天下誰爭第二!

Mozilla IoT

Things Gateway by Mozilla

Illustration showing a Raspberry PiBuild your own Web of Things gateway

Download

 

AWS IoT Device SDK for Python

The AWS IoT Device SDK for Python allows developers to write Python script to use their devices to access the AWS IoT platform through MQTT or MQTT over the WebSocket protocol. By connecting their devices to AWS IoT, users can securely work with the message broker, rules, and the device shadow (sometimes referred to as a thing shadow) provided by AWS IoT and with other AWS services like AWS Lambda, Amazon Kinesis, Amazon S3, and more.


Overview

This document provides instructions for installing and configuring the AWS IoT Device SDK for Python. It includes examples demonstrating the use of the SDK APIs.

MQTT Connections

The SDK is built on top of a modified Paho MQTT Python client library. Developers can choose from two types of connections to connect to AWS IoT:

  • MQTT (over TLS 1.2) with X.509 certificate-based mutual authentication.
  • MQTT over the WebSocket protocol with AWS Signature Version 4 authentication.

For MQTT over TLS (port 8883), a valid certificate and a private key are required for authentication. For MQTT over the WebSocket protocol (port 443), a valid AWS Identity and Access Management (IAM) access key ID and secret access key pair are required for authentication.

Device Shadow

A device shadow, or thing shadow, is a JSON document that is used to store and retrieve current state information for a thing (device, app, and so on). A shadow can be created and maintained for each thing or device so that its state can be get and set regardless of whether the thing or device is connected to the Internet. The SDK implements the protocol for applications to retrieve, update, and delete shadow documents. The SDK allows operations on shadow documents of single or multiple shadow instances in one MQTT connection. The SDK also allows the use of the same connection for shadow operations and non-shadow, simple MQTT operations.

 

曾經領先果真甘退幕後?

Connect a Raspberry Pi to IBM Watson IoT Platform

Use a Raspberry Pi to connect to IBM Watson IoT Platform. Then you can visualize the data generated by the Raspberry Pi

 

世間事,隨或且易??

<Logo>

 

The Eclipse Paho project provides open-source client implementations of MQTT and MQTT-SN messaging protocols aimed at new, existing, and emerging applications for the Internet of Things (IoT).

 

Mosquitto

An Open Source MQTT v3.1/v3.1.1 Broker

Eclipse Mosquitto™ is an open source (EPL/EDL licensed) message broker that implements the MQTT protocol versions 3.1 and 3.1.1. MQTT provides a lightweight method of carrying out messaging using a publish/subscribe model. This makes it suitable for “Internet of Things” messaging such as with low power sensors or mobile devices such as phones, embedded computers or microcontrollers like the Arduino.

Mosquitto is an iot.eclipse.org project

 

止之道,恐難定靜矣!!

 

 

 

 

 

 

 

 

【鼎革‧革鼎】︰ Raspbian Stretch 《三‧庚》

如果問聰明物件往何處尋找?上窮碧落出於九天,下黃泉入於九地 ,這麼『九天九地』的追求!善也!非善之善者也?!為什麼呢? ?因著『九』『六』之辨。想那《易經》唯獨『乾』『坤』兩卦有用『九』用『六』之文。有人講︰陽『極』曰『九』,陰『極』曰『六』。天地數『極』,恐將不在,故誡之以︰

用九:見群龍無首,吉。

用六:利永貞。

誰知《孫子兵法》中的『九』『六』之數︰

軍形』講『九天九地』,『地形』篇說『六』,『九地』篇談用『兵』。

,竟惹出了『武功』裡的『九』『六』之辯︰

九陽神功、九陰真經、六陰真經、六脈神劍 ………

,到底哪一個是絕世武功的耶??!!

此一番分解是因當今萬教所宣稱的『 IOT 』眾多,幾乎各個都言明『 SMART 』。作者不想陷入︰

這不是『肯德雞』。

的迷思,因此寫在前頭表白清楚,凡有所選,不過『之一』而已,絕非『唯一』,也無法稱霸武林。

於是作者順著 Mrphs 給的『麵包屑』

漢賽爾與葛麗特是 一個貧窮伐木工人的小孩。由於害怕食物不足,木工的妻子,也就是小孩們的繼母,說服木工將小孩帶到森林,並將他們遺棄。漢賽爾與葛麗特聽 到了他們的計畫,於是他們事先集了小石頭,這樣他們就能沿小石頭找到回家的路。在他們回來後,他們的繼母再度說服木工將他們丟在森林;不過這次,他們沿路 布置的是麵包屑。不幸的是,麵包屑被森林中的動物吃掉了,於是漢賽爾與葛麗特在森林中迷路了。……

─── 引自《春雷早發︰樹莓派 2 Model B ︰ jessie !!

,希望能夠抵達『糖果屋』。在『 Lego Mindstorms EV3 』詞條上

……

,最後發現了

GrovePi

!!?? W!o+ 的《小伶鼬工坊演義》︰ 九天九地

 

看過《小伶鼬工坊演義》全集者,自然知道作者曾經細說 GrovePi 之硬、韌、軟諸體,企欲讀者盡其用也。

雖然現在

GrovePi︰ ATMEGA328 + C

仍執牛耳︰

宋‧蘇軾《題西林壁》

橫看成嶺側成峰,
遠近高低各不同。
不識廬山真面目,
只緣身在此山中。

曾 聽 Mrphs 說︰ W!o+ 的工坊內各種物件星羅棋布,那裡頭最大的一塊區域擺著各類『感測器』。少年的他在觀察自然生物後,認為所謂『智慧組件』如果師法自然,首重『自主感測器』 的深入理解 。因為這是『生命』感知天地自我的第一步。並且那個『自主性』就是『智慧』藏身之處,賦予一個『組件』之聰明。若是將之適當組合就形成『聰明物件』。

雖然這也是作者選擇『 GrovePi 』的重要原因,

Port Description

The GrovePi is stacked on top of the Raspberry Pi without the need for any other connections.  Communication between the two occurs over the I2C interface. All Grove modules connect to the universal Grove connectors on the GrovePi shield via the universal 4 pin connector cable.

Grove modules, which work on analog and digital signals, connect directly to the ATMEGA328 microcontroller on the Grove Pi.  The microcontroller acts as an interpreter between the Raspberry Pi and the Grove sensors.  It sends, receives, and executes commands sent by the RaspberryPi.

In addition, the GrovePi allows you the Raspberry Pi to access some Grove sensors directly.  The Raspberry Pi has an I2C Bus and a Serial bus.  These buses can directly connect to sensors via the I2C Ports and the USART Port.

GrovePi Port description

GlovePi+

…… 摘自《W!o+ 的《小伶鼬工坊演義》︰ 經緯縱橫

 

焉知來者

pyboard: ESP8266 + Python

不如今者耶?

MicroPython

MicroPython is a lean and efficient implementation of the Python 3 programming language that includes a small subset of the Python standard library and is optimised to run on microcontrollers and in constrained environments.

The MicroPython pyboard is a compact electronic circuit board that runs MicroPython on the bare metal, giving you a low-level Python operating system that can be used to control all kinds of electronic projects.

MicroPython is packed full of advanced features such as an interactive prompt, arbitrary precision integers, closures, list comprehension, generators, exception handling and more. Yet it is compact enough to fit and run within just 256k of code space and 16k of RAM.

MicroPython aims to be as compatible with normal Python as possible to allow you to transfer code with ease from the desktop to a microcontroller or embedded system.

Quick reference for the pyboard

 

何況早有繼起者發展推廣之乎!

January 9, 2017 AT 5:04 pm

Welcome to the Adafruit CircuitPython Beta!

CircuitPython

Today we’ve released the first beta version of CircuitPython! CircuitPython is based on the open-sourceMicroPython which brings the popular Python language to microcontrollers. The goal of CircuitPython is to make hardware as simple and easy as possible. CircuitPython adds support for the SAMD21 processor found on the Arduino Zero and Feather M0s. Furthermore, many APIs including the hardware APIs have been reworked for the  SAMD21 and ESP8266. This rework ensures that APIs are consistent across processors and makes it easier to keep documentation up to date with implementation.  Lastly, the APIs common with CPython on desktop are strictly a subset which means code written for CircuitPython will work with CPython.

This beta is the precursor to a 1.0 version which will ship on upcominghardware designed for CircuitPython. A few things may change but the vast majority of the APIs are fixed. We’re focussed on creating awesome libraries and drivers on top of this new foundation to help verify the API design. Any help writing drivers, finding and fixing bugs is appreciated! Please file issues on GitHub and chat with us on Gitter.

To run the beta you need a Feather Huzzah, Arduino Zero or Feather M0. The bin files are available here. Instructions on loading MicroPython and CircuitPython are the same and are available here as a learning guide.

You can also support MicroPython and the creator, Damien George by purchasing official PyBoards at Adafruit as well as MicroPython stickers. Adafruit will soon be shipping CircuitPython boards, stay tuned to our weekly shows for more information and previews!

 

 

 

 

 

 

 

【鼎革‧革鼎】︰ Raspbian Stretch 《三‧己》

篆文隨

《説文解字》:随,从也。从辵, 無土之隨 省聲。

土之聚為丘,丘之大成山,果可因『聚大』就『』的嘛!

此『』── 山頭主義 ── 易經有『』,但看『該不該』『』的吧??

易經》第十七卦‧澤雷隨

隨:元亨利貞,無咎。

彖曰:隨,剛來而下柔,動而說,隨。大亨貞,無咎,而天下隨時,隨之時義大矣哉!

象曰:澤中有雷,隨﹔君子以嚮晦入宴息。

初九:官有渝,貞吉。 出門交有功。
象曰:官有渝,從正吉也。 出門交有功,不失也。

六二:系小子,失丈夫。
象曰:系小子,弗兼與也。

六三:系丈夫,失小子。 隨有求得,利居貞。
象曰:系丈夫,志舍下也。

九四隨有獲,貞凶。有孚在道,以明,何咎。
象曰隨有獲,其義凶也。 有孚在道,明功也。

九五:孚于嘉,吉。
象曰:孚于嘉,吉﹔位正中也。

上六:拘系之,乃從維之。 王用亨于西山。
象曰:拘系之,上窮也。

,或許已落於『無可奈何』,方不得不說『』之情事罷了!!

『東方』曾如是說,『西方』後有研究︰

200px-Milgram_Experiment_v2

實 驗者【E】命令『老師』【T】對『學生』【L】施予『電擊』 ,那位扮演『老師』的參與者被告知這樣做真的會使『學生』遭受痛苦的電擊,但實際上這個『學生』是此實驗之一名助手所扮演的。參與者『相信』『學生』每次 回答錯誤都真的會遭受電擊,雖然並沒有真的實施。當與參與者進行隔離以後,這個助手會設置一套『錄音機』,這套『錄音機』正由『老師』的『電擊產生器』所 控制,正確依據『電擊強度』播出不同的『預製錄音』。

250px-Milgram_Experiment_advertising

米爾格倫實驗廣告傳單

根據維基百科︰

米爾格倫實驗』 Milgram experiment ,又稱『權力服從研究』 Obedience to Authority Study 是一個針對社會心理學非常知名的科學實驗。實驗的概念最先開始於 1963 年由耶魯大學心理學家斯坦利‧米爾格倫在 《變態心理學雜誌》 Journal of Abnormal and Social Psychology 裡所發表的 Behavioral Study of Obedience 一文,稍後也在他於 1974 年出版的 Obedience to Authority: An Experimental View 裡所討論。這個實驗的目的,是為了測試受測者,在面對權威者下達違背良心的命令時,人性所能發揮的拒絕力量到底有多少。

實驗開始於 1961 年 7 月,也就是納粹黨徒阿道夫‧艾希曼被抓回耶路撒冷審判並被判處死刑後的一年。米爾格倫設計了這個實驗,便是為了測試『艾希曼以及其他千百萬名參與了猶太人大屠殺的納粹追隨者,有沒有可能只是單純的服從了上級的命令呢?我們能稱呼他們為大屠殺的兇手嗎?

一九七四年米爾格倫在《服從的危險》裡寫道:

在 法律和哲學上有關服從的觀點是意義非常重大的,但他們很少談及人們在遇到實際情況時會採取怎樣的行動。我在耶魯大學設計了這個實驗,便是為了測試一個普通 的市民,只因一位輔助實驗的科學家所下達的命令,而會願意在另一個人身上加諸多少的痛苦。當主導實驗的權威者命令參與者傷害另一個人,更加上參與者所聽到 的痛苦尖叫聲,即使參與者受到如此強烈的道德不安 ,多數情況下權威者仍然得以繼續命令他。實驗顯示了成年人對於權力者有多麼大的服從意願,去做出幾乎任何 尺度的行為,而我們必須儘快對這種現象進行研究和解釋。

引出了『令人震驚』之『整合分析』 meta-analysis 『結論』︰

Thomas Blass ──《電醒全世界的人》的作者 ── of the University of Maryland, Baltimore County performed a meta-analysis on the results of repeated performances of the experiment. He found that the percentage of participants who are prepared to inflict fatal voltages remains remarkably constant, 61–66 percent, regardless of time or country.

The participants who refused to administer the final shocks neither insisted that the experiment itself be terminated, nor left the room to check the health of the victim without requesting permission to leave, as per Milgram’s notes and recollections, when fellow psychologist Philip Zimbardo asked him about that point.

假使再添上『阿希從眾實驗』的『從眾效應』所說

實驗結果︰受試者中有百分之三十七之回答是依據了『大多數』的『錯誤回答』,大概有四分之三的人至少有過一次『從眾行為』,只有大約四分之一的人維持了『獨立自主』性。

獨立自主』之不易正如《易經‧乾卦》所講︰

初九曰潛龍勿用。何謂也?
子曰龍德而隱者也不易乎世,不成乎名﹔遯世而無悶,不見是而無悶﹔樂則行之,憂則違之﹔確乎其不可拔,潛龍也。

尊重事實』,有著『實驗查證』的『科學精神』,從古今歷史來看,實在並不容易!『待人處事』能夠『進取』『有所不為』,不落『鄉愿』『德之戝也』窠臼,誠屬難能可貴!!

─── 《《隨》□ 起舞?!

 

久未關心 webiopi 計畫,原來已有官網,且開展新專案了呦︰

Jumpstart Raspberry Pi Projects with Cayenne

Accelerate development with the world’s first drag-and-drop project builder

  • Add and remotely control sensors, motors, actuators, GPIO boards, and more
  • Customizable dashboards with drag-and-drop widgets for connection devices
  • Create triggers and threshold alerts for devices, events, and actions
  • Schedule one-time or multi-device events for easy automation
  • Quick and easy setup – connect your Pi in minutes

 

看來這物聯網漸成氣候,已是大勢所趨矣!

談起目前東西方競逐所為,恐生平台工具、應用實務、生產製造 … 之大哉辨乎?此所謂本末功夫也!!

一時 Mrphs 說道︰雖然先生曾在

《派生》 Python 作坊【甲】尋本溯源》文本中,談到『 甲骨文作一』『作』字。

甲骨文作一

甲骨文作二

甲骨文作三

△★ 坊

《説文解字》:,起也。从人,从乍。

本義:木匠用刀具砍斫削刻,制作器物。

《説文解字》:,邑里之名。从土,方聲 。古通用埅。

原意:邊塞的防護墙。

───

但是 W!o+ 非常心儀『 工 』『工』字。他講這個『工』字古來就代表多功能『工具』,因此後有『工欲善其事,必先利其器』之說 ,所以特取名為『工坊』。彼時作者當真墬落『工』『作』和『作』『工』之輪迴裡。縱想問,卻不知問之『目的』安在?……只聽 Mrphs 又講︰W!o+ 認為

懷疑是種子,經驗雖除惑,催生新懷疑。

所以理知之方法學,應當要效法『龍捲風』

從下而上‧由上往下,積聚力量。

故而『工坊』內的網絡佈置都採用『明線』,因應著學習心得常會有變遷………

此時回顧,果然

假使一個人果能站在前人學問的基石上,又天真好奇孜孜不倦,那就會如孔子在《論語‧子罕》:

後生可畏焉知來者之不如今也。 四十、五十而無 ── ㄨㄣˊ陽關道 ──焉,斯亦不足畏也已。

,裡所說的一樣。甚至要能如下面所引的『一則故事』那樣

歐陽修, 一向治學嚴謹,直至晚年,不減當初。他常將自己平生所寫的文章,清理出來進行修改,每字每句反覆推敲,甚是認真。為此,他整天辛苦勞累,有時直忙 到深夜。夫人見他年歲已高,還如此盡心費神,恐其操勞過度,影響健康,十分擔心,目前制止。她關切地對丈夫說:『官人,何必如此用功,不惜貴體安康,為這 些文字吃這樣多的苦頭,官人已年邁致仕(退休),難道還怕先生責難生氣嗎?』歐陽修回答說:『不怕先生生氣,只怕後生生譏』,『後生可畏耶!』

活到老學到老

─ 引自《後生可畏!?

── 摘自《W!o+ 的《小伶鼬工坊演義》︰ 從下而上‧由上往下

 

故而反倒樂見有人廣其志︰

Yet Another WebIoPi+

a forked WebIOPi, the original one is written by Eric PTAK (trouch). Please refer to http://webiopi.trouch.com/ for the original one.

Differences

Please refer to the following pages for more details.

 

喜聞殊途可同歸哩◎

PHPoC

New era – Internet of Things (IoT) has come up. There are a lot of the smart things have been created such as Nest Learning Thermostat, Philips Hue-Smart Home Lighting, Apple Watch and HomeKit, Google Glass, The Air Quality Egg, Amazon Echo, etc. PHPoC helps you to quickly realize your idea, rapidly make your application prototyping. PHPoC lets you develop your application on embedded devices as easily as on your computer. With supported library, you can do something as big as you can imagine by some simple lines of codes without worrying about designing hardware.

PHPoC vs PHP

Similar to PHP, PHPoC (PHP on Chip) can create a variety of web pages to suit your environment and perform other network functions such as sending email or accessing the database. Unlike PHP, however, PHPoC has some additional features that an embedded system needs in order to interact with hardware. It provides a variety of hardware interfaces and functions to monitor sensor status and control machines or devices.

 

 

 

 

 

 

 

 

【鼎革‧革鼎】︰ Raspbian Stretch 《三‧戊》

壬一

壬二

壬三

《説文解字》:壬,位北方也。陰極陽生 ,故《易》曰:“龍戰于野。”戰者,接也 。象人褢妊之形。承亥壬以子,生之敘也 。與巫同意。壬承辛,象人脛。脛,任體也。凡壬之屬皆从壬。

本義:善於使用巧具,勝任事務。

論語》‧泰伯第八

曾子曰:士不可以不弘毅任重道遠,仁以為己任,不亦重乎!死而後已,不亦遠乎!

曾子曰:以能問於不能,以多問於寡;有若無,實若虛,犯而不校;昔者吾友【顏淵】,嘗從事於斯矣。

……

BigData_2267x1146_trasparent

Viegas-UserActivityonWikipedia

IBM 對維基百科編輯紀錄資料進行視覺化的呈現。維基百科上總計數兆位元組的文字和圖片正是大資料的例子之一

Hilbert_InfoGrowth

全球資訊儲存容量成長圖

Big_data_cartoon_t_gregorius

Cartoon critical of big data application, by T. Gregorius

根據維基百科詞條,現今『大數據』的
定義】是

大數據由巨型資料集組成,這些資料集大小常超出人類在可接受時間下的收集、庋用、管理和處理能力。大數據的大小經常改變 ,截至 2012 年,單一資料集的大小從數兆位元組(TB)至數十兆億位元組(PB)不等。

在一份 2001 年的研究與相關的演講中,麥塔集團 ( META Group,現為高德納)分析員道格‧萊尼(Doug Laney)指出資料增長的挑戰機遇三個方向(Volume,資料大小)、(Velocity,資料輸入輸出的速度)與多變(Variety,多樣性),合稱「 3V 」或「 3Vs 」。高德納與現在大部份大數據產業中的公司,都繼續使用 3V  來描述大數據。高德納於 2012 年修改了對大數據的定義:「大數據是大量、高速、及/或多變的資訊資產,它需要新型的處理方式去促成更強的決策能力、洞察力與最佳化處理。」另外,有機構在 3V 之外定義了第 4 個 V:真實性(Veracity)為第四特點。

大數據必須藉由計算機對資料進行統計、比對、解析方能得出客觀結果。美國在 2012 年就開始著手大數據,歐巴馬更在同年投入 2 億美金在大數據的開發中,更強調大數據會是之後的未來石油

資料探勘(data mining)則是在探討用以解析大數據的方法。

應用範例

大資料的應用範例包括大科學、RFID、感測裝置網路、天文學、大氣學、基因組學、生物學、大社會資料分析、網際網 路檔案處理、製作網際網路搜尋引擎索引、通訊記錄明細、軍事偵查、社群網路 、通勤時間預測、醫療記錄、相片圖像和影像封存、大規模的電子商務等。

人性關切

大 數據時代的來臨帶來無數的機遇,但是與此同時個人機構隱私權也極有可能受到衝擊,大數據包含了各種個人資訊資料,現有的隱私保護法律或政策無力解決這 些新出現的問題。有人提出,大數據時代,個人是否擁有「被遺忘權」,被遺忘權即是否有權利要求資料商不保留自己的某些資訊,大數據時代資訊為某些網際網路巨頭所控制,但是資料商收集任何資料未必都獲得用戶的許可,其對資料的控制權不具有合法性。 2014 年 5 月 13 日歐盟法院就「被遺忘權」(right to be forgotten)一案作出裁定,判決 Google應根據用戶請求刪除不完整的、無關緊要的、不相關的資料以保證資料不出現在搜尋結果中。這說明在大數 據時代,加強用戶個人權利尊重才是時勢所趨的潮流。

無 論人們喜歡與否,我們已經活在了『大數據』的『礦坑』之中,我們本身就是『資訊礦石』。舉例來說,許多便利商店裝設著資訊收集、分析、儲存……的『攝像鏡 頭』,用著『影像辨識』的科技追蹤『消費者』之『視線』,分析『消費者』的性別、年齡、喜好 ……等等數據,可用於廣告、促銷、商品管理……種種用途,企圖達到『別家』或『門可羅雀』,此處卻『人滿為患』的成效。那麼這是『合理』的嗎?應該『同 意』的嗎??想像未來當你進入一個『賣場』,你的『手機』就已經告訴你今天有哪些你『喜歡』的『食品』正在『特價』,挑動著你的『感性欲望』;或許由於其 它非食品業 APP 軟體廠商的大力『宣傳』,你的『手機』上也有那種分析『食品』對『身體健康』影響的 APP,它正提醒你的『理性』再吃就『超標』了……這難道不是…資訊轟炸……更像是……擺脫不掉 ,自己找來的麻煩!!

也許那還是自己可以選擇之『好』的一面。因為不是所有人利用『大數據』來『淘金』,都具有『專業訓練』以及『道德良心』。因此常有『□□ 研究』的『數據』『證實』吃『○○食品』能降低『☆☆指數』如何?如之何的『廣告』??一 旦發生了『事故』,大概全成了那是『個案』以及『例外』的了。就像『風起雲湧』,天未必會下雨,『艷陽高照』,未必天就不下雨。比方說『徵候』是講時間 『先行』的『現象』,與伴隨該『現象』之後『而來』的『現象』,『現象』之間可能會有『統計相關性』,但不一定具有什麼『因果關係』。或許可以讀一讀 《知未知‧既未濟》所言︰

………

大數據』的確是『任重』而『道遠』,就讓我們介紹那熊熊烈火『派生火焰』 Python blaze 的吧!照亮『大數據』『科學』之道路 !! ─── 《《派生》 Python 作坊【壬】任重道遠

 

人拿刀殺人,罪在刀乎?有製殺人之刀者,有人用以殺人,製刀者果無罪耶 ??工具論者 ── 器物與應用無干 ── 有辯也。依其論 ,隻手亦可殺人,練武動機可疑矣!那麼

荀子‧王制篇

馬駭輿,則君子不安輿;庶人駭政,則君子不安位。馬駭輿,則莫若靜之;庶人駭政,則莫若惠之。選賢良,舉篤敬,興孝弟,收孤寡,補貧窮。如是,則庶人安政矣。庶人安政,然後君子安位。傳曰:「君者、舟也,庶人者、水也;水則載舟,水則覆舟。」此之謂也。

言︰水則載舟,水則覆舟。到底是誰之過焉!!

所以寫在派生火焰 Python blaze 之先,盼人人能得光明,照亮世間邁向和諧多好呦◎

《LOST 對話錄》

人的存在久遠矣,就像物種的存在一樣,哪有什麼同不同、做不做的事呢?如果存在有道理,那它若不普遍似乎比較神奇的吧!

 誰說人們超越了芝諾,人們果真聽明白了他的話嗎??有窮與無窮並不是人給的條件,而只是認知之不足的啊。就像諸神的時代已經遠離,人們怎麼還不知道如何過日子哩!!

我親愛的普羅米修斯火種是不夠用的,哪怕你認為把光明帶給世界仍舊徒然??因為人類根本無法承受那光亮照明的呢!!

䁗奧思,你為什麼這麼說呢?你明知道這火種既不屬於你也不屬於你的孿生兄弟奧德。它從無物反思自身存有迸發出的大霹靂之火而來 。只要還有時間,自然存在機會阿!當虛空歸寂反噬萬有之時,你曾經歷千百萬次,終究無法回想起是吧!!…

─── 摘自《萬象在說話︰思其思考的人!

 

【派生火焰生態系】

The Blaze Ecosystem

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.

 

【安裝】

 

【展示】

 

 

 

 

 

 

 

 

 

【鼎革‧革鼎】︰ Raspbian Stretch 《三‧丁》

俗話說︰人心不足蛇吞象。用以表達過份貪婪。據維基百科詞條講 ,語源出自《三海經》之『巴蛇食象』︰

山海經校注·海內南經

  (山海經第十·山海經海經新釋卷五)

15、巴蛇食象,三歲而出其骨,君子服之,無心腹之疾①。其為蛇青黃赤黑②。一曰黑蛇青首③,在犀牛西。

①  郭璞云:“今南方(虫丹)蛇(藏經本作蟒蛇——珂)吞鹿,鹿已爛,自絞於樹腹中,骨皆穿鱗甲間出,此其類也。楚詞曰:‘有蛇吞象,厥大何如?’說者云長 千尋。”郝懿行云:“今楚詞天問作‘一蛇吞象’,與郭所引異。王逸注引此經作‘靈蛇吞象’,並與今本異也。”珂案:淮南子本經篇云:“羿斷修蛇於洞庭。” 路史後紀十以“修蛇”作“長它 ”,羅苹注云:“長它即所謂巴蛇,在江岳間。其墓今巴陵之巴丘,在州治側。江源記(即江記,六朝宋庾仲雍撰 ——珂)云:‘羿屠巴蛇於洞庭,其骨若陵,曰巴陵也。’”岳陽風土記(宋范致明撰)亦云:“今巴蛇□在州院廳側,巍然而高,草木叢翳。兼有巴蛇廟,在岳陽 門內 。”又云:“象骨山。山海經云:‘巴蛇吞象。’暴其骨於此。山旁湖謂之象骨港。”是均從此經及淮南子附會而生出之神話。然而既有冢有廟,有山有港,言之確 鑿,則知傳播於民間亦已久矣。

② 珂案:言其文采斑爛也。

③  珂案:海內經云:“有巴遂山,澠水出焉。又有朱卷之國。有黑蛇,青首,食象。”即此。巴,小篆作□,說文十四云:“蟲也;或曰 :食象蛇。象 形。”則所象者,物在蛇腹彭亨之形。山海經多稱大蛇 ,如北山經云:“大咸之山,有蛇名曰長蛇,其毛如彘毫,其音如鼓柝。”北次三經云:“錞於毋逢之山,是 有大蛇,赤首白身,其音如牛,見則其邑大旱。”是可以“吞象”矣。水經注葉榆河云:“山多大蛇 ,名曰髯蛇,長十丈,圍七八尺,常在樹上伺鹿獸,鹿獸過,便低頭繞之。有頃鹿死,先濡令濕訖,便吞,頭角骨皆鑽皮出。山夷始見蛇不動時,便以大竹籤籤蛇頭 至尾,殺而食之,以為珍異。”即郭注所謂(虫丹)蛇也。

───

然而從《山海經》的說法『君子服之,無心腹之疾。』來看,一點也沒有貪婪的意思吧!郭璞認為『巴蛇』是『蟒蛇』一類。無怪乎『TensorFlow』能在二十行內完成『手寫阿拉伯數字』辨識程式︰

MNIST For ML Beginners

This tutorial is intended for readers who are new to both machine learning and TensorFlow. If you already know what MNIST is, and what softmax (multinomial logistic) regression is, you might prefer this faster paced tutorial. Be sure to install TensorFlow before starting either tutorial.

When one learns how to program, there’s a tradition that the first thing you do is print “Hello World.” Just like programming has Hello World, machine learning has MNIST.

MNIST is a simple computer vision dataset. It consists of images of handwritten digits like these:

It also includes labels for each image, telling us which digit it is. For example, the labels for the above images are 5, 0, 4, and 1.

In this tutorial, we’re going to train a model to look at images and predict what digits they are. Our goal isn’t to train a really elaborate model that achieves state-of-the-art performance — although we’ll give you code to do that later! — but rather to dip a toe into using TensorFlow. As such, we’re going to start with a very simple model, called a Softmax Regression.

The actual code for this tutorial is very short, and all the interesting stuff happens in just three lines. However, it is very important to understand the ideas behind it: both how TensorFlow works and the core machine learning concepts. Because of this, we are going to very carefully work through the code.

…… 《W!o+ 的《小伶鼬工坊演義》︰巴蛇食象

 

樹莓派 cpu 力小,若沒有 gpu 輔助,恐怕無法在張量流 Tensorflow 裡衝浪也。即使用 3B 目前還是喝茶好,也別勉強喝咖啡吧!?

認識一下『Caffe』是何物︰

Caffe

Caffe is a deep learning framework made with expression, speed, and modularity in mind. It is developed by the Berkeley Vision and Learning Center (BVLC) and by community contributors. Yangqing Jia created the project during his PhD at UC Berkeley. Caffe is released under the BSD 2-Clause license.

Check out our web image classification demo!

Why Caffe?

Expressive architecture encourages application and innovation. Models and optimization are defined by configuration without hard-coding. Switch between CPU and GPU by setting a single flag to train on a GPU machine then deploy to commodity clusters or mobile devices.

Extensible code fosters active development. In Caffe’s first year, it has been forked by over 1,000 developers and had many significant changes contributed back. Thanks to these contributors the framework tracks the state-of-the-art in both code and models.

Speed makes Caffe perfect for research experiments and industry deployment. Caffe can process over 60M images per day with a single NVIDIA K40 GPU*. That’s 1 ms/image for inference and 4 ms/image for learning. We believe that Caffe is the fastest convnet implementation available.

Community: Caffe already powers academic research projects, startup prototypes, and even large-scale industrial applications in vision, speech, and multimedia. Join our community of brewers on the caffe-users group and Github.

* With the ILSVRC2012-winning SuperVision model and caching IO. Consult performance details.

Documentation

─── 摘自《W!o+ 的《小伶鼬工坊演義》︰神經網絡【FFT】七

 

那麼 OpenCV 呢?!祇看下面

 

的輸出結果,可推知作者當然會嚐鮮矣!!

※ 註︰

‧ 編譯參考 《GoPiGo 小汽車︰朝向目標前進《二》

‧ 概需 32G SD 卡。

‧ 1G swap 空間

 

將要如何驗證哩??心想與其老彈臉部辨識

Face Recognition with OpenCV

 

之陳調,不如就轉拍貼近生活的新照呦◎

高動態範圍成像

High Dynamic Range (HDR)

Goal

In this chapter, we will

  • Learn how to generate and display HDR image from an exposure sequence.
  • Use exposure fusion to merge an exposure sequence.

Theory

High-dynamic-range imaging (HDRI or HDR) is a technique used in imaging and photography to reproduce a greater dynamic range of luminosity than is possible with standard digital imaging or photographic techniques. While the human eye can adjust to a wide range of light conditions, most imaging devices use 8-bits per channel, so we are limited to only 256 levels. When we take photographs of a real world scene, bright regions may be overexposed, while the dark ones may be underexposed, so we can’t capture all details using a single exposure. HDR imaging works with images that use more than 8 bits per channel (usually 32-bit float values), allowing much wider dynamic range.

There are different ways to obtain HDR images, but the most common one is to use photographs of the scene taken with different exposure values. To combine these exposures it is useful to know your camera’s response function and there are algorithms to estimate it. After the HDR image has been merged, it has to be converted back to 8-bit to view it on usual displays. This process is called tonemapping. Additional complexities arise when objects of the scene or camera move between shots, since images with different exposures should be registered and aligned.

In this tutorial we show 2 algorithms (Debvec, Robertson) to generate and display HDR image from an exposure sequence, and demonstrate an alternative approach called exposure fusion (Mertens), that produces low dynamic range image and does not need the exposure times data. Furthermore, we estimate the camera response function (CRF) which is of great value for many computer vision algorithms. Each step of HDR pipeline can be implemented using different algorithms and parameters, so take a look at the reference manual to see them all.

Exposure sequence HDR

In this tutorial we will look on the following scene, where we have 4 exposure images, with exposure times of: 15, 2.5, 1/4 and 1/30 seconds. (You can download the images from Wikipedia)

exposures.jpg

 

 

ldr_debvec.jpg

 

ldr_robertson.jpg

 

fusion_mertens.jpg

 

 

 

 

 

 

 

 

 

輕。鬆。學。部落客