python numpy usage - bincount

Today to see the script when it came to the use of a few do not understand, recorded for later viewing:

1、numpy bincount

First on the map:

 

As shown above: the first requirement can not contain negative input array;

This function is non-negative number of computing elements, if the maximum value in the array is 100, then there is an output element 101, on behalf of each position, the input array, the value of the number of zeros, the number of value 1 . . . Is the number of 100;

 

Guess you like

Origin www.cnblogs.com/rainsoul/p/11051693.html