Live data from Hacker News

Gpu.js – GPU Accelerated JavaScript

gpu.rocks

41–50 of 84 posts

Re: Gpu.js – GPU Accelerated JavaScript

#41
post #4

cool! shameless self-promotion, I wrote a similar thing for a blog post travelling salesman in js+gpu: https://amoffat.github.io/held-karp-gpu-demo/ gpgpu.js: https://github.com/amoffat/gpgpu.js

Brilliant and thank you for posting it here!

This is just the example and encouragement I needed to entice my friend to get the interest in what I have been thoroughly absorbed by the past months, and yet failing to impress upon my buddy how much he has been missing.

(dude is my best friend in the business and until amicable split recently my partner in a number of projects. His latest is precisely what I know your effort will help him to figure out now : a delivery related app which is kinda a consumer breakaway from the last thing we worked on together.

As cheesy as this is, I have to say I am very grateful for your provision of a great chance to get my friend a good direction, right when I have been afraid for him. My best bud he is, but not a hacker [edit] of the modern mold and his glory days are from 40 years ago banging out mainframe clients. (cool though, he sold a db2 front end on the first IBM pc, which was a tour de force of memory management caching the data in a prefect scheme to create a floppy copy of the query results from partial tables. Example job was what I would use a Excel pivot table for today: flip sales orders against regions and tally sales rep targets, margins and success rates. Querying the big iron is not happening, it's shared and hosted and the computation cycles cost (I forget the term for IBM capacity charges) so the job is to juggle the PC as input terminal for the sales office secretary inputting the work rate stats, write local copies of the input and raw query results, and pull up missing data from the mainframe to grab the entries from other sales offices and e.g if they sold to a new customer in a new city get any other results which are sales to the locale by other departments, as they were only measured by senior management by the margin made and terms of supply length. To be clear the different offices were different departments and not restricted by geography, but knowing that they were more profitable than the other departments was a key factor in bonuses and morale. A big company, this could be a good deal of data. Only if the corporate already had customers in a area did bonuses get affected by relative performance, because they knew they would grow their market after sunk costs were eaten and they advertised the more profitable products first and piggy back sold off that as matter of policy. This meant that the exact price of a sale could be critical to the departments and securing advertising for their business lines was a significant advantage. Once the company had established enough gross sales overall it applied a less biased marketing policy, but the idea was to increase the incentives for people to both keep their prices high and to open new geographical areas. Since the advertising affected the margins quarterly, the department my buddy worked for later got him to work on the ability to target customers in areas which had trade magazine circulation in the highest densities, to increase the efficiency and also leave the other departments to less efficient advertising deals. Anyhow this was a rolling process of growing a new database continuously and it was a further tool for departmental management to book sales in the most advantageous times and that meant that both their and the mainframe were only eventually consistent. I'm told that the hardest part was because effectively the entire storage capacity of this PC was all in use and getting a scratch space would bust the performance horribly, everything was sequenced down to disk spinning to be sending the inputs and query results to final location in discreet action, no later sorting. I have only the stories and I was in school when my friend got this job, but I love the balance of the specification he had to deliver. What's cool is my buddy got the job on spec, they didn't believe because they considered him a kid, he was barely graduated and visited the business because his dad was a supplier of theirs. And his pitch was basically "I can make a database do anything you want but think is impossible, hire me!" His pay was nominal because of the speculative pitch, like $500 but he got a new PC and the expansion as part of his deal, and so got himself bootstrapped. At 20, in Chicago, in like 1982. I can only imagine how that must have felt like...

But I don't think that modern Web stacks is a world my friend can come to terms with. I've struggled and I'm still in my youthful 40s. I'm trying to get him into the whole Web assembly thing, which I think is the best thing to happen this century. Time to get rid of all the JS implementation grief, and love the primitives. I like how it started with a Scheme and is devolved to be almost a pure lambda layer. I have such admiration for my friend though, but what keeps getting between us is he is a amazing salesman and lost no energy in all the years, but the way it is just not clicking for him is a showstopper every time to getting shipped. We have a long friendship and I just feel that he feels he lost a touch without which he fears that things would get out of his grasp to fix. I'm secretly writing a parallel app to the same timetable as his, hell bent on rolling his place in the likely event that he is unable to get the perfection he needs to show his stuff. I'm not giving up on the guy, your self promotion is my absolute pleasure, thanks again for posting!)

Re: Gpu.js – GPU Accelerated JavaScript

#42
I've built an animated raytracer using this library.

http://raytracer.crypt.sg

The compile-able JavaScript subset is still fairly limited, so vector operations are quite painful. Beyond that, it's a great library to start with for parallel computation in the browser if you have no background in WebGL/GLSL.

Re: Gpu.js – GPU Accelerated JavaScript

#44
post #36
post #27

Earlier quoted context omitted.

Okay, Bill Gates alone is worth more than twice all the bitcoin ever mined. Apple is worth almost 20x that. So, per risk/reward, probably not a great strategy for either company. https://howmuch.net/articles/worlds-money-in-perspective .

Please adjust your equations for time.

Adjusting to the Gates or Apple timeline doesn't get you anywhere. Bitcoin won't exist in 30 years.

Re: Gpu.js – GPU Accelerated JavaScript

#46

Next steps: A computational graph based deep learning system with a Tensorflow like API on Javascript/Node lala-land. https://github.com/tqchen/tinyflow would be a great showcase (and useful) project to port for Gpu.js

Does node.js support webgl now?

Check out e.g. https://github.com/stackgl/headless-gl.

Re: Gpu.js – GPU Accelerated JavaScript

#47

Earlier quoted context omitted.

the beginning of the end of adblock :(

One can always disable WebGL.

My point is it could enforce a waittime. Disabling webgl only makes it worse as you'd have to wait much longer for the solution.

Re: Gpu.js – GPU Accelerated JavaScript

#48

One thing that might be helpful is if you linked to the Github repo on the site: https://github.com/gpujs/gpu.js . Especially for a project like this, high-performance computing, I'm gonna want to look at the code before I trust it.

There's a github corner-triangle-tabby-thingy in the top right corner of the page. Took me a moment of exasperation to spot, granted.

Re: Gpu.js – GPU Accelerated JavaScript

#49
post #36
post #27

Earlier quoted context omitted.

Okay, Bill Gates alone is worth more than twice all the bitcoin ever mined. Apple is worth almost 20x that. So, per risk/reward, probably not a great strategy for either company. https://howmuch.net/articles/worlds-money-in-perspective .

Please adjust your equations for time.

Meaning? MSFT and AAPL have proved enduring returns over decades, and ... is a flash in the pan? So adjusting over time means what?

Re: Gpu.js – GPU Accelerated JavaScript

#50

Is js via gpu (WebGL i assume) already efficient enough to make the concept of "computation time instead of banners" finally viable?

the beginning of the end of adblock :(

Ad blocking will always work as long as: a) ad networks insist on having users connect to their servers and b) users have the ability to blacklist said servers.
Post reply on HN