Skip to main content

Posts

Showing posts with the label numpy arrays

NumPy arrays in Machine Learning

Arrays are the main data structure used in machine learning. In Python, arrays from the NumPy library, called N-dimensional arrays or the ndarray, are used as the primary data structure for representing data.  NumPy (Numerical Python)is a library for the Python programming language, adding support for large, multi-dimensional  arrays  and  matrices , along with a large collection of high-level mathematical functions to operate on these arrays. The ancestor of NumPy, Numeric, was originally created by  Jim Hugunin  with contributions from several other developers. In 2005,  Travis Oliphant  created NumPy by incorporating features of the competing Numarray into Numeric, with extensive modifications. NumPy is open-source software and has many contributors. To use the numpy package in your program, you have to import the package as follows import numpy as np Arrays A numpy array is a grid of values, all of the same type, and is indexed by a tuple of non negative integer