You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
My friend and I, on different devices, are both trying to run the basic test example on Node,js (thanks for fixing the require problem) and we both get the issue
Warning: gpu not supported, falling back to cpu support
And while he has integrated intel graphics in a laptop and I wouldn't be all that surprised by that not working, I have a desktop with a GeForce 1060 6GB installed, so I can't imagine why my GPU wouldn't be compatible.
If this is specifically in node, right now there isn't GPU support in v1. There is however some work to bring in opencl, which is the target for node. Currently you'd need webgl to get GPU acceleration. Too, I will add, that the CPU implementation actually does a fine job optimizing the function it is given, so there is some acceleration, just not break neck speed that will come with GPU.
@robertleeplummerjr thanks, looking forward to the node update. I'd offer to help rather than be a moocher but tbh this project is a bit outside my skill set. We're using this in the web browser to compute neural networks lightning fast, GPU acceleration is so awesome, thanks for creating this for JS! A node implementation will probably be even faster.
They all seem to work fairly similarly, I got started by watching this but a friend and I built our own from the ground up successfully, I'll share it with you when we finish polishing and release it on github. One I can recommend is SynapticJS, it looks a little more polished than the one at brain.js.org but I cant say for sure. All of us devs seem to be working with neural nets these days, cant wait to see what the future holds for all of this.
May be this does not apply to you at all, but nevertheless. You could also use electron, since this is a modified version of chrome with the advantage of being able to use all native node modules.
Any news on this working? I'd like to use this to calculate Vector cosine similarity on thousands of vectors on my server, and using the GPU would be perfect for this... Any news on it working with node yet?
The project works ok in node, it just doesn't currently fall back to the GPU, it falls back to CPU. A lot of people have dedicated a lot of their time to this project, and to my knowledge there are none that perform the level of automation that are obtainable from it. GPU support is coming on node and has only recently been within our grasp.
@WriteCodeEveryday sadly I do not have a specific deadline for this yet. Brain.js v2 will come out first then I'll shift focus onto this. Brain.js v2 is about 95% done, but I'm currently unit testing and correcting convolution layers and it is simply taking more time that I'd hoped. Help would be greatly appreciated, but not required.
So an update to everyone, v2, rc2 has Nodejs support. In-fact it pushes the existing mechanics of gpu.js to be very stable. It is near release time for it, as unit tests are passing very well. There is, however, one missing feature highlighted here: stackgl/headless-gl#142
To expound on the feature: In order for GPU.js to be really fast, we want to set multiple outputs for a single input. This already works in webgl1, webgl2, and CPU with the createKernelMap method. I've been working really hard to find out what the missing requirements are to satisfy that feature, and as of last night for it working for the repo that gives us node GPU support here: stackgl/headless-gl#144
While there may be some changes that need to happen to satisfy the maintainers of headless-gl, unencumbered GPU.js node support is imminent. Said differently, we finally have full on GPU support on the server. A little late, but on its way.
So to be clear: currently to get the full on effects, just browserify your code from node, and run it in a browser
A little late to the party. I'm actually just curious about this. (FYI complete newbie to ML in general) This might sound stupid, but would running my brainjs code within a headless browser - like chrome headless or something else - allow it to leverage the WebGL and there by the GPU for increased speed and performance?
Activity
robertleeplummerjr commentedon Nov 8, 2017
If this is specifically in node, right now there isn't GPU support in v1. There is however some work to bring in opencl, which is the target for node. Currently you'd need webgl to get GPU acceleration. Too, I will add, that the CPU implementation actually does a fine job optimizing the function it is given, so there is some acceleration, just not break neck speed that will come with GPU.
robertleeplummerjr commentedon Nov 8, 2017
So to be clear: currently to get the full on effects, just browserify your code from node, and run it in a browser
viziionary commentedon Nov 30, 2017
@robertleeplummerjr thanks, looking forward to the node update. I'd offer to help rather than be a moocher but tbh this project is a bit outside my skill set. We're using this in the web browser to compute neural networks lightning fast, GPU acceleration is so awesome, thanks for creating this for JS! A node implementation will probably be even faster.
robertleeplummerjr commentedon Nov 30, 2017
Ty! Have you looked at brain.js.org? That is how I got started. I'd love to see the nets you are working with!
viziionary commentedon Nov 30, 2017
They all seem to work fairly similarly, I got started by watching this but a friend and I built our own from the ground up successfully, I'll share it with you when we finish polishing and release it on github. One I can recommend is SynapticJS, it looks a little more polished than the one at brain.js.org but I cant say for sure. All of us devs seem to be working with neural nets these days, cant wait to see what the future holds for all of this.
t638403 commentedon Dec 11, 2017
May be this does not apply to you at all, but nevertheless. You could also use electron, since this is a modified version of chrome with the advantage of being able to use all native node modules.
viziionary commentedon Dec 12, 2017
@t638403 yep, doing that already actually :)
robertleeplummerjr commentedon Dec 12, 2017
Opencl will be in v2, but until with, whatever means works. You guys are awesome. We'd love links to see how gpu.js is being used in the wild!
viziionary commentedon Dec 15, 2017
Looking forward to it, will link you when project is public
wbrickner commentedon Feb 23, 2018
Node.js support is absolutely critical. Has there been any progress on this issue?
Is there anything at all I can do to help get this working? Not sure how this works under the hood, I may not have the skillset.
wbrickner commentedon Feb 23, 2018
Looks interesting: https://github.com/mikeseven/node-opencl
robertleeplummerjr commentedon Feb 23, 2018
It's like you are in my head: mikeseven/node-opencl#55
wbrickner commentedon Mar 18, 2018
Any news on this? (Asking because Brain.js is dependent on GPU.js).
josiahbryan commentedon May 29, 2018
Any news on this working? I'd like to use this to calculate Vector cosine similarity on thousands of vectors on my server, and using the GPU would be perfect for this... Any news on it working with node yet?
robertleeplummerjr commentedon Aug 1, 2018
The project works ok in node, it just doesn't currently fall back to the GPU, it falls back to CPU. A lot of people have dedicated a lot of their time to this project, and to my knowledge there are none that perform the level of automation that are obtainable from it. GPU support is coming on node and has only recently been within our grasp.
WriteCodeEveryday commentedon Sep 28, 2018
@robertleeplummerjr do we have a target deadline for nodejs in gpu.js?
robertleeplummerjr commentedon Sep 29, 2018
@WriteCodeEveryday sadly I do not have a specific deadline for this yet. Brain.js v2 will come out first then I'll shift focus onto this. Brain.js v2 is about 95% done, but I'm currently unit testing and correcting convolution layers and it is simply taking more time that I'd hoped. Help would be greatly appreciated, but not required.
ExoMemphiz commentedon Dec 12, 2018
Any update? :)
Would love the capability to more easily write executable code on the GPU, and this would be fantastic if it'd actually run server-side.
robertleeplummerjr commentedon Dec 13, 2018
Nodejs compatibility will land around the first month of 2019.
robertleeplummerjr commentedon Feb 25, 2019
So an update to everyone, v2, rc2 has Nodejs support. In-fact it pushes the existing mechanics of gpu.js to be very stable. It is near release time for it, as unit tests are passing very well. There is, however, one missing feature highlighted here: stackgl/headless-gl#142
To expound on the feature: In order for GPU.js to be really fast, we want to set multiple outputs for a single input. This already works in webgl1, webgl2, and CPU with the
createKernelMapmethod. I've been working really hard to find out what the missing requirements are to satisfy that feature, and as of last night for it working for the repo that gives us node GPU support here: stackgl/headless-gl#144While there may be some changes that need to happen to satisfy the maintainers of headless-gl, unencumbered GPU.js node support is imminent. Said differently, we finally have full on GPU support on the server. A little late, but on its way.
Just fyi.
robertleeplummerjr commentedon Feb 25, 2019
Because this issue has to do with node and an already mature issue was raised here: #52
Going to close and continue progress there.
michaelonubogu commentedon Apr 23, 2019
A little late to the party. I'm actually just curious about this. (FYI complete newbie to ML in general) This might sound stupid, but would running my brainjs code within a headless browser - like chrome headless or something else - allow it to leverage the WebGL and there by the GPU for increased speed and performance?
harshkhandeparkar commentedon Apr 23, 2019
Yes it would provided that the PC has a GPU.