Wednesday, September 23, 2015

numpy.ndarray doesn't have count attribute

First convert it into a list, by using list() function. Then use the count method to count.

list(nda).count(1)

No comments:

Post a Comment

Any comments?

my-alpine and docker-compose.yml

 ``` version: '1' services:     man:       build: .       image: my-alpine:latest   ```  Dockerfile: ``` FROM alpine:latest ENV PYTH...