Learning Cython Programming, 2/e(Paperback)
暫譯: 學習 Cython 程式設計(第二版)

Philip Herron

  • 出版商: Packt Publishing
  • 出版日期: 2016-02-23
  • 售價: $1,670
  • 貴賓價: 9.5$1,587
  • 語言: 英文
  • 頁數: 110
  • 裝訂: Paperback
  • ISBN: 1783551674
  • ISBN-13: 9781783551675
  • 相關分類: C 程式語言Python程式語言
  • 海外代購書籍(需單獨結帳)

買這商品的人也買了...

商品描述

Key Features

  • Learn how to extend C applications with pure Python code
  • Get more from Python – you'll not only learn Cython, you'll also unlock a greater understanding of how to harness Python
  • Packed with tips and tricks that make Cython look easy, dive into this accessible programming guide and find out what happens when you bring C and Python together!

Book Description

Cython is a hybrid programming language used to write C extensions for Python language. Combining the practicality of Python and speed and ease of the C language it's an exciting language worth learning if you want to build fast applications with ease.

This new edition of Learning Cython Programming shows you how to get started, taking you through the fundamentals so you can begin to experience its unique powers.

You'll find out how to get set up, before exploring the relationship between Python and Cython. You'll also look at debugging Cython, before moving on to C++ constructs, Caveat on C++ usage, Python threading and GIL in Cython. Finally, you'll learn object initialization and compile time, and gain a deeper insight into Python 3, which will help you not only become a confident Cython developer, but a much more fluent Python developer too.

What you will learn

  • Reuse Python logging in C
  • Make an IRC bot out of your C application
  • Extend an application so you have a web server for rest calls
  • Practice Cython against your C++ code
  • Discover tricks to work with Python ConfigParser in C
  • Create Python bindings for native libraries
  • Find out about threading and concurrency related to GIL
  • Expand Terminal Multiplexer Tmux with Cython

About the Author

Philip Herron is a developer who focuses his passion toward compilers and virtual machine implementations. When he was first accepted to Google Summer of Code 2010, he used inspiration from Paul Biggar's PhD on the optimization of dynamic languages to develop a proof of the concept GCC frontend to compile Python. This project sparked his deep interest in how Python works.

After completing a consecutive year on the same project in 2011, Philip applied to Cython under the Python foundation to gain a deeper appreciation of the standard Python implementation. Through this he started leveraging the advantages of Python to control the logic in systems or even add more high-level interfaces, such as embedding Flask web servers in a REST API to a system-level piece of software, without writing any C code.

Philip currently works as a software consultant for Instil Software based in Northern Ireland. He develops mobile applications with embedded native code for video streaming. Instil has given him a lot of support in becoming a better engineer.

He has written several tutorials for the UK-based Linux Format magazine on Python and loves to share his passion for the Python programming language.

Table of Contents

  1. Cython Won't Bite
  2. Understanding Cython
  3. Extending Applications
  4. Debugging Cython
  5. Advanced Cython
  6. Further Reading

商品描述(中文翻譯)

**主要特點**

- 學習如何使用純 Python 代碼擴展 C 應用程式
- 從 Python 中獲得更多 - 你不僅會學習 Cython,還會更深入了解如何利用 Python
- 充滿了讓 Cython 看起來簡單的技巧和竅門,深入這本易於理解的程式設計指南,發現當你將 C 和 Python 結合時會發生什麼!

**書籍描述**

Cython 是一種混合程式語言,用於為 Python 語言編寫 C 擴展。它結合了 Python 的實用性和 C 語言的速度與簡便性,是一種值得學習的令人興奮的語言,特別是如果你想輕鬆構建快速應用程式。

這本《學習 Cython 程式設計》的新版本將指導你如何入門,帶你了解基本概念,讓你開始體驗其獨特的功能。

你將學會如何設置環境,然後探索 Python 和 Cython 之間的關係。你還將學習 Cython 的除錯,然後進入 C++ 結構、C++ 使用的注意事項、Python 線程和 Cython 中的全域解釋器鎖(GIL)。最後,你將學習物件初始化和編譯時間,並深入了解 Python 3,這將幫助你不僅成為一名自信的 Cython 開發者,還能成為一名更流利的 Python 開發者。

**你將學到的內容**

- 在 C 中重用 Python 日誌
- 將你的 C 應用程式製作成 IRC 機器人
- 擴展應用程式,使其擁有用於 REST 調用的網頁伺服器
- 在你的 C++ 代碼中練習 Cython
- 發現與 C 中的 Python ConfigParser 相關的技巧
- 為本地庫創建 Python 綁定
- 了解與 GIL 相關的線程和並發
- 使用 Cython 擴展終端多路復用器 Tmux

**關於作者**

**Philip Herron** 是一位開發者,專注於編譯器和虛擬機實現的熱情。當他首次被接受參加 2010 年的 Google Summer of Code 時,他從 Paul Biggar 的博士論文中獲得靈感,該論文探討了動態語言的優化,並開發了一個概念證明的 GCC 前端來編譯 Python。這個項目激發了他對 Python 工作原理的深厚興趣。

在 2011 年完成同一項目的連續一年後,Philip 申請了 Python 基金會下的 Cython,以更深入地理解標準 Python 實現。通過這個過程,他開始利用 Python 的優勢來控制系統中的邏輯,甚至添加更多高級介面,例如在系統級軟體中嵌入 Flask 網頁伺服器的 REST API,而無需編寫任何 C 代碼。

Philip 目前在位於北愛爾蘭的 Instil Software 擔任軟體顧問。他開發嵌入本地代碼的移動應用程式,用於視頻串流。Instil 在他成為更好的工程師方面給予了他很多支持。

他為英國的 Linux Format 雜誌撰寫了幾篇有關 Python 的教程,並熱衷於分享他對 Python 程式設計語言的熱情。

**目錄**

1. Cython 不會咬人
2. 理解 Cython
3. 擴展應用程式
4. 除錯 Cython
5. 進階 Cython
6. 進一步閱讀

最後瀏覽商品 (20)