On Mon, Aug 2, 2021, at 10:50, Sebastian Berg wrote: > * Should `np.ndarray.bit_count()` exist? I tend against this; > but we should have it on (integer) scalars to mirror the > Python `int`.
Should `np.bit_count` exist? Having it on the int* types may be sufficient. > * The return value is currently the same type as the input. That > means that: `np.bit_count(uint8)` returns the count as `uint8` > while `np.bit_count(int32)` returns it as `int32`, etc. What is the max value of the count? 64? If so it can go in a uint8. Stéfan _______________________________________________ NumPy-Discussion mailing list NumPy-Discussion@python.org https://mail.python.org/mailman/listinfo/numpy-discussion