Skip to content

Jupyter notebooks for our O'Reilly book "Blueprints for Text Analysis Using Python"

License

Notifications You must be signed in to change notification settings

naiarapm/blueprints-text

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Blueprints for Text Analysis Using Python

Machine Learning Based Solutions for Common Real World (NLP) Applications

Jens Albrecht, Sidharth Ramachandran, Christian Winkler

Published by O'Reilly, 2020

cover

Order at O'Reilly
Order at Amazon.com
Order at Amazon.de
Order at Amazon.co.uk
Order at Amazon.fr
Order at Amazon.in


Content of this Repository

This repository is currently in preparation. Please do not yet send any comments.

This repository contains the code examples of our O'Reilly book. You will find a subdirectory for each chapter containing a Jupyter notebook and additional files for the setup.

Below you find the links to view the notebooks here on Github or execute them directly on Google Colab. In the section thereafter you will find instructions to setup the environment on your local computer.

Problems and Errors

If you discover any problems or have recommendations on how to improve the code, do not hesitate to create an issue here in the repository.

For errors in the book text, please use O'Reilly's errata page.

View or Run the Notebooks

For each chapter of the book we provide three links:

  • "git" opens the notebook for viewing here on Github (sometimes not working because of Github issue)
  • "nbviewer" opens the notebook for viewing on nbviewer.ipython.org
  • "colab" opens a runnable copy on Google's Colab service

If you run the notebook locally or on Colab, you can execute each cell separately by hitting "Shift-enter". Do not skip cells and don't forget to run the first code cells for the setup.

Local Setup

The following instructions should work on Linux, Windows and MacOS. If you are a Windows user familiar with Linux, you should check out the Windows Subsystem for Linux, Version 2 (WSL2). This allows to use a Linux system on the Windows machine. However, using native Windows should also be no problem.

It is helpful to install git on your machine, but you can also download the full repository from Github as a zip file. If you use git, run the following commands from the command line:

git clone https://github.com/blueprints-for-text-analytics-python/blueprints-text.git
cd blueprints-text

Otherwise download the zip file, unpack it to a location convenient to you, and open a command line terminal in the project directory blueprints-text.

For local setup, we recommend to use Miniconda, a minimal version of the popular Anaconda distribution that contains only the package manager conda and Python. Follow the installation instructions on the Miniconda Homepage. If you already have Anaconda or Miniconda installed on your system: That's fine. We will create a separate virtual environment for the blueprints book so that our installation will not interfere with your previous setup.

After installation of Anaconda/Miniconda, run the following command(s) from the project directory:

conda env create --name blueprints --file blueprints.yml
conda activate blueprints

The prompt should change after activation and indicate that you are working in the blueprints environment. Our installation includes the Jupyter notebook extensions. We suggest to enable the extensions "table of contents" (toc2), "execute time", and "variable inspector" (varInspector):

jupyter nbextension enable toc2/main
jupyter nbextension enable execute_time/ExecuteTime
jupyter nbextension enable varInspector/main

Now you can start the Jupyter notebook server:

jupyter notebook

If working on WSL under Windows, add --no-browser.

Browse to the respective chapter and open the notebook file (suffix .ipynb)

About

Jupyter notebooks for our O'Reilly book "Blueprints for Text Analysis Using Python"

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Jupyter Notebook 73.2%
  • HTML 22.6%
  • TeX 2.6%
  • Python 1.5%
  • Other 0.1%