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
Copy file name to clipboardExpand all lines: README.md
+6-4Lines changed: 6 additions & 4 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -4,9 +4,11 @@ A matrix log dependency utility. Useful for converting and testing algorithm beh
4
4
5
5
## Why?
6
6
GPU Principle: Your can only _write to_ or _read from_ Arrays (Textures).
7
-
CPU Principle: You can read or right to arrays as you see fit.
8
7
9
-
CPU Problem: Sometimes you'd like to convert your CPU code to GPU code.
8
+
CPU Principle: You can read or write to arrays _as you see fit_.
9
+
10
+
GPU Problem: Sometimes you'd like to convert your CPU code to GPU code.
11
+
10
12
By strategically using MatrixLog as a logger in your CPU algorithms, you can see which points are dependent from your source arrays to your target arrays.
11
13
This makes converting CPU code to run on GPU, using a utility like [GPU.js](http://gpu.rocks), much easier.
3. Now we have enough logic to visibly see how to build out our algorythm that will work on the GPU. For `filters`@`x=0,y=0` we can see we need the values from `weights`@`x=0,y=0`,`x=1,y=0`,`x=0,y=1`, and `x=1,y=1`. Then to get `filters`@`x=1,y=0`, we seem to increment by to on `weights`. If we were to write a loop that emilates this behaviour, it'd look something like this:
166
+
3. Now we have enough logic to visibly see how to build out our algorythm that will work on the GPU. For `filters`@`x=0,y=0` we can see we need the values from `weights`@`x=0,y=0`,`x=1,y=0`,`x=0,y=1`, and `x=1,y=1`. Then to get `filters`@`x=1,y=0`, we seem to increment by two on `weights`. If we were to write a loop that emilates this behaviour, it'd look something like this:
0 commit comments