Top "Numpy" questions

NumPy is an extension of the Python language that adds support to large multidimensional arrays and matrixes, along with a large library of high-level mathematical functions for operations with these arrays.

Concatenating two one-dimensional NumPy arrays

I have two simple one-dimensional arrays in NumPy. I should be able to concatenate them using numpy.concatenate. But I …

python arrays numpy concatenation numpy-ndarray
Pandas read_csv low_memory and dtype options

When calling df = pd.read_csv('somefile.csv') I get: /Users/josh/anaconda/envs/py27/lib/python2.7/site-packages/pandas/io/…

python parsing numpy pandas dataframe
Sorting arrays in NumPy by column

How can I sort an array in NumPy by the nth column? For example, a = array([[9, 2, 3], [4, 5, 6], [7, 0, 5]]) I'd like to sort …

python arrays sorting numpy scipy
Installing Numpy on 64bit Windows 7 with Python 2.7.3

It looks like the only 64 bit windows installer for Numpy is for Numpy version 1.3.0 which only works with Python 2.6 http://…

python windows python-2.7 numpy
What does -1 mean in numpy reshape?

A numpy matrix can be reshaped into a vector using reshape function with parameter -1. But I don't know what …

python numpy reshape numpy-ndarray
How do you get the magnitude of a vector in Numpy?

In keeping with the "There's only one obvious way to do it", how do you get the magnitude of a …

python numpy
how to convert an RGB image to numpy array?

I have an RGB image. I want to convert it to numpy array. I did the following im = cv.LoadImage("…

python image opencv numpy
How to convert an array of strings to an array of floats in numpy?

How to convert ["1.1", "2.2", "3.2"] to [1.1, 2.2, 3.2] in NumPy?

python numpy
Find nearest value in numpy array

Is there a numpy-thonic way, e.g. function, to find the nearest value in an array? Example: np.find_nearest( …

python search numpy
numpy: most efficient frequency counts for unique values in an array

In numpy / scipy, is there an efficient way to get frequency counts for unique values in an array? Something along …

python arrays performance numpy