summaryrefslogtreecommitdiff
path: root/cumatrix_example.lua
blob: 88b591238ddeff29ed2de5f0dd532e6b0f96a31b (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
m = 600
n = 600
t = nerv.FloatCuMatrix(m, n)
t2 = nerv.FloatCuMatrix(m, n)
-- print(t)
a = t[1]
for i = 0, m - 1 do
    tt = t[i]
    tt2 = t2[i]
    for j = 0, n - 1 do
        tt[j] = i + j
        tt2[j] = t[i][j]
    end
end
-- print(t:rowsum())