Learning IPython for Interactive Computing and Data Visualization


Learning IPython for Interactive Computing and Data Visualization
eBook: $17.99
Formats: PDF, PacktLib, ePub and Mobi formats
$15.29
save 15%!
Print + free eBook + free PacktLib access to the book: $47.98    Print cover: $29.99
$29.99
save 37%!
Free Shipping!
UK, US, Europe and selected countries in Asia.
Also available on:
Overview
Table of Contents
Author
Support
Sample Chapters
  • A practical step-by-step tutorial which will help you to replace the Python console with the powerful IPython command-line interface
  • Use the IPython notebook to modernize the way you interact with Python
  • Perform highly efficient computations with NumPy and Pandas
  • Optimize your code using parallel computing and Cython

Book Details

Language : English
Paperback : 138 pages [ 235mm x 191mm ]
Release Date : April 2013
ISBN : 1782169938
ISBN 13 : 9781782169932
Author(s) : Cyrille Rossant
Topics and Technologies : All Books, Big Data and Business Intelligence, Open Source, Python

Table of Contents

Preface
Chapter 1: Getting Started with IPython
Chapter 2: Interactive Work with IPython
Chapter 3: Numerical Computing with IPython
Chapter 4: Interactive Plotting and Graphical Interfaces
Chapter 5: High-Performance and Parallel Computing
Chapter 6: Customizing IPython
Index
  • Chapter 1: Getting Started with IPython
    • Installing IPython and the recommended packages
      • Prerequisites for IPython
      • Installing an all-in-one distribution
      • Installing the packages one by one
        • Packages websites
        • Getting binary installers
        • Using the Python packaging system
      • Installing the development versions
    • Ten IPython essentials
      • Running the IPython console
      • Using IPython as a system shell
      • Using the history
      • Tab completion
      • Executing a script with the %run command
      • Quick benchmarking with the %timeit command
      • Quick debugging with the %debug command
      • Interactive computing with Pylab
      • Using the IPython Notebook
      • Customizing IPython
    • Summary
    • Chapter 2: Interactive Work with IPython
      • The extended shell
        • Navigating through the filesystem
        • Accessing the system shell from IPython
      • The extended Python console
        • Exploring the history
        • Import/export of Python code
          • Importing code in IPython
          • Exporting code to a file
        • Dynamic introspection
          • Tab completion
          • Source code introspection
        • Using the interactive debugger
        • Interactive benchmarking and profiling
          • Controlling the execution time of a command
          • Profiling a script
      • Using the IPython notebook
        • Installation
        • The notebook dashboard
        • Working with cells
        • Cell magics
        • Managing notebooks
        • Multimedia and rich text editing
        • Graph plotting
      • Summary
      • Chapter 3: Numerical Computing with IPython
        • A primer to vector computing
          • An example of computation with Python loops
          • What an array is
          • Reimplementing the example with arrays
        • Creating and loading arrays
          • Creating arrays
            • From scratch, element by element
            • From scratch, using predefined templates
            • From random values
          • Loading arrays
            • From a native Python object
            • From a buffer or an external file
            • Using Pandas
        • Working with arrays
          • Selection
            • Using Pandas
            • Using NumPy
            • More indexing possibilities
          • Manipulation
            • Reshaping
            • Repeating and concatenating
            • Broadcasting
            • Permuting
          • Computation
        • Advanced mathematical processing
        • Summary
        • Chapter 4: Interactive Plotting and Graphical Interfaces
          • Figures with Matplotlib
            • Setting up IPython for interactive visualization
              • Using Matplotlib
              • Interactive navigation
              • Matplotlib in the IPython notebook
            • Standard plots
              • Curves
              • Scatter plots
              • Bar graphs
            • Plot customization
              • Styles and colors
              • Grid, axes, and legends
              • Interaction from IPython
              • Drawing multiple plots
          • Advanced figures and graphics
            • Image processing
              • Loading images
              • Showing images
              • Using PIL
              • Advanced image processing – color quantization
            • Maps
            • 3D plots
            • Animations
            • Other visualization packages
          • Graphical User Interfaces (GUI)
            • Setting up IPython for interactive GUIs
            • A "Hello World" example
          • Summary
          • Chapter 5: High-Performance and Parallel Computing
            • Interactive task parallelization
              • Parallel computing in Python
              • Distributing tasks on multiple cores
                • Starting the engines
                • Creating a Client instance
                • Using the parallel magic
                • Parallel map
              • A practical example – Monte Carlo simulations
              • Using MPI with IPython
              • Advanced parallel computing features of IPython
            • Using C in IPython with Cython
              • Installing and configuring Cython
              • Using Cython from IPython
              • Accelerating a pure Python algorithm with Cython
                • Pure Python version
                • Naïve Cython conversion
                • Adding C types
              • Using NumPy and Cython
                • Python version
                • Cython version
              • More advanced options for accelerating Python code
            • Summary
            • Chapter 6: Customizing IPython
              • IPython profiles
                • Profile locations
                • The IPython configuration files
                • Loading scripts when IPython starts
              • IPython extensions
                • Example – line-by-line profiling
                • Creating new extensions
                  • Example – executing C++ code in IPython
              • Rich representations in the frontend
              • Embedding IPython
              • Final words
              • Summary

              Cyrille Rossant

              Dr. Cyrille Rossant is a French researcher in computational neuroscience. A graduate of the Ecole Normale Supérieure, Paris, where he studied Mathematics and Computer Science, he has also worked at Princeton University and University College London. He is interested in all kinds of relationships between brains and computers, including models of neural processing, high-performance simulations of neural networks, and analysis of neurophysiological data. He has also worked on parallel computing and high-performance visualization technologies for Python, and he is a core developer of Vispy, a visualization package. He is the author of Learning IPython for Interactive Computing and Data Visualization, Packt Publishing, the prequel of this cookbook.
              Sorry, we don't have any reviews for this title yet.

              Code Downloads

              Download the code and support files for this book.


              Submit Errata

              Please let us know if you have found any errors not listed on this list by completing our errata submission form. Our editors will check them and add them to this list. Thank you.


              Errata

              - 1 submitted: last submission 05 Jun 2013

              Errata type: Code Related|Page number: 92

              In [4]: import os

              Should be

              In [4]: %px import os

              Sorry, there are currently no downloads available for this title.

              Frequently bought together

              Learning IPython for Interactive Computing and Data Visualization +    Building Machine Learning Systems with Python =
              50% Off
              the second eBook
              Price for both: $34.50

              Buy both these recommended eBooks together and get 50% off the cheapest eBook.

              What you will learn from this book

              • Debug your code from the IPython console
              • Benchmark and profile your code from IPython
              • Perform efficient vectorized computations with NumPy
              • Analyze data tables with Pandas
              • Create visualizations with Matplotlib
              • Parallelize your code easily with IPython
              • Customize IPython and create your own magic commands
              • Accelerate your Python code using dynamic C compilation with Cython

              In Detail

              You already use Python as a scripting language, but did you know it is also increasingly used for scientific computing and data analysis? Interactive programming is essential in such exploratory tasks and IPython is the perfect tool for that. Once you’ve learnt it, you won’t be able to live without it.

              "Learning IPython for Interactive Computing and Data Visualization" is a practical, hands-on, example-driven tutorial to considerably improve your productivity during interactive Python sessions, and shows you how to effectively use IPython for interactive computing and data analysis.

              This book covers all aspects of IPython, from the highly powerful interactive Python console to the numerical and visualization features that are commonly associated with IPython.

              You will learn how IPython lets you perform efficient vectorized computations, through examples covering numerical simulations with NumPy, data analysis with Pandas, and visualization with Matplotlib. You will also discover how IPython can be conveniently used to optimize your code using parallel computing and dynamic compilation in C with Cython.

              "Learning IPython for Interactive Computing and Data Visualization" will allow you to optimize your productivity in interactive Python sessions.

              Approach

              A practical hands-on guide which focuses on interactive programming, numerical computing, and data analysis with IPython.

              Who this book is for

              This book is for Python developers who use Python as a scripting language or for software development, and are interested in learning IPython for increasing their productivity during interactive sessions in the console. Knowledge of Python is required, whereas no knowledge of IPython is necessary.

              Code Download and Errata
              Packt Anytime, Anywhere
              Register Books
              Print Upgrades
              eBook Downloads
              Video Support
              Contact Us
              Awards Voting Nominations Previous Winners
              Judges Open Source CMS Hall Of Fame CMS Most Promising Open Source Project Open Source E-Commerce Applications Open Source JavaScript Library Open Source Graphics Software
              Resources
              Open Source CMS Hall Of Fame CMS Most Promising Open Source Project Open Source E-Commerce Applications Open Source JavaScript Library Open Source Graphics Software