AI engineering glossary · NumPy pandas visualization

What is vectorization?

Vectorization (also called vectorised operations): Writing computations as operations on whole arrays instead of Python loops over single elements. The looping then happens inside optimised compiled code, which is usually tens to hundreds of times faster and also shorter to read. Vectorised style is the normal way to write numerical code in NumPy and pandas.

Level: beginnerTopic: NumPy pandas visualization

Vectorization: an example

prices * 1.18 adds 18 percent GST to every price in an array at once, replacing a for loop over each item.

Related terms

More NumPy pandas visualization terms

Where you learn it

Vectorization is part of the AI Engineering Program, which teaches it with notes, a hands-on lab and an exam. The first lesson is free.

Before you go

Take the cheat sheet with you

One free PDF: the key AI-engineering terms, formulas and Python idioms. No spam; unsubscribe any time.