Comments (3)
Can you give some context (and difference with proposed solution)?
from numpy-100.
Sure. In order to compare the colors, the proposed solution encode them as an integer with radix 256, which is not necessary. Instead, we can directly compare the colors, by specifying the axis, and that's what line 3 does. Note that this approach work only when the array is 2D, so just reshape it in advance.
from numpy-100.
Makes sense. Can you make a PR adding your alternative while keeping the old way (which has been modified by #142 but doesn't yet show up on the generator file)
from numpy-100.
Related Issues (20)
- The solution to Q60 is not clear HOT 2
- An alternative solution for Q.63 (Typo) HOT 1
- Possibly Faster solution for #66 HOT 8
- np.eye(10)[4] for Q.6?
- Numpy-100
- about question 5 HOT 3
- Query about Question 3 HOT 1
- An alternative solution for Q.19 HOT 2
- About question 19 HOT 1
- about question 18 HOT 1
- Question # 35 HOT 1
- Typo: 86. ... matrices wich shape ... -> ... matrices with shape ... HOT 2
- Alternative solution to q4 HOT 2
- 12345
- can't enter the normal binder HOT 1
- Solution for Q10 is not entirely correct. HOT 1
- #4 memory size of any array HOT 1
- Q.83 - `np.bincount` doesn't work on negative values HOT 2
- #56 Doesn't use the fact a 2d gaussian is separable and only works for mu=0.0 HOT 1
- #52 question HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from numpy-100.