Y
HN Search
Hacker News Search
new
|
comments
|
top
|
jobs
cdavid
searching PlanetScale…
1.
▲
2.
▲
3.
▲
4.
▲
5.
▲
6.
▲
78 ms
·
721.
▲
by
cdavid
16y ago
But javascript does not have something like numpy. You can easily get one to two orders of magnitude faster using numpy when applicable, and a MP3 decode certainly falls in that category.
722.
▲
by
cdavid
16y ago
Oh, python has a nice solution in this problem space - NumPy. But again, this only works in some cases. Unfortunately, the model fails performance-wise once you use non native type - think array of arbitrary precision floats. Haskell being
723.
▲
by
cdavid
16y ago
What I am saying is that the whole concept of doing the heavy logic in the high level language and do the work in the C implementation cannot work when your logic depends on handling many objects. For example, I wrote a few years ago a smal
724.
▲
by
cdavid
16y ago
Yep, in that case, that's relatively easy - but cython is even better. Cython is used a lot in the scipy community - if you don't know it, you may want to look at it. Since I am using cython, I am trying to avoid writing raw C API as much a
725.
▲
by
cdavid
16y ago
Being implemented in C does not make things fast. Integers are implemented in C in python, but they are really slow, because of the boxing/unboxing thing (you need to chase one pointer pointer to get the actual C int from the Python object
726.
▲
by
cdavid
16y ago
Because of the python <-> C marshalling cost. Let's say you have some code which uses a lot of small objects which interact with each other, maybe each object has a small list with a few integers. Replacing this in C would make sens
727.
▲
by
cdavid
16y ago
This works only if your bottlenecks are a small portion of your work. For example, if your twisted application is slow, you will have a hard time optimizing it by writing a bit of C code.
728.
▲
by
cdavid
16y ago
Writing C extensions is only easy if you do trivial things. As soon as you do something significant, writing all this C code by hand becomes increasingly complex, especially because of reference counting and error management ( http://docs.p
729.
▲
by
cdavid
16y ago
Psyco does not work on 64 bits, which makes it nearly useless for most servers-oriented kind of work
730.
▲
by
cdavid
16y ago
Fossee ( http://fossee.in/ ) was one of the association which helped organizing the conference, and you may find more information on their website if you are interested.
731.
▲
by
cdavid
16y ago
Most projects I have been involved with were related to my PhD at that time, numerical computing kind of stuff in python. Going to the conferences in Europe or the US, it is already quite exciting because you see a lot of people, in academi
732.
▲
by
cdavid
16y ago
Open source still makes a big difference, especially in 3rd world country. I went once to an open source conference in India, it really opened my eyes to a whole new way of looking at the movement. Maybe that's what you may want to look at:
733.
▲
by
cdavid
16y ago
But if you rebuild python from scratch, you loose every single software packaged by your distribution. If you depend on modules with C extensions, it quickly becomes intractable. Building python is easy - building a recent pyqt on RHEL 5, n
734.
▲
by
cdavid
16y ago
It depends on what you mean by running unchanged. Numpy and scipy also support 2.4 to 2.7 (and soon to 3.1) from the same codebase. But everytime a new version of python is out, we need to make some changes, albeit relatively minors. So it
735.
▲
by
cdavid
16y ago
If you build yourself a new python, what's the point of virtualenv ? Compiling python is of course possible, although quite a chore if all you want is to configure some software. Concerning the need to obtain a new python if you want to use
736.
▲
by
cdavid
16y ago
I am curious: how do you think virtualenv and pip would solve the issue of antiquated python ? The only thing that virtualenv does is to install packages in some temporary location, that you can throw away later without impacting anything o
737.
▲
by
cdavid
16y ago
I feel sorry for your experience, it just does not match mine. Note that we are not talking about the same products - I mainly use vmware workstation/player/fusion (I deal a lot with cross platform issues in some medium-size open source pro
738.
▲
by
cdavid
16y ago
Vmware is one of the few software I have ever bought, I am pretty hardcore open source otherwise. Vmware works very well, has top notch clone/backup/rollback feature, can automatically install tons of different OS. That's a real time saver.
739.
▲
by
cdavid
16y ago
If X[0] is masked, it will return the value mask, of type MaskedConstant. As for python vs numpy differences: yes, those can be confusing, and that's inherent to the fact that we use a "real" language with a library on top of it instead of
740.
▲
by
cdavid
16y ago
thanks, I will take a look at it at home (where I have enough memory to deal with that kind of matrix). As I said, the scipys.sparse is pretty rough and too low-level, but 3 sec vs 8 hours is way too long to be normal. (I forked your gist s
741.
▲
by
cdavid
16y ago
ATLAS/BLAS/LAPACK is mostly useless for basic sparse operations, at least in scipy. It becomes useful for more advanced operations like SVD, etc... Unless you can use dot (scalar product), which is very fast in numpy if you use atlas (e.g.
742.
▲
by
cdavid
16y ago
It is important - you cannot know whether NaN is coming from a computation or is really a missing value otherwise. In Numpy, we have the MaskedArray implementation to do this.
743.
▲
by
cdavid
16y ago
To be fair, the sparse matrix package is still very rough. I am highly skeptical of the 1sec in java vs 8 hours in scipy, though. In general, numpy/scipy is quite faster than R: it does not have the pass by value semantics for once. I am al
744.
▲
by
cdavid
16y ago
You are overly exaggerating things. First, concerning junk food, it is nowhere near what you find in the US, especially quantity-wise (to give a stupid example, the biggest menu in Mc Donald's in Japan is smaller than the smallest thing you
745.
▲
by
cdavid
16y ago
For anyone living in Japan, the surprising thing is that it works at all . The possibilities for cheating are endless. It should be noted though that people in Japan do not move often. Actually, there are a lot of practices which make movi
746.
▲
by
cdavid
16y ago
It can be, and the end is certainly very stressful. But the amount of things you can learn during a PhD, and the pleasure of working/meeting very smart people is rewarding. Your mileage may vary, obviously. Also, in my case, even though I l
747.
▲
by
cdavid
16y ago
I think it is like this pretty much everywhere but the US. At least it is in France, UK, and Japan, and the US are the only country I have heard so far where you don't have to get a master before a PhD.
748.
▲
by
cdavid
16y ago
Is this relevant to the current 3d cards market ? I somehow doubt it.
749.
▲
by
cdavid
16y ago
One thing which is surprising with bug tracking is how crappy most of the products are, especially the open source ones. This strikes me as odd a priori since open source is generally pretty good at core programming tools - and bug tracking
750.
▲
by
cdavid
16y ago
LSA is relatively similar in some abstract sense to the published pagerank algorithm. LDA is more powerful, in the sense that it can account for more complex relationships (but may be less accurate with large number of data - I have really
More ›