错误:搜索内容不能为空,请输入英文关键词
错误:关键词超出字数限制,请精简
高级检索

A Tour of Python

  • Pierre M. Nugues

摘要

All the programs in this book use Python. This chapter gives an introduction to this language with a specific focus on text processing. This will enable us to touch all the data structures and programming constructs we need to implement our algorithms. Large collections of texts form the raw material of natural language processing. This chapter describes the different kinds of corpora and how we can use them in applications. It introduces regular expressions, a ubiquitous tool to process text. We then move on to Python programming and its regular expression module to match patterns in text and apply some transformations. We finally review techniques to carry out approximate string matching.