
谷歌的AI擊敗了一位圍棋大師,是一種衡量人工智能突然的快速發展的方式,也揭示了這些技術如何發展而來和將來可以如何發展。
人工智能是一種未來性的技術,目前正在致力于研究自己的一套工具。一系列的進展在過去的幾年中發生了:無事故駕駛超過300000英里并在三個州合法行駛迎來了自動駕駛的一個里程碑;IBM Waston擊敗了Jeopardy兩屆冠軍;統計學習技術從對消費者興趣到以萬億記的圖像的復雜數據集進行模式識別。這些發展必然提高了科學家和巨匠們對人工智能的興趣,這也使得開發者們了解創建人工智能應用的真實本質。開發這些需要注意的第一件事是:
哪一種編程語言適合人工智能?
你所熟練掌握的每一種編程語言都可以是人工智能的開發語言。
人工智能程序可以使用幾乎所有的編程語言實現,最常見的有:Lisp,Prolog,C/C++,近來又有Java,最近還有Python.
LISP
像LISP這樣的高級語言在人工智能中備受青睞,因為在各高校多年的研究后選擇了快速原型而舍棄了快速執行。垃圾收集,動態類型,數據函數,統一的語法,交互式環境和可擴展性等一些特性使得LIST非常適合人工智能編程。
PROLOG
這種語言有著LISP高層和傳統優勢有效結合,這對AI是非常有用的。它的優勢是解決“基于邏輯的問題”。Prolog提供了針對于邏輯相關問題的解決方案,或者說它的解決方案有著簡潔的邏輯特征。它的主要缺點(恕我直言)是學起來很難。
C/C++
就像獵豹一樣,C/C++主要用于對執行速度要求很高的時候。它主要用于簡單程序,統計人工智能,如神經網絡就是一個常見的例子。Backpropagation 只用了幾頁的C/C++代碼,但是要求速度,哪怕程序員只能提升一點點速度也是好的。
JAVA
新來者,Java使用了LISP中的幾個理念,最明顯的是垃圾收集。它的可移植性使它可以適用于任何程序,它還有一套內置類型。Java沒有LISP和Prolog高級,又沒有C那樣快,但如果要求可移植性那它是最好的。
PYTHON
Python是一種用LISP和JAVA編譯的語言。按照Norvig文章中對Lips和Python的比較,這兩種語言彼此非常相似,僅有一些細小的差別。還有JPthon,提供了訪問Java圖像用戶界面的途徑。這是PeterNorvig選擇用JPyhton翻譯他人工智能書籍中程序的的原因。JPython可以讓他使用可移植的GUI演示,和可移植的http/ftp/html庫。因此,它非常適合作為人工智能語言的。
在人工智能上使用Python比其他編程語言的好處
優質的文檔
平臺無關,可以在現在每一個*nix版本上使用
和其他面向對象編程語言比學習更加簡單快速
Python有許多圖像加強庫像Python Imaging Libary,VTK和Maya 3D可視化工具包,Numeric Python, Scientific Python和其他很多可用工具可以于數值和科學應用。
Python的設計非常好,快速,堅固,可移植,可擴展。很明顯這些對于人工智能應用來說都是非常重要的因素。
對于科學用途的廣泛編程任務都很有用,無論從小的shell腳本還是整個網站應用。
最后,它是開源的??梢缘玫较嗤纳鐓^支持。
AI的Python庫
總體的AI庫
AIMA:Python實現了從Russell到Norvigs的“人工智能:一種現代的方法”的算法
pyDatalog:Python中的邏輯編程引擎
SimpleAI:Python實現在“人工智能:一種現代的方法”這本書中描述過的人工智能的算法。它專注于提供一個易于使用,有良好文檔和測試的庫。
EasyAI:一個雙人AI游戲的python引擎(負極大值,置換表、游戲解決)
機器學習庫
PyBrain 一個靈活,簡單而有效的針對機器學習任務的算法,它是模塊化的Python機器學習庫。它也提供了多種預定義好的環境來測試和比較你的算法。
PyML 一個用Python寫的雙邊框架,重點研究SVM和其他內核方法。它支持Linux和Mac OS X。
scikit-learn旨在提供簡單而強大的解決方案,可以在不同的上下文中重用:機器學習作為科學和工程的一個多功能工具。它是python的一個模塊,集成了經典的機器學習的算法,這些算法是和python科學包(numpy,scipy.matplotlib)緊密聯系在一起的。
MDP-Toolkit這是一個Python數據處理的框架,可以很容易的進行擴展。它海收集了有監管和沒有監管的學習算飯和其他數據處理單元,可以組合成數據處理序列或者更復雜的前饋網絡結構。新算法的實現是簡單和直觀的??捎玫乃惴ㄊ窃诓粩嗟姆€定增加的,包括信號處理方法(主成分分析、獨立成分分析、慢特征分析),流型學習方法(局部線性嵌入),集中分類,概率方法(因子分析,RBM),數據預處理方法等等。
自然語言和文本處理庫
NLTK 開源的Python模塊,語言學數據和文檔,用來研究和開發自然語言處理和文本分析。有windows,Mac OSX和Linux版本。
案例
做了一個實驗,一個使用人工智能和物聯網做員工行為分析的軟件。該軟件通過員工情緒和行為的分心提供了一個有用的反饋給員工,從而提高了管理和工作習慣。
使用Python機器學習庫,opencv和haarcascading概念來培訓。建立了樣品POC來檢測通過安置在不同地點的無線攝像頭傳遞回來基礎情感像幸福,生氣,悲傷,厭惡,懷疑,蔑視,譏諷和驚喜。收集到的數據會集中到云數據庫中,甚至整個辦公室都可以通過在Android設備或桌面點擊一個按鈕來取回。
開發者在深入分析臉部情感上復雜點和挖掘更多的細節中取得進步。在深入學習算法和機器學習的幫助下,可以幫助分析員工個人績效和適當的員工/團隊反饋。
結論
python因為提供像 scikit-learn的好的框架,在人工智能方面扮演了一個重要的角色:Python中的機器學習,實現了這一領域中大多的需求。D3.js JS中數據驅動文檔時可視化最強大和易于使用的工具之一。處理框架,它的快速原型制造使得它成為一門不可忽視的重要語言。AI需要大量的研究,因此沒有必要要求一個500KB的Java樣板代碼去測試新的假說。python中幾乎每一個想法都可以迅速通過20-30行代碼來實現(JS和LISP也是一樣)。因此,它對于人工智能是一門非常有用的語言。
【英文原版】
Role of Python in Artificial Intelligence
Google’s AI Beating a Go Grandmaster is a way of judging the suddenly rapid progress of artificial intelligence that may show how far these technologies have come—and how far they may go.
Artificial intelligence is a futuristic technology that is working on its set of tools at present. A slew of advances has been observed in last few years: Self-driving cars that have achieved a milestone by logging over 300,000 accident-free miles and becoming officially legal in three states; IBM Watson which beat two champions of Jeopardy!; and statistical learning techniques are conducting pattern recognition on complex data sets from consumer interests to trillions of images. These developments certainly raised the number of scientists or giants taking interest in AI, which has made it essential for developers to understand the ground realities of building AI applications. The first thing that strikes developers is,
Which programming language is good for AI?
Every programming language is a AI language if you are adept in it!
AI programs are written in almost all the programming languages, the most common are: Lisp, Prolog, C/C++, recently Java, and even more recently, Python.
LISP
High-level languages like LISP are favored in AI because after many years of research in various universities fast prototyping was chosen over fast execution. Garbage collection, dynamic typing, functions as data, uniform syntax, interactive environment, and extensibility are some of its feature that makes the language suitable for AI programming.
PROLOG
This language comes with an effective combination of the high-level and traditional advantages of Lisp with a built-in unifier, which is particularly useful in AI. It’s strength is ‘logic based problems’. Prolog gives good solutions for problems in which logic is intimately involved, or whose solutions have a succinct logical characterization. Its major drawback (IMHO) is that it’s hard to learn.
C/C++
Cheetah of the bunch, C/C++ is mostly used when the speed of execution is most important. It is used mostly when the program is simple, statistical AI techniques such as neural networks are common examples of this. Backpropagation is only a couple of pages of C/C++ code, and needs every ounce of speed that the programmer can muster.
JAVA
The newcomer, Java uses several ideas from Lisp, most notably garbage collection. Its portability makes it desirable for just about any application, and it has a decent set of built in types. Java is still not as high-level as Lisp or Prolog, and not as fast as C, making it best when portability is paramount.
PYTHON
Python is a language with the best compilation of Lisp and Java both.According to Norvig is his text comparing Lisp to Python, these two languages are very similar to each other with some minor differences. There also exists JPython, giving access to the Java GUIs. This is the reason behind Peter Norvig choosing JPython to translate his programs from his AI book. As JPython allowed him to have portable GUI demos, and portable http/ftp/html libraries. Therefore, it is very good to use as AI language.
Benefits of Using Python over the Other Programming Languages for AI
1.Good quality documentation.
2.Platform agnostic, and present in virtually every *nix distribution.
3.Easy and fast to learn in comparison to any other OOP language.
4.Python has many image intensive libraries like Python Imaging Library, VTK and Maya 3D Visualization Toolkits, Numeric Python, Scientific Python and many other tools available for numeric and scientific applications.
5.Python is very well designed, fast, robust, portable, and scalable. These are evidently the most important factors for AI applications.
6.Useful for a really broad range of programming tasks from little shell scripts to enterprise web applications to scientific uses.
7.Last but not the least, it is Open Source! Good community support available for the same.
Python Libraries for AI
Libraries for General AI
1.AIMA – Python implementation of algorithms from Russell and Norvig’s ‘Artificial Intelligence: A Modern Approach’
2.pyDatalog – Logic Programming engine in Python
3.SimpleAI – Python implementation of many of the artificial intelligence algorithms described on the book “Artificial Intelligence, a Modern Approach”. It focuses on providing an easy to use, well documented and tested library.
4.EasyAI – Simple Python engine for two-players games with AI (Negamax, transposition tables, game solving).
Libraries for ML
1.PyBrain – It is a flexible, simple yet effective algorithms for ML tasks, it is a modular Machine Learning Library for Python. It also provides a variety of predefined environments to test and compare your algorithms.
2.PyML – A bilateral framework written in Python that focuses on SVMs and other kernel methods. It is supported on Linux and Mac OS X.
3.scikit-learn – It aims to provide easy and powerful solutions reusable in various contexts: machine-learning as a versatile tool for science and engineering. It is a Python module that integrates the classic classic machine learning algorithms in the tightly-knit world of scientific Python packages (numpy, scipy, matplotlib).
4.MDP-Toolkit – It is a Python data processing framework that can be easily expanded, it also has a collection of supervised and unsupervised learning algorithms and other data processing units that can be combined into data processing sequences and more complex feed-forward network architectures. The implementation of new algorithms is easy and intuitive. The base of available algorithms is steadily increasing and includes signal processing methods (Principal Component Analysis, Independent Component Analysis, Slow Feature Analysis), manifold learning methods ([Hessian] Locally Linear Embedding), several classifiers, probabilistic methods (Factor Analysis, RBM), data pre-processing methods, and many others.
Libraries for Natural Language & Text Processing
NLTK – Open source Python modules, linguistic data and documentation for research and development in natural language processing and text analytics, with distributions for Windows, Mac OSX and Linux.
Case Study
An experiment to bring AI to use with Internet of Things was done to make a software for employee behavioral analytics. The software provides useful feedback to the employees through employee emotions and behaviour analysis, thus enhancing positive changes in management and work habits.
Using python machine learning libraries, opencv and haarcascading concepts for application training, a sample POC was built to detect basic emotions like happiness, anger, sadness, disgust, suspicion, contempt, sarcasm and surprise through wireless cameras attached at various bay points. The data collected was feeded to a centralized cloud database where daily emotional quotient within the bay, or even the entire office could be retrieved at the click of a button either through android device or desktop.
Developers are making gradual progress in analyzing further complex points on facial emotions and mine more details with the help of deep learning algorithms and machine learning which can help analyze individual employee performance and help in proper employee/team feedback.
Conclusion
Python plays an important role in Artificial Intelligence by providing it with good frameworks like scikit-learn: machine learning in Python, which fulfills almost every need in this field and D3.js – Data-Driven Documents in JS, which is one of the most powerful and easy-to-use tools for visualization. Other than frameworks, it’s fast prototyping makes it an important language not to be ignored. AI needs a lot of research and hence it is necessary not to require a 500 KB boilerplate code in Java to test a new hypothesis, which will never finish the project. In Python almost every idea can be quickly validated through 20-30 lines of code (same for JS with libs). Therefore, it is a pretty useful language for the sake of AI.
數據分析咨詢請掃描二維碼
若不方便掃碼,搜微信號:CDAshujufenxi
CDA數據分析師證書考試體系(更新于2025年05月22日)
2025-05-26解碼數據基因:從數字敏感度到邏輯思維 每當看到超市貨架上商品的排列變化,你是否會聯想到背后的銷售數據波動?三年前在零售行 ...
2025-05-23在本文中,我們將探討 AI 為何能夠加速數據分析、如何在每個步驟中實現數據分析自動化以及使用哪些工具。 數據分析中的AI是什么 ...
2025-05-20當數據遇見人生:我的第一個分析項目 記得三年前接手第一個數據分析項目時,我面對Excel里密密麻麻的銷售數據手足無措。那些跳動 ...
2025-05-20在數字化運營的時代,企業每天都在產生海量數據:用戶點擊行為、商品銷售記錄、廣告投放反饋…… 這些數據就像散落的拼圖,而相 ...
2025-05-19在當今數字化營銷時代,小紅書作為國內領先的社交電商平臺,其銷售數據蘊含著巨大的商業價值。通過對小紅書銷售數據的深入分析, ...
2025-05-16Excel作為最常用的數據分析工具,有沒有什么工具可以幫助我們快速地使用excel表格,只要輕松幾步甚至輸入幾項指令就能搞定呢? ...
2025-05-15數據,如同無形的燃料,驅動著現代社會的運轉。從全球互聯網用戶每天產生的2.5億TB數據,到制造業的傳感器、金融交易 ...
2025-05-15大數據是什么_數據分析師培訓 其實,現在的大數據指的并不僅僅是海量數據,更準確而言是對大數據分析的方法。傳統的數 ...
2025-05-14CDA持證人簡介: 萬木,CDA L1持證人,某電商中廠BI工程師 ,5年數據經驗1年BI內訓師,高級數據分析師,擁有豐富的行業經驗。 ...
2025-05-13CDA持證人簡介: 王明月 ,CDA 數據分析師二級持證人,2年數據產品工作經驗,管理學博士在讀。 學習入口:https://edu.cda.cn/g ...
2025-05-12CDA持證人簡介: 楊貞璽 ,CDA一級持證人,鄭州大學情報學碩士研究生,某上市公司數據分析師。 學習入口:https://edu.cda.cn/g ...
2025-05-09CDA持證人簡介 程靖 CDA會員大咖,暢銷書《小白學產品》作者,13年頂級互聯網公司產品經理相關經驗,曾在百度、美團、阿里等 ...
2025-05-07相信很多做數據分析的小伙伴,都接到過一些高階的數據分析需求,實現的過程需要用到一些數據獲取,數據清洗轉換,建模方法等,這 ...
2025-05-06以下的文章內容來源于劉靜老師的專欄,如果您想閱讀專欄《10大業務分析模型突破業務瓶頸》,點擊下方鏈接 https://edu.cda.cn/g ...
2025-04-30CDA持證人簡介: 邱立峰 CDA 數據分析師二級持證人,數字化轉型專家,數據治理專家,高級數據分析師,擁有豐富的行業經驗。 ...
2025-04-29CDA持證人簡介: 程靖 CDA會員大咖,暢銷書《小白學產品》作者,13年頂級互聯網公司產品經理相關經驗,曾在百度,美團,阿里等 ...
2025-04-28CDA持證人簡介: 居瑜 ,CDA一級持證人國企財務經理,13年財務管理運營經驗,在數據分析就業和實踐經驗方面有著豐富的積累和經 ...
2025-04-27數據分析在當今信息時代發揮著重要作用。單因素方差分析(One-Way ANOVA)是一種關鍵的統計方法,用于比較三個或更多獨立樣本組 ...
2025-04-25CDA持證人簡介: 居瑜 ,CDA一級持證人國企財務經理,13年財務管理運營經驗,在數據分析就業和實踐經驗方面有著豐富的積累和經 ...
2025-04-25